Browse Source

Fix the search bar not filtering while typing

weinand 9 years ago
parent
commit
207f40c9e0

+ 2 - 0
Script/AtomicEditor/ui/frames/HierarchyFrame.ts

@@ -72,6 +72,8 @@ class HierarchyFrame extends Atomic.UIWidget {
 
 
         this.subscribeToEvent(EditorEvents.ActiveSceneEditorChange, (data) => this.handleActiveSceneEditorChanged(data));
         this.subscribeToEvent(EditorEvents.ActiveSceneEditorChange, (data) => this.handleActiveSceneEditorChanged(data));
 
 
+        this.searchEdit.subscribeToEvent(this.searchEdit, "WidgetEvent", (data) => this.handleWidgetEvent(data));
+
         // on mouse up clear the list's drag object
         // on mouse up clear the list's drag object
         this.subscribeToEvent("MouseButtonUp", () => {
         this.subscribeToEvent("MouseButtonUp", () => {
             // handle dropping on hierarchy, moving node, dropping prefabs, etc
             // handle dropping on hierarchy, moving node, dropping prefabs, etc

+ 2 - 0
Script/AtomicEditor/ui/frames/ProjectFrame.ts

@@ -77,6 +77,8 @@ class ProjectFrame extends ScriptWidget {
         this.subscribeToEvent("AssetRenamed", (ev: ToolCore.AssetRenamedEvent) => this.handleAssetRenamed(ev));
         this.subscribeToEvent("AssetRenamed", (ev: ToolCore.AssetRenamedEvent) => this.handleAssetRenamed(ev));
         this.subscribeToEvent(EditorEvents.InspectorProjectReference, (ev: EditorEvents.InspectorProjectReferenceEvent) => { this.handleInspectorProjectReferenceHighlight(ev.path); });
         this.subscribeToEvent(EditorEvents.InspectorProjectReference, (ev: EditorEvents.InspectorProjectReferenceEvent) => { this.handleInspectorProjectReferenceHighlight(ev.path); });
 
 
+        this.searchEdit.subscribeToEvent(this.searchEdit, "WidgetEvent", (data) => this.handleWidgetEvent(data));
+
         folderList.subscribeToEvent("UIListViewSelectionChanged", (event: Atomic.UIListViewSelectionChangedEvent) => this.handleFolderListSelectionChangedEvent(event));
         folderList.subscribeToEvent("UIListViewSelectionChanged", (event: Atomic.UIListViewSelectionChangedEvent) => this.handleFolderListSelectionChangedEvent(event));
 
 
         // this.subscribeToEvent(EditorEvents.ResourceFolderCreated, (ev: EditorEvents.ResourceFolderCreatedEvent) => this.handleResourceFolderCreated(ev));
         // this.subscribeToEvent(EditorEvents.ResourceFolderCreated, (ev: EditorEvents.ResourceFolderCreatedEvent) => this.handleResourceFolderCreated(ev));

+ 2 - 0
Script/AtomicEditor/ui/modal/ResourceSelection.ts

@@ -52,6 +52,8 @@ class ResourceSelection extends ModalWindow {
         this.setSize(800, 600);
         this.setSize(800, 600);
         this.center();
         this.center();
 
 
+        this.searchEdit.subscribeToEvent(this.searchEdit, "WidgetEvent", (data) => this.handleWidgetEvent(data));
+
     }
     }
 
 
     //adjusted to delete current folderlist and replace with search list if search is activated
     //adjusted to delete current folderlist and replace with search list if search is activated