[evince] shell,plugin: Set position of GtkPopover. Fixes 756976
- From: Germán Poo-Caamaño <gpoo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evince] shell,plugin: Set position of GtkPopover. Fixes 756976
- Date: Thu, 22 Oct 2015 18:13:13 +0000 (UTC)
commit 2cd7145f90adacddd89c75d6078cf98bf63cc769
Author: Germán Poo-Caamaño <gpoo gnome org>
Date: Thu Oct 22 10:38:21 2015 -0700
shell,plugin: Set position of GtkPopover. Fixes 756976
On wayland, the GtkPopover is shown in Gtk's default position which is
GTK_POS_TOP. This default makes Evince unusable when having the window
maximized. Besides that it looks ugly having the popups shown in the
top of the window.
https://bugzilla.gnome.org/show_bug.cgi?id=756976
browser-plugin/EvBrowserPluginToolbar.cpp | 1 +
shell/ev-zoom-action.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/browser-plugin/EvBrowserPluginToolbar.cpp b/browser-plugin/EvBrowserPluginToolbar.cpp
index c7e4bc3..1786705 100644
--- a/browser-plugin/EvBrowserPluginToolbar.cpp
+++ b/browser-plugin/EvBrowserPluginToolbar.cpp
@@ -135,6 +135,7 @@ static void toggleSearch(EvBrowserPluginToolbar *toolbar)
{
if (!toolbar->priv->searchPopover) {
toolbar->priv->searchPopover = gtk_popover_new(toolbar->priv->searchToggleButton);
+ gtk_popover_set_position (GTK_POPOVER (toolbar->priv->searchPopover), GTK_POS_BOTTOM);
g_signal_connect_swapped(toolbar->priv->searchPopover, "closed",
G_CALLBACK(searchPopoverClosed), toolbar);
GtkWidget *searchBox = ev_search_box_new(toolbar->priv->plugin->model());
g_signal_connect_swapped(searchBox, "started", G_CALLBACK(searchStarted), toolbar);
diff --git a/shell/ev-zoom-action.c b/shell/ev-zoom-action.c
index 4f9bd93..3ed3f15 100644
--- a/shell/ev-zoom-action.c
+++ b/shell/ev-zoom-action.c
@@ -251,6 +251,7 @@ get_popup (EvZoomAction *zoom_action)
gtk_entry_get_icon_area (GTK_ENTRY (zoom_action->priv->entry),
GTK_ENTRY_ICON_SECONDARY, &rect);
gtk_popover_set_pointing_to (GTK_POPOVER (zoom_action->priv->popup), &rect);
+ gtk_popover_set_position (GTK_POPOVER (zoom_action->priv->popup), GTK_POS_BOTTOM);
return zoom_action->priv->popup;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]