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

Proposed by Andrea Azzarone on 2016-01-20
Status: Merged
Approved by: Marco Trevisan (Treviño) on 2016-03-21
Approved revision: 4079
Merged at revision: 4092
Proposed branch: lp:~azzar1/unity/unity-sn
Merge into: lp:unity
Prerequisite: lp:~3v1n0/unity/launcher-filemanager-integration
Diff against target: 155 lines (+33/-3)
9 files modified
CMakeLists.txt (+1/-1)
debian/control (+1/-1)
launcher/ApplicationLauncherIcon.cpp (+8/-0)
launcher/Launcher.cpp (+1/-1)
launcher/WindowedLauncherIcon.cpp (+5/-0)
launcher/WindowedLauncherIcon.h (+1/-0)
unity-shared/ApplicationManager.h (+1/-0)
unity-shared/BamfApplicationManager.cpp (+14/-0)
unity-shared/BamfApplicationManager.h (+1/-0)
To merge this branch: bzr merge lp:~azzar1/unity/unity-sn
Reviewer Review Type Date Requested Status
Marco Trevisan (Treviño) 2016-01-20 Approve on 2016-03-21
PS Jenkins bot continuous-integration Needs Fixing on 2016-02-29
Review via email: mp+283322@code.launchpad.net

Commit Message

ApplicationLauncherIcon: use the starting property to show an icon when launched

Description of the Change

Use new bamf starting property. It's not taking properly lp:~3v1n0/unity/launcher-filemanager-integration as a prerequisite. No sure if it's my fault.

To post a comment you must log in.
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Marco Trevisan (Treviño) (3v1n0) wrote :

Looks good, fix a typo in the s/visible/starting variable and add proper dependency on new bamf version (both in debian and cmakefile sides).

review: Needs Fixing
lp:~azzar1/unity/unity-sn updated on 2016-02-25
4068. By Matthias Klose on 2016-02-08

debian: Multiarchify the library packages.

Manual sync with debian packaging

4069. By Marco Trevisan (Treviño) on 2016-02-09

Launcher: add FileManager, Trash and Volume icons integration

Now the launcher will link each nautilus window to the related volume or trash
icon, while the Nautilus launcher icon will only be active if the file manager is
browsing other locations.
It's now possible to manage sub-windows from the parent icon like it happens for
every other application (so even spreading them or select from QL)

The windows management logic has been moved to WindowedLauncherIcon which is a
base class of ApplicationLauncherIcon, and StorageLauncherIcon.
VolumeLauncherIcon and TrashLauncherIcon are now based on StorageLauncherIcon
which connects to the FileManager to get the windows for a given location.

FileManagerLauncherIcon is now special and is both an ApplicationLauncherIcon
and a StorageLauncherIcon, and uses the parent application only for some tasks.

Lots of random code cleanup included too. Fixes: #1063823, #1063838, #1161323, #1524721
Approved by: PS Jenkins bot, Andrea Azzarone

4070. By Marco Trevisan (Treviño) on 2016-02-09

SwitcherModel: avoid to access to invalid selection or to divide by zero Fixes: #1537524
Approved by: PS Jenkins bot, Andrea Azzarone

4071. By Didier Roche on 2016-02-09

debian: Recommends session-shortcuts, prodiving easy way to shutdown, reboot and logout from dash
Approved by: Marco Trevisan (Treviño)

4072. By Marco Trevisan (Treviño) on 2016-02-09

CMake: use GNUInstallDirs with native multi-arch support

We can now use CMAKE_INSTALL_*DIR instead of defining them manually.
Also disable networkarea region plugin build by default. Fixes: #1485668, #1508635
Approved by: Andrea Azzarone

4073. By handsome_feng on 2016-02-09

Extend the lockscreen theme for kylin.
Approved by: PS Jenkins bot, Marco Trevisan (Treviño)

4074. By CI Train Bot Account on 2016-02-09

Releasing 7.4.0+16.04.20160209.3-0ubuntu1

4075. By Andrea Azzarone on 2016-02-25

Merge with trunk.

4076. By Andrea Azzarone on 2016-02-25

Fix typo.

PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
lp:~azzar1/unity/unity-sn updated on 2016-02-29
4077. By Andrea Azzarone on 2016-02-29

Use bamf 5.3

Andrea Azzarone (azzar1) wrote :

Done.

PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
lp:~azzar1/unity/unity-sn updated on 2016-03-21
4078. By Andrea Azzarone on 2016-03-18

Require bamf >= 0.5.3 in CmakeList.txt too.

4079. By Andrea Azzarone on 2016-03-21

Increase MAX_STARTING_BLINKS.

Marco Trevisan (Treviño) (3v1n0) wrote :

Everything has been addressed. Thanks.

So, let's go!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'CMakeLists.txt'
2--- CMakeLists.txt 2016-03-16 09:47:02 +0000
3+++ CMakeLists.txt 2016-03-21 15:21:52 +0000
4@@ -243,7 +243,7 @@
5 gtk+-3.0>=3.1
6 indicator3-0.4>=0.4.90
7 json-glib-1.0
8- libbamf3>=0.5.2
9+ libbamf3>=0.5.3
10 gnome-desktop-3.0
11 libnotify
12 libstartup-notification-1.0
13
14=== modified file 'debian/control'
15--- debian/control 2016-03-17 07:36:44 +0000
16+++ debian/control 2016-03-21 15:21:52 +0000
17@@ -15,7 +15,7 @@
18 intltool (>= 0.35.0),
19 libappstream-glib-dev,
20 libatk1.0-dev,
21- libbamf3-dev (>= 0.5.2~bzr0),
22+ libbamf3-dev (>= 0.5.3~bzr0),
23 libboost-dev,
24 libcairo2-dev,
25 libdbus-1-dev,
26
27=== modified file 'launcher/ApplicationLauncherIcon.cpp'
28--- launcher/ApplicationLauncherIcon.cpp 2015-12-17 22:32:37 +0000
29+++ launcher/ApplicationLauncherIcon.cpp 2016-03-21 15:21:52 +0000
30@@ -114,6 +114,9 @@
31 // Make sure we set the LauncherIcon stick bit too...
32 if (app_->sticky() || was_sticky)
33 Stick(false); // don't emit the signal
34+
35+ if (app_->starting())
36+ SetQuirk(Quirk::STARTING, true);
37 }
38
39 void ApplicationLauncherIcon::UnsetApplication()
40@@ -151,6 +154,11 @@
41 SetQuirk(Quirk::URGENT, urgent);
42 }));
43
44+ signals_conn_.Add(app_->starting.changed.connect([this](bool starting) {
45+ LOG_DEBUG(logger) << tooltip_text() << " starting now " << (starting ? "true" : "false");
46+ SetQuirk(Quirk::STARTING, starting);
47+ }));
48+
49 signals_conn_.Add(app_->active.changed.connect([this](bool active) {
50 LOG_DEBUG(logger) << tooltip_text() << " active now " << (active ? "true" : "false");
51 SetQuirk(Quirk::ACTIVE, active);
52
53=== modified file 'launcher/Launcher.cpp'
54--- launcher/Launcher.cpp 2016-03-18 01:47:08 +0000
55+++ launcher/Launcher.cpp 2016-03-21 15:21:52 +0000
56@@ -59,7 +59,7 @@
57 const int URGENT_BLINKS = 3;
58 const int WIGGLE_CYCLES = 6;
59
60-const int MAX_STARTING_BLINKS = 5;
61+const int MAX_STARTING_BLINKS = 15;
62 const int STARTING_BLINK_LAMBDA = 3;
63
64 const int PULSE_BLINK_LAMBDA = 2;
65
66=== modified file 'launcher/WindowedLauncherIcon.cpp'
67--- launcher/WindowedLauncherIcon.cpp 2015-12-08 18:28:09 +0000
68+++ launcher/WindowedLauncherIcon.cpp 2016-03-21 15:21:52 +0000
69@@ -60,6 +60,11 @@
70 return GetQuirk(Quirk::ACTIVE);
71 }
72
73+bool WindowedLauncherIcon::IsStarting() const
74+{
75+ return GetQuirk(Quirk::STARTING);
76+}
77+
78 bool WindowedLauncherIcon::IsRunning() const
79 {
80 return GetQuirk(Quirk::RUNNING);
81
82=== modified file 'launcher/WindowedLauncherIcon.h'
83--- launcher/WindowedLauncherIcon.h 2015-12-07 18:04:33 +0000
84+++ launcher/WindowedLauncherIcon.h 2016-03-21 15:21:52 +0000
85@@ -40,6 +40,7 @@
86 WindowList WindowsForMonitor(int monitor) override;
87
88 virtual bool IsActive() const;
89+ virtual bool IsStarting() const;
90 virtual bool IsRunning() const;
91 virtual bool IsUrgent() const;
92 virtual bool IsUserVisible() const;
93
94=== modified file 'unity-shared/ApplicationManager.h'
95--- unity-shared/ApplicationManager.h 2016-02-23 15:05:29 +0000
96+++ unity-shared/ApplicationManager.h 2016-03-21 15:21:52 +0000
97@@ -165,6 +165,7 @@
98 nux::ROProperty<bool> active;
99 nux::ROProperty<bool> running;
100 nux::ROProperty<bool> urgent;
101+ nux::ROProperty<bool> starting;
102
103 sigc::signal<void> closed;
104
105
106=== modified file 'unity-shared/BamfApplicationManager.cpp'
107--- unity-shared/BamfApplicationManager.cpp 2015-11-26 00:20:23 +0000
108+++ unity-shared/BamfApplicationManager.cpp 2016-03-21 15:21:52 +0000
109@@ -114,6 +114,11 @@
110 return bamf_view_is_urgent(bamf_view_);
111 }
112
113+bool View::GetStarting() const
114+{
115+ return bamf_view_is_starting(bamf_view_);
116+}
117+
118
119 WindowBase::WindowBase(ApplicationManager const& manager,
120 glib::Object<BamfView> const& window)
121@@ -303,6 +308,8 @@
122 active.SetGetterFunction(std::bind(&View::GetActive, this));
123 running.SetGetterFunction(std::bind(&View::GetRunning, this));
124 urgent.SetGetterFunction(std::bind(&View::GetUrgent, this));
125+ starting.SetGetterFunction(std::bind(&View::GetStarting, this));
126+
127
128 signals_.Add<void, BamfApplication*, const char*>(bamf_app_, "desktop-file-updated",
129 [this] (BamfApplication*, const char* new_desktop_file) {
130@@ -326,6 +333,13 @@
131 LOG_TRACE(logger) << "active-changed " << visible;
132 this->active.changed.emit(active);
133 });
134+
135+ signals_.Add<void, BamfView*, gboolean>(bamf_view_, "starting-changed",
136+ [this] (BamfView*, gboolean starting) {
137+ LOG_TRACE(logger) << "starting " << starting;
138+ this->starting.changed.emit(starting);
139+ });
140+
141 signals_.Add<void, BamfView*, gboolean>(bamf_view_, "running-changed",
142 [this] (BamfView*, gboolean running) {
143 LOG_TRACE(logger) << "running " << visible;
144
145=== modified file 'unity-shared/BamfApplicationManager.h'
146--- unity-shared/BamfApplicationManager.h 2015-11-25 23:16:11 +0000
147+++ unity-shared/BamfApplicationManager.h 2016-03-21 15:21:52 +0000
148@@ -45,6 +45,7 @@
149 bool GetActive() const;
150 bool GetRunning() const;
151 bool GetUrgent() const;
152+ bool GetStarting() const;
153
154 protected:
155 ApplicationManager const& manager_;