diff options
Diffstat (limited to 'addressbook/gui/widgets')
-rw-r--r-- | addressbook/gui/widgets/e-addressbook-view.c | 6 | ||||
-rw-r--r-- | addressbook/gui/widgets/e-minicard-view.c | 8 |
2 files changed, 9 insertions, 5 deletions
diff --git a/addressbook/gui/widgets/e-addressbook-view.c b/addressbook/gui/widgets/e-addressbook-view.c index 4d6aea77ae..9d7b1826c7 100644 --- a/addressbook/gui/widgets/e-addressbook-view.c +++ b/addressbook/gui/widgets/e-addressbook-view.c @@ -230,9 +230,11 @@ table_white_space_event (ETable *table, GdkEvent *event, EAddressbookView *view) { - gint button = ((GdkEventButton *) event)->button; + guint event_button = 0; - if (event->type == GDK_BUTTON_PRESS && button == 3) { + gdk_event_get_button (event, &event_button); + + if (event->type == GDK_BUTTON_PRESS && event_button == 3) { addressbook_view_emit_popup_event (view, event); return TRUE; } diff --git a/addressbook/gui/widgets/e-minicard-view.c b/addressbook/gui/widgets/e-minicard-view.c index 88633d4492..1889399f3d 100644 --- a/addressbook/gui/widgets/e-minicard-view.c +++ b/addressbook/gui/widgets/e-minicard-view.c @@ -404,12 +404,14 @@ e_minicard_view_event (GnomeCanvasItem *item, GdkEvent *event) { EMinicardView *view; + guint event_button = 0; view = E_MINICARD_VIEW (item); switch (event->type) { case GDK_2BUTTON_PRESS: - if (((GdkEventButton *) event)->button == 1) { + gdk_event_get_button (event, &event_button); + if (event_button == 1) { gboolean editable; g_object_get (view->adapter, "editable", &editable, NULL); @@ -419,9 +421,9 @@ e_minicard_view_event (GnomeCanvasItem *item, return TRUE; } case GDK_BUTTON_PRESS: - if (event->button.button == 3) { + gdk_event_get_button (event, &event_button); + if (event_button == 3) e_minicard_view_right_click (view, event); - } break; case GDK_KEY_PRESS: if (event->key.keyval & GDK_SHIFT_MASK && |