Ejemplo n.º 1
0
        private void PaintContent()
        {
            this.PaintToolbar();
            this.contentScroll = EditorGUILayout.BeginScrollView(
                this.contentScroll,
                GUIStyle.none,
                GUI.skin.verticalScrollbar
                );

            EditorGUILayout.Space();

            ModuleManifest[] manifests = ModuleManager.GetProjectManifests();
            if (this.sidebarIndex < 0 || this.sidebarIndex >= manifests.Length)
            {
                ModuleManagerContent.PaintContentMessage();
            }
            else
            {
                ModuleManifest manifest = manifests[this.sidebarIndex];
                ModuleManagerContent.PaintProjectModule(manifest);
            }

            EditorGUILayout.Space();
            EditorGUILayout.EndScrollView();
        }
Ejemplo n.º 2
0
        private void PaintContent()
        {
            this.PaintToolbar();
            this.contentScroll = EditorGUILayout.BeginScrollView(
                this.contentScroll,
                GUIStyle.none,
                GUI.skin.verticalScrollbar
                );

            EditorGUILayout.Space();
            switch (this.toolbarOptionsIndex)
            {
            case 0:
                ModuleManifest[] manifests = ModuleManager.GetProjectManifests();
                if (this.sidebarIndex < 0 || this.sidebarIndex >= manifests.Length)
                {
                    ModuleManagerContent.PaintContentMessage();
                }
                else
                {
                    ModuleManifest manifest = manifests[this.sidebarIndex];
                    ModuleManagerContent.PaintProjectModule(manifest);
                }
                break;

            case 1:
                if (ModuleManagerStore.REQUEST_STATUS == ModuleManagerStore.StoreRequestStatus.Error)
                {
                    ModuleManagerContent.PaintContentMessage(ModuleManagerStore.REQUEST_DATA.error);
                    break;
                }
                else if (ModuleManagerStore.REQUEST_STATUS == ModuleManagerStore.StoreRequestStatus.Requesting)
                {
                    ModuleManagerContent.PaintContentMessage("Loading...");
                    break;
                }

                Module[] modules = ModuleManager.GetStoreModules();
                if (this.sidebarIndex < 0 || this.sidebarIndex >= modules.Length)
                {
                    ModuleManagerContent.PaintContentMessage();
                }
                else
                {
                    Module module = modules[this.sidebarIndex];
                    ModuleManagerContent.PaintStoreModule(module);
                }
                break;
            }

            EditorGUILayout.Space();
            EditorGUILayout.EndScrollView();
        }