diff options
Diffstat (limited to 'libempathy-gtk')
-rw-r--r-- | libempathy-gtk/empathy-log-window.c | 30 |
1 files changed, 25 insertions, 5 deletions
diff --git a/libempathy-gtk/empathy-log-window.c b/libempathy-gtk/empathy-log-window.c index c4a260889..219d0cc11 100644 --- a/libempathy-gtk/empathy-log-window.c +++ b/libempathy-gtk/empathy-log-window.c @@ -2502,13 +2502,12 @@ who_row_is_separator (GtkTreeModel *model, return (type == COL_TYPE_SEPARATOR); } -static gboolean -log_window_events_button_press_event (GtkWidget *webview, - GdkEventButton *event, - EmpathyLogWindow *self) +static void +log_window_find_row (EmpathyLogWindow *self, + GdkEventButton *event) { WebKitHitTestResult *hit = webkit_web_view_get_hit_test_result ( - WEBKIT_WEB_VIEW (webview), event); + WEBKIT_WEB_VIEW (self->priv->webview), event); WebKitDOMNode *inner_node; tp_clear_object (&self->priv->events_contact); @@ -2563,6 +2562,27 @@ log_window_events_button_press_event (GtkWidget *webview, g_object_unref (hit); log_window_update_buttons_sensitivity (self); +} + +static gboolean +log_window_events_button_press_event (GtkWidget *webview, + GdkEventButton *event, + EmpathyLogWindow *self) +{ + switch (event->button) + { + case 1: + log_window_find_row (self, event); + break; + + case 3: + empathy_webkit_context_menu_for_event ( + WEBKIT_WEB_VIEW (webview), event, 0); + return TRUE; + + default: + break; + } return FALSE; } |