コード例 #1
0
        public void SetUp()
        {
            const string sceneCardPrefabPath =
                "Assets/Scripts/MainScripts/DCL/Controllers/HUD/BuilderProjectsPanel/Prefabs/SceneCardView.prefab";
            var sceneCardPrefab = AssetDatabase.LoadAssetAtPath <SceneCardView>(sceneCardPrefabPath);

            sectionController = new SectionScenesController();
            scenesController  = new ScenesViewController(sceneCardPrefab);

            scenesController.AddListener((IDeployedSceneListener)sectionController);
            scenesController.AddListener((IProjectSceneListener)sectionController);
        }
コード例 #2
0
    void OnSectionShow(SectionBase sectionBase)
    {
        if (sectionBase is IDeployedSceneListener deployedSceneListener)
        {
            scenesViewController.AddListener(deployedSceneListener);
        }

        if (sectionBase is IProjectSceneListener projectSceneListener)
        {
            scenesViewController.AddListener(projectSceneListener);
        }

        if (sectionBase is ISelectSceneListener selectSceneListener)
        {
            scenesViewController.AddListener(selectSceneListener);
        }

        if (sectionBase is ILandsListener landsListener)
        {
            landController.AddListener(landsListener);
        }

        searchBarView.SetSearchBar(sectionBase.searchHandler, sectionBase.searchBarConfig);
    }
コード例 #3
0
 private void SetView()
 {
     scenesViewController.AddListener((IDeployedSceneListener)view);
     scenesViewController.AddListener((IProjectSceneListener)view);
 }