[gedit] filebrowser: explicitly set tree view search column
- From: Jordi Mas <jmas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit] filebrowser: explicitly set tree view search column
- Date: Fri, 8 Nov 2019 19:45:19 +0000 (UTC)
commit d3b4565aef185402fb8d1f24a8dfe1b120e64fc6
Author: zb3 <onlylogout gmail com>
Date: Fri Nov 8 17:11:28 2019 +0100
filebrowser: explicitly set tree view search column
This sets the search column to the displayed file/bookmark name, which makes the interactive search
functionality work as expected.
Fixes #231
plugins/filebrowser/gedit-file-browser-view.c | 4 ++++
1 file changed, 4 insertions(+)
---
diff --git a/plugins/filebrowser/gedit-file-browser-view.c b/plugins/filebrowser/gedit-file-browser-view.c
index 476dabadf..37a0a238d 100644
--- a/plugins/filebrowser/gedit-file-browser-view.c
+++ b/plugins/filebrowser/gedit-file-browser-view.c
@@ -1048,6 +1048,7 @@ gedit_file_browser_view_set_model (GeditFileBrowserView *tree_view,
GtkTreeModel *model)
{
GtkTreeSelection *selection;
+ gint search_column;
if (tree_view->priv->model == model)
return;
@@ -1062,6 +1063,7 @@ gedit_file_browser_view_set_model (GeditFileBrowserView *tree_view,
tree_view->priv->text_renderer,
(GtkTreeCellDataFunc)cell_data_cb,
tree_view, NULL);
+ search_column = GEDIT_FILE_BOOKMARKS_STORE_COLUMN_NAME;
}
else
{
@@ -1071,6 +1073,7 @@ gedit_file_browser_view_set_model (GeditFileBrowserView *tree_view,
tree_view->priv->text_renderer,
(GtkTreeCellDataFunc)cell_data_cb,
tree_view, NULL);
+ search_column = GEDIT_FILE_BROWSER_STORE_COLUMN_NAME;
if (tree_view->priv->restore_expand_state)
install_restore_signals (tree_view, model);
@@ -1091,6 +1094,7 @@ gedit_file_browser_view_set_model (GeditFileBrowserView *tree_view,
tree_view->priv->model = model;
gtk_tree_view_set_model (GTK_TREE_VIEW (tree_view), model);
+ gtk_tree_view_set_search_column (GTK_TREE_VIEW (tree_view), search_column);
}
void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]