Merge lp:~azzar1/unity/lp-1411620 into lp:unity

Proposed by Andrea Azzarone
Status: Merged
Approved by: Marco Trevisan (Treviño)
Approved revision: no longer in the source branch.
Merged at revision: 3915
Proposed branch: lp:~azzar1/unity/lp-1411620
Merge into: lp:unity
Diff against target: 22 lines (+3/-3)
1 file modified
unity-shared/MenuManager.cpp (+3/-3)
To merge this branch: bzr merge lp:~azzar1/unity/lp-1411620
Reviewer Review Type Date Requested Status
Marco Trevisan (Treviño) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+248529@code.launchpad.net

Commit message

Actually connect to changed::* signal in MenuManager.cpp.

Description of the change

Due to a change in gsettings we to connect to the change signal before getting the value. I'm actually working on GSettingsProperty that should make gsettings easier to use in Unity. I still need some time, so it's better to send this before.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'unity-shared/MenuManager.cpp'
2--- unity-shared/MenuManager.cpp 2014-12-19 13:03:44 +0000
3+++ unity-shared/MenuManager.cpp 2015-02-04 11:16:49 +0000
4@@ -59,15 +59,15 @@
5 indicators_->on_entry_activate_request.connect(sigc::mem_fun(this, &Impl::ActivateRequest));
6 indicators_->icon_paths_changed.connect(sigc::mem_fun(this, &Impl::IconPathsChanged));
7
8- parent_->integrated_menus = g_settings_get_boolean(settings_, LIM_KEY.c_str());
9- parent_->always_show_menus = g_settings_get_boolean(settings_, ALWAYS_SHOW_MENUS_KEY.c_str());
10-
11 signals_.Add<void, GSettings*, const gchar*>(settings_, "changed::" + LIM_KEY, [this] (GSettings*, const gchar*) {
12 parent_->integrated_menus = g_settings_get_boolean(settings_, LIM_KEY.c_str());
13 });
14 signals_.Add<void, GSettings*, const gchar*>(settings_, "changed::" + ALWAYS_SHOW_MENUS_KEY, [this] (GSettings*, const gchar*) {
15 parent_->always_show_menus = g_settings_get_boolean(settings_, ALWAYS_SHOW_MENUS_KEY.c_str());
16 });
17+
18+ parent_->integrated_menus = g_settings_get_boolean(settings_, LIM_KEY.c_str());
19+ parent_->always_show_menus = g_settings_get_boolean(settings_, ALWAYS_SHOW_MENUS_KEY.c_str());
20 }
21
22 ~Impl()