Sfoglia il codice sorgente

UI: Implement interactive search on GameTable (#1148)

As I was unable to disable the ctrl + f keybinding, this implement
something to make it works with the default GTK code logic.

Also remove unused _treeView static member.
Thog 6 anni fa
parent
commit
74f8a9bd79
1 ha cambiato i file con 3 aggiunte e 4 eliminazioni
  1. 3 4
      Ryujinx/Ui/MainWindow.cs

+ 3 - 4
Ryujinx/Ui/MainWindow.cs

@@ -41,8 +41,6 @@ namespace Ryujinx.Ui
         private static bool _debuggerOpened;
         private static bool _debuggerOpened;
 #pragma warning restore CS0169
 #pragma warning restore CS0169
 
 
-        private static TreeView _treeView;
-
 #pragma warning disable CS0169
 #pragma warning disable CS0169
         private static Ryujinx.Debugger.Debugger _debugger;
         private static Ryujinx.Debugger.Debugger _debugger;
 #pragma warning restore CS0169
 #pragma warning restore CS0169
@@ -127,8 +125,6 @@ namespace Ryujinx.Ui
             // Make sure that everything is loaded.
             // Make sure that everything is loaded.
             _virtualFileSystem.Reload();
             _virtualFileSystem.Reload();
 
 
-            _treeView = _gameTable;
-
             ApplyTheme();
             ApplyTheme();
 
 
             _mainWin.Icon            = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.Icon.png");
             _mainWin.Icon            = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.Icon.png");
@@ -171,6 +167,9 @@ namespace Ryujinx.Ui
             _tableStore.SetSortFunc(8, FileSizeSort);
             _tableStore.SetSortFunc(8, FileSizeSort);
             _tableStore.SetSortColumnId(0, SortType.Descending);
             _tableStore.SetSortColumnId(0, SortType.Descending);
 
 
+            _gameTable.EnableSearch = true;
+            _gameTable.SearchColumn = 2;
+
             UpdateColumns();
             UpdateColumns();
             UpdateGameTable();
             UpdateGameTable();