[empathy] empathy_individual_view_get_individual_menu: don't create a menu if we don't want any feature
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy] empathy_individual_view_get_individual_menu: don't create a menu if we don't want any feature
- Date: Wed, 1 Jun 2011 09:49:30 +0000 (UTC)
commit cc6c2b5423c3a1906b5f484c157bc67dd9ee9d86
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date: Wed Jun 1 11:33:04 2011 +0200
empathy_individual_view_get_individual_menu: don't create a menu if we don't want any feature
Fix an assertion error when right clicking in the 'Invite contact' treeview.
libempathy-gtk/empathy-individual-view.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/libempathy-gtk/empathy-individual-view.c b/libempathy-gtk/empathy-individual-view.c
index ec63298..72e64cf 100644
--- a/libempathy-gtk/empathy-individual-view.c
+++ b/libempathy-gtk/empathy-individual-view.c
@@ -2564,6 +2564,10 @@ empathy_individual_view_get_individual_menu (EmpathyIndividualView *view)
g_return_val_if_fail (EMPATHY_IS_INDIVIDUAL_VIEW (view), NULL);
+ if (priv->individual_features == EMPATHY_INDIVIDUAL_FEATURE_NONE)
+ /* No need to create a context menu */
+ return NULL;
+
individual = empathy_individual_view_dup_selected (view);
if (individual == NULL)
return NULL;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]