[ekiga/ds-gtk-application] UI: Really sync actions in ActorMenu.
- From: Damien Sandras <dsandras src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ekiga/ds-gtk-application] UI: Really sync actions in ActorMenu.
- Date: Sun, 23 Mar 2014 16:25:37 +0000 (UTC)
commit 700fceac64eb773976ad3a8e091ab99d6fc7ee57
Author: Damien Sandras <dsandras beip be>
Date: Sun Mar 23 17:15:10 2014 +0100
UI: Really sync actions in ActorMenu.
GIO actions should be added or removed in a sync operation.
lib/engine/gui/gtk-core/actor-menu.cpp | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/lib/engine/gui/gtk-core/actor-menu.cpp b/lib/engine/gui/gtk-core/actor-menu.cpp
index b8b47dd..d8c74c3 100644
--- a/lib/engine/gui/gtk-core/actor-menu.cpp
+++ b/lib/engine/gui/gtk-core/actor-menu.cpp
@@ -82,8 +82,12 @@ Ekiga::ActorMenu::sync_gio_actions ()
{
ActionMap::const_iterator it;
- for (it = obj.actions.begin(); it != obj.actions.end(); ++it)
- add_gio_action (boost::dynamic_pointer_cast<Action> (it->second));
+ for (it = obj.actions.begin(); it != obj.actions.end(); ++it) {
+ if (it->second->is_enabled ())
+ add_gio_action (boost::dynamic_pointer_cast<Action> (it->second));
+ else
+ remove_gio_action (it->first);
+ }
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]