summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDon Scorgie <dscorgie@src.gnome.org>2006-06-11 09:21:49 +0000
committerDon Scorgie <dscorgie@src.gnome.org>2006-06-11 09:21:49 +0000
commitf74954c5f7c862ec648a094a6ff1b6a96ee56e26 (patch)
tree2141eaa0587e55664d2fa8e438272e843bd3479b
parentb1dc970ca5a6cf9d491aa9dd696e164728d37386 (diff)
downloadyelp-f74954c5f7c862ec648a094a6ff1b6a96ee56e26.tar.gz
Don't auto-expand sections in left pane (bug #167070)
* src/yelp-window.c: Don't auto-expand sections in left pane (bug #167070)
-rw-r--r--ChangeLog5
-rw-r--r--src/yelp-window.c15
2 files changed, 15 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 35b52cb6..3d446477 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-06-11 Don Scorgie <dscorgie@cvs.gnome.org>
+
+ * src/yelp-window.c:
+ Don't auto-expand sections in left pane (bug #167070)
+
2006-06-11 Christian Persch <chpe@cvs.gnome.org>
* configure.in:
diff --git a/src/yelp-window.c b/src/yelp-window.c
index 427802c0..4aba9426 100644
--- a/src/yelp-window.c
+++ b/src/yelp-window.c
@@ -1799,12 +1799,17 @@ window_handle_page (YelpWindow *window,
if (yelp_pager_page_contains_frag (pager,
id,
priv->current_frag)) {
- GtkTreePath *path = gtk_tree_model_get_path (model, &iter);
-
- gtk_tree_view_expand_to_path (GTK_TREE_VIEW (priv->side_sects),
- path);
+ GtkTreePath *path = NULL;
+ GtkTreeIter parent;
+ if (gtk_tree_model_iter_parent (model, &parent, &iter)) {
+ path = gtk_tree_model_get_path (model, &parent);
+ gtk_tree_view_expand_to_path (GTK_TREE_VIEW (priv->side_sects),
+ path);
+ gtk_tree_path_free(path);
+ }
+ path = gtk_tree_model_get_path (model, &iter);
gtk_tree_selection_select_path (selection, path);
-
+
gtk_tree_path_free (path);
g_free (id);
break;