[buoh/builder-port: 2/4] Fix some deprecations
- From: Jan Tojnar <jtojnar src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [buoh/builder-port: 2/4] Fix some deprecations
- Date: Wed, 12 Sep 2018 11:54:19 +0000 (UTC)
commit df36d1b72e816b07cc4e1ce7b54e0bcdef98f1c9
Author: Jan Tojnar <jtojnar gmail com>
Date: Tue Sep 11 13:41:48 2018 +0200
Fix some deprecations
src/buoh-view-message.c | 4 ++--
src/buoh-window.c | 24 ++++++++++--------------
2 files changed, 12 insertions(+), 16 deletions(-)
---
diff --git a/src/buoh-view-message.c b/src/buoh-view-message.c
index 69f9c5b..7b414bb 100644
--- a/src/buoh-view-message.c
+++ b/src/buoh-view-message.c
@@ -50,7 +50,7 @@ buoh_view_message_init (BuohViewMessage *m_view)
m_view->priv = BUOH_VIEW_MESSAGE_GET_PRIVATE (m_view);
- vbox = gtk_vbox_new (FALSE, 24);
+ vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 24);
m_view->priv->title = gtk_label_new (NULL);
gtk_label_set_line_wrap (GTK_LABEL (m_view->priv->title), TRUE);
@@ -68,7 +68,7 @@ buoh_view_message_init (BuohViewMessage *m_view)
TRUE, TRUE, 0);
gtk_widget_show (m_view->priv->text);
- hbox = gtk_hbox_new (FALSE, 24);
+ hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 24);
gtk_container_set_border_width (GTK_CONTAINER (hbox), 24);
m_view->priv->icon = gtk_image_new_from_stock (NULL, GTK_ICON_SIZE_DIALOG);
diff --git a/src/buoh-window.c b/src/buoh-window.c
index 7e74fad..20fc6c5 100644
--- a/src/buoh-window.c
+++ b/src/buoh-window.c
@@ -256,7 +256,7 @@ buoh_window_init (BuohWindow *buoh_window)
buoh_window->priv->buoh_settings = g_settings_new (GS_BUOH_SCHEMA);
buoh_window->priv->lockdown_settings = g_settings_new (GS_LOCKDOWN_SCHEMA);
- vbox = gtk_vbox_new (FALSE, 0);
+ vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
/* Menu bar */
action_group = gtk_action_group_new ("MenuActions");
@@ -322,7 +322,7 @@ buoh_window_init (BuohWindow *buoh_window)
NULL);
/* Pane */
- paned = gtk_hpaned_new ();
+ paned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
/* FIXME: Remember side position */
gtk_paned_set_position (GTK_PANED (paned), 230);
@@ -1104,9 +1104,8 @@ buoh_window_comic_list_button_press_cb (GtkWidget *widget, GdkEventButton *event
if (gtk_tree_selection_get_selected (selection, NULL, NULL)) {
popup = gtk_ui_manager_get_widget (window->priv->ui_manager, "/ListPopup");
- gtk_menu_popup (GTK_MENU (popup), NULL,
- NULL, NULL, NULL,
- event->button, event->time);
+ gtk_menu_popup_at_pointer (GTK_MENU (popup),
+ (const GdkEvent *) event);
return TRUE;
}
}
@@ -1130,9 +1129,8 @@ buoh_window_comic_list_key_press_cb (GtkWidget *widget, GdkEventKey *event, gpoi
if (gtk_tree_selection_get_selected (selection, NULL, NULL)) {
popup = gtk_ui_manager_get_widget (window->priv->ui_manager, "/ListPopup");
- gtk_menu_popup (GTK_MENU (popup), NULL,
- NULL, NULL, NULL,
- 0, event->time);
+ gtk_menu_popup_at_pointer (GTK_MENU (popup),
+ (const GdkEvent *) event);
return TRUE;
}
}
@@ -1170,9 +1168,8 @@ buoh_window_comic_view_button_press_cb (GtkWidget *widget, GdkEventButton *event
if (event->button == 3) {
popup = gtk_ui_manager_get_widget (window->priv->ui_manager, "/ViewPopup");
- gtk_menu_popup (GTK_MENU (popup), NULL,
- NULL, NULL, NULL,
- event->button, event->time);
+ gtk_menu_popup_at_pointer (GTK_MENU (popup),
+ (const GdkEvent *) event);
return TRUE;
}
@@ -1199,9 +1196,8 @@ buoh_window_comic_view_key_press_cb (GtkWidget *widget, GdkEventKey *event, gpoi
event->keyval == GDK_KEY_F10) {
popup = gtk_ui_manager_get_widget (window->priv->ui_manager, "/ViewPopup");
- gtk_menu_popup (GTK_MENU (popup), NULL,
- NULL, NULL, NULL,
- 0, event->time);
+ gtk_menu_popup_at_pointer (GTK_MENU (popup),
+ (const GdkEvent *) event);
return TRUE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]