Browse Source

Fix switching to non-existent pose/face blend set

Apparent when loading newly installed MeidoPhotoStudio with no custom
poses or face presets.
habeebweeb 4 years ago
parent
commit
4c1a545046

+ 2 - 2
COM3D2.MeidoPhotoStudio.Plugin/MeidoPhotoStudio/GUI/Panes/FaceWindowPanes/MaidFaceBlendPane.cs

@@ -48,8 +48,8 @@ namespace COM3D2.MeidoPhotoStudio.Plugin
             );
             );
             faceBlendCategoryDropdown.SelectionChange += (s, a) =>
             faceBlendCategoryDropdown.SelectionChange += (s, a) =>
             {
             {
-                faceBlendDropdown.SetDropdownItems(UIFaceList(), 0);
                 faceListEnabled = CurrentFaceList.Count > 0;
                 faceListEnabled = CurrentFaceList.Count > 0;
+                faceBlendDropdown.SetDropdownItems(UIFaceList(), 0);
             };
             };
 
 
             prevCategoryButton = new Button("<");
             prevCategoryButton = new Button("<");
@@ -61,7 +61,7 @@ namespace COM3D2.MeidoPhotoStudio.Plugin
             faceBlendDropdown = new Dropdown(UIFaceList());
             faceBlendDropdown = new Dropdown(UIFaceList());
             faceBlendDropdown.SelectionChange += (s, a) =>
             faceBlendDropdown.SelectionChange += (s, a) =>
             {
             {
-                if (updating) return;
+                if (!faceListEnabled || updating) return;
                 this.meidoManager.ActiveMeido.SetFaceBlendSet(SelectedFace, facePresetMode);
                 this.meidoManager.ActiveMeido.SetFaceBlendSet(SelectedFace, facePresetMode);
             };
             };
 
 

+ 1 - 0
COM3D2.MeidoPhotoStudio.Plugin/MeidoPhotoStudio/GUI/Panes/PoseWindowPanes/MaidPoseSelectorPane.cs

@@ -169,6 +169,7 @@ namespace COM3D2.MeidoPhotoStudio.Plugin
 
 
         private void ChangePoseGroup()
         private void ChangePoseGroup()
         {
         {
+            poseListEnabled = CurrentPoseList.Count > 0;
             if (previousPoseGroup == SelectedPoseGroup)
             if (previousPoseGroup == SelectedPoseGroup)
             {
             {
                 poseDropdown.SelectedItemIndex = 0;
                 poseDropdown.SelectedItemIndex = 0;