summaryrefslogtreecommitdiff
path: root/src/completion.c
diff options
context:
space:
mode:
authorDaniel Carl <danielcarl@gmx.de>2014-04-10 00:47:19 +0200
committerDaniel Carl <danielcarl@gmx.de>2014-04-10 00:47:19 +0200
commit8c6ee697fd6d58cd9e1813aa4c1b1061e29a245e (patch)
tree0d9992cbdf2bdb0fd740f115edbdbb2c0fef3b24 /src/completion.c
parent13296a8d0dfe86793fe6507e4da05047e3d47c51 (diff)
Show the completion list after the hight was set.
If the completion list is displayed before we set the hight, the user might see the list for a really short time covering the whole webview window before it's resized to fit into the lower third of the view. The patch moved the display of the completion list after the list is calculated and the first entry is marked as active.
Diffstat (limited to 'src/completion.c')
-rw-r--r--src/completion.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/completion.c b/src/completion.c
index 6740284..d01207b 100644
--- a/src/completion.c
+++ b/src/completion.c
@@ -127,7 +127,6 @@ gboolean completion_create(GtkTreeModel *model, CompletionSelectFunc selfunc,
/* this prevents the first item to be placed out of view if the completion
* is shown */
- gtk_widget_show_all(comp.win);
while (gtk_events_pending()) {
gtk_main_iteration();
}
@@ -154,6 +153,8 @@ gboolean completion_create(GtkTreeModel *model, CompletionSelectFunc selfunc,
comp.active = -1;
completion_next(back);
+ gtk_widget_show_all(comp.win);
+
return true;
}