ソースを参照

Suppress scene changes while toggling the debug icons visibility during preview camera render so that the attribute editor doesn't constantly refresh, making attributes uneditable. Closes #854.

Lasse Öörni 10 年 前
コミット
47fe410d06
1 ファイル変更4 行追加0 行削除
  1. 4 0
      bin/Data/Scripts/Editor/EditorView.as

+ 4 - 0
bin/Data/Scripts/Editor/EditorView.as

@@ -2046,10 +2046,12 @@ void HandleBeginViewUpdate(StringHash eventType, VariantMap& eventData)
     }
     }
     if (eventData["Camera"].GetPtr() is previewCamera.Get())
     if (eventData["Camera"].GetPtr() is previewCamera.Get())
     {
     {
+        suppressSceneChanges = true;
         if (grid !is null)
         if (grid !is null)
             grid.viewMask = 0;
             grid.viewMask = 0;
         if (debugIconsNode !is null)
         if (debugIconsNode !is null)
             debugIconsNode.enabled = false;
             debugIconsNode.enabled = false;
+        suppressSceneChanges = false;
     }
     }
 }
 }
 
 
@@ -2063,10 +2065,12 @@ void HandleEndViewUpdate(StringHash eventType, VariantMap& eventData)
     }
     }
     if (eventData["Camera"].GetPtr() is previewCamera.Get())
     if (eventData["Camera"].GetPtr() is previewCamera.Get())
     {
     {
+        suppressSceneChanges = true;
         if (grid !is null)
         if (grid !is null)
             grid.viewMask = 0x80000000;
             grid.viewMask = 0x80000000;
         if (debugIconsNode !is null)
         if (debugIconsNode !is null)
             debugIconsNode.enabled = true;
             debugIconsNode.enabled = true;
+        suppressSceneChanges = false;
     }
     }
 }
 }