Example #1
0
        private void TreeView_SelectionChanged(object sender, RoutedPropertyChangedEventArgs <object> e)
        {
            var item = (TreeViewItem)e.NewValue;

            switch ((string)item.Name)
            {
            case "GeneralPanel":
                _generalPanel.Refresh();
                EditorPanel.Content = _generalPanel;
                break;

            case "PartyPanel":
                _partyPanel.Refresh();
                EditorPanel.Content = _partyPanel;
                break;

            case "CreaturePanel":
                _creaturePanel.Refresh();
                EditorPanel.Content = _creaturePanel;
                break;

            case "TrappingPanel":
                _trappingPanel.Refresh();
                EditorPanel.Content = _trappingPanel;
                break;

            case "ItemsPanel":
                _itemsPanel.Refresh();
                EditorPanel.Content = _itemsPanel;
                break;

            case "AccessoriesPanel":
                _accessoriesPanel.Refresh();
                EditorPanel.Content = _accessoriesPanel;
                break;

            case "DresspheresPanel":
                _dresspheresPanel.Refresh();
                EditorPanel.Content = _dresspheresPanel;
                break;

            case "GarmentGridsPanel":
                _garmentGridsPanel.Refresh();
                EditorPanel.Content = _garmentGridsPanel;
                break;

            case "DebugOptionsPanel":
                _debugOptionsPanel.Refresh();
                EditorPanel.Content = _debugOptionsPanel;
                break;

            case "ModsPanel":
                _modPanel.Refresh();
                EditorPanel.Content = _modPanel;
                break;

            default:
                break;
            }
        }
        private void TreeView_SelectionChanged(object sender, RoutedPropertyChangedEventArgs <object> e)
        {
            var item = (TreeViewItem)e.NewValue;

            switch ((string)item.Tag)
            {
            case "General":
                mGeneral.Refresh();
                EditorPanel.Content = mGeneral;
                break;

            case "PartyEditorYuna":
                mPartyEditorYuna.Refresh();
                EditorPanel.Content = mPartyEditorYuna;
                break;

            case "PartyEditorRikku":
                mPartyEditorRikku.Refresh();
                EditorPanel.Content = mPartyEditorRikku;
                break;

            case "PartyEditorPaine":
                mPartyEditorPaine.Refresh();
                EditorPanel.Content = mPartyEditorPaine;
                break;

            case "CreaturePanel":
                CreaturePanel.Update();
                EditorPanel.Content = mCreaturePanel;
                break;

            case "CreatureTrapping":
                mCreatureTrapping.Refresh();
                EditorPanel.Content = mCreatureTrapping;
                break;

            case "ItemEditor":
                mItemsEditor.Refresh();
                EditorPanel.Content = mItemsEditor;
                break;

            case "AccessoriesEditor":
                mAccessoriesEditor.Refresh();
                EditorPanel.Content = mAccessoriesEditor;
                break;

            case "DressphereEditor":
                mDressphereEditor.Refresh();
                EditorPanel.Content = mDressphereEditor;
                break;

            case "GarmentGridEditor":
                mGarmentGridEditor.Refresh();
                EditorPanel.Content = mGarmentGridEditor;
                break;

            case "DebugOptions":
                mDebugOptions.Refresh();
                EditorPanel.Content = mDebugOptions;
                break;

            default:
                break;
            }
        }