Merge lp:~bilalakhtar/unity/fix-740867 into lp:unity

Proposed by Bilal Akhtar
Status: Rejected
Rejected by: Didier Roche-Tolomelli
Proposed branch: lp:~bilalakhtar/unity/fix-740867
Merge into: lp:unity
Diff against target: 60 lines (+26/-0)
2 files modified
src/BamfLauncherIcon.cpp (+25/-0)
src/BamfLauncherIcon.h (+1/-0)
To merge this branch: bzr merge lp:~bilalakhtar/unity/fix-740867
Reviewer Review Type Date Requested Status
Didier Roche-Tolomelli Disapprove
Review via email: mp+54497@code.launchpad.net

Description of the change

This branch fixes bug #740867 .

To post a comment you must log in.
Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

Hey Bilal,

Thanks for the merge request. However, the decision to remove it has been taken in bug #709707 referenced by the commit your revert (see the comments) and won't be reintroduce without an agreement on the ayatana-mailing list.

Disapproving for now. keep me in touch if the discussion changed the outcome :)

review: Disapprove
Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

Setting the state to reject as my previous comment to clean the list and you already proposed another fix which makes that happen :)

Unmerged revisions

1001. By Bilal Akhtar

Add 'Open a new window' item to quicklist of BamfLauncherIcon

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/BamfLauncherIcon.cpp'
2--- src/BamfLauncherIcon.cpp 2011-03-14 20:48:50 +0000
3+++ src/BamfLauncherIcon.cpp 2011-03-23 11:35:43 +0000
4@@ -651,6 +651,12 @@
5 }
6
7 void
8+BamfLauncherIcon::OnNewWindow (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self)
9+{
10+ OpenInstanceLauncherIcon();
11+}
12+
13+void
14 BamfLauncherIcon::OnTogglePin (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self)
15 {
16 BamfView *view = BAMF_VIEW (self->m_App);
17@@ -680,6 +686,22 @@
18 {
19 DbusmenuMenuitem *menu_item;
20
21+ /* NewWindow */
22+ if (_menu_items.find ("NewWindow") == _menu_items.end ())
23+ {
24+ menu_item = dbusmenu_menuitem_new ();
25+ g_object_ref (menu_item);
26+
27+ dbusmenu_menuitem_property_set (menu_item, DBUSMENU_MENUITEM_PROP_LABEL, _("Open a New Window"));
28+ dbusmenu_menuitem_property_set_bool (menu_item, DBUSMENU_MENUITEM_PROP_ENABLED, true);
29+ dbusmenu_menuitem_property_set_bool (menu_item, DBUSMENU_MENUITEM_PROP_VISIBLE, true);
30+
31+ g_signal_connect (menu_item, DBUSMENU_MENUITEM_SIGNAL_ITEM_ACTIVATED, (GCallback) &BamfLauncherIcon::OnNewWindow, this);
32+
33+ _menu_items["NewWindow"] = menu_item;
34+ }
35+
36+
37 /* Pin */
38 if (_menu_items.find ("Pin") == _menu_items.end ())
39 {
40@@ -770,6 +792,9 @@
41 if (g_strcmp0 (key , "Quit") == 0 && !bamf_view_is_running (BAMF_VIEW (m_App)))
42 continue;
43
44+ if (g_strcmp0 (key, "NewWindow") == 0 && !bamf_view_is_running (BAMF_VIEW (m_App)))
45+ continue;
46+
47 exists = false;
48 std::string label_default = dbusmenu_menuitem_property_get ((*it_m).second, DBUSMENU_MENUITEM_PROP_LABEL);
49 for(it_l = result.begin(); it_l != result.end(); it_l++)
50
51=== modified file 'src/BamfLauncherIcon.h'
52--- src/BamfLauncherIcon.h 2011-02-11 17:03:24 +0000
53+++ src/BamfLauncherIcon.h 2011-03-23 11:35:43 +0000
54@@ -95,6 +95,7 @@
55 static void OnChildRemoved (BamfView *view, BamfView *child, gpointer data);
56
57 static void OnQuit (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self);
58+ static void OnNewWindow (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self);
59 static void OnLaunch (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self);
60 static void OnTogglePin (DbusmenuMenuitem *item, int time, BamfLauncherIcon *self);
61