Merge lp:~azzar1/unity/fix-1308540 into lp:unity
- fix-1308540
- Merge into trunk
Status: | Merged |
---|---|
Approved by: | Marco Trevisan (Treviño) |
Approved revision: | no longer in the source branch. |
Merged at revision: | 3863 |
Proposed branch: | lp:~azzar1/unity/fix-1308540 |
Merge into: | lp:unity |
Diff against target: |
347 lines (+83/-33) 8 files modified
lockscreen/LockScreenAbstractShield.h (+9/-1) lockscreen/LockScreenController.cpp (+18/-1) lockscreen/LockScreenController.h (+5/-0) lockscreen/LockScreenShield.cpp (+17/-22) lockscreen/LockScreenShield.h (+6/-3) lockscreen/LockScreenShieldFactory.cpp (+7/-2) lockscreen/LockScreenShieldFactory.h (+12/-2) tests/test_lockscreen_controller.cpp (+9/-2) |
To merge this branch: | bzr merge lp:~azzar1/unity/fix-1308540 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Marco Trevisan (Treviño) | Approve | ||
PS Jenkins bot (community) | continuous-integration | Approve | |
Review via email: mp+226455@code.launchpad.net |
Commit message
Share lockscreen password entry between screens.
Description of the change
== Problem ==
[lockscreen] the password entry is not shared between screens
== Fix ==
Share the UserPromptView object between the shields.
PS Jenkins bot (ps-jenkins) wrote : | # |
Marco Trevisan (Treviño) (3v1n0) wrote : | # |
Mostly looks fine, just check these two comments...
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3839
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https:/
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3840
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https:/
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3841
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
Marco Trevisan (Treviño) (3v1n0) wrote : | # |
You also need http://
Andrea Azzarone (azzar1) wrote : | # |
> You also need http://
> build, sad but true :/
Done!
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3842
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3842
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:3843
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
Marco Trevisan (Treviño) (3v1n0) wrote : | # |
It seems there's a compile error here: http://
Marco Trevisan (Treviño) (3v1n0) wrote : | # |
(I guess there's another prompt_view_ defined as a simple pointer inside the actual Shield header)
Andrea Azzarone (azzar1) wrote : | # |
Should work now!
PS Jenkins bot (ps-jenkins) wrote : | # |
PASSED: Continuous integration, rev:3843
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
Preview Diff
1 | === modified file 'lockscreen/LockScreenAbstractShield.h' | |||
2 | --- lockscreen/LockScreenAbstractShield.h 2014-06-05 19:48:27 +0000 | |||
3 | +++ lockscreen/LockScreenAbstractShield.h 2014-08-27 13:25:30 +0000 | |||
4 | @@ -32,16 +32,23 @@ | |||
5 | 32 | namespace lockscreen | 32 | namespace lockscreen |
6 | 33 | { | 33 | { |
7 | 34 | 34 | ||
8 | 35 | class UserPromptView; | ||
9 | 36 | |||
10 | 35 | class AbstractShield : public MockableBaseWindow | 37 | class AbstractShield : public MockableBaseWindow |
11 | 36 | { | 38 | { |
12 | 37 | public: | 39 | public: |
14 | 38 | AbstractShield(session::Manager::Ptr const& session, indicator::Indicators::Ptr const& indicators, Accelerators::Ptr const& accelerators, int monitor_num, bool is_primary) | 40 | AbstractShield(session::Manager::Ptr const& session, |
15 | 41 | indicator::Indicators::Ptr const& indicators, | ||
16 | 42 | Accelerators::Ptr const& accelerators, | ||
17 | 43 | nux::ObjectPtr<UserPromptView> const& prompt_view, | ||
18 | 44 | int monitor_num, bool is_primary) | ||
19 | 39 | : MockableBaseWindow("Unity Lockscreen") | 45 | : MockableBaseWindow("Unity Lockscreen") |
20 | 40 | , primary(is_primary) | 46 | , primary(is_primary) |
21 | 41 | , monitor(monitor_num) | 47 | , monitor(monitor_num) |
22 | 42 | , session_manager_(session) | 48 | , session_manager_(session) |
23 | 43 | , indicators_(indicators) | 49 | , indicators_(indicators) |
24 | 44 | , accelerators_(accelerators) | 50 | , accelerators_(accelerators) |
25 | 51 | , prompt_view_(prompt_view) | ||
26 | 45 | {} | 52 | {} |
27 | 46 | 53 | ||
28 | 47 | nux::Property<bool> primary; | 54 | nux::Property<bool> primary; |
29 | @@ -58,6 +65,7 @@ | |||
30 | 58 | session::Manager::Ptr session_manager_; | 65 | session::Manager::Ptr session_manager_; |
31 | 59 | indicator::Indicators::Ptr indicators_; | 66 | indicator::Indicators::Ptr indicators_; |
32 | 60 | Accelerators::Ptr accelerators_; | 67 | Accelerators::Ptr accelerators_; |
33 | 68 | nux::ObjectPtr<UserPromptView> prompt_view_; | ||
34 | 61 | }; | 69 | }; |
35 | 62 | 70 | ||
36 | 63 | } // lockscreen | 71 | } // lockscreen |
37 | 64 | 72 | ||
38 | === modified file 'lockscreen/LockScreenController.cpp' | |||
39 | --- lockscreen/LockScreenController.cpp 2014-07-30 18:33:31 +0000 | |||
40 | +++ lockscreen/LockScreenController.cpp 2014-08-27 13:25:30 +0000 | |||
41 | @@ -24,6 +24,7 @@ | |||
42 | 24 | 24 | ||
43 | 25 | #include "LockScreenShield.h" | 25 | #include "LockScreenShield.h" |
44 | 26 | #include "LockScreenSettings.h" | 26 | #include "LockScreenSettings.h" |
45 | 27 | #include "UserPromptView.h" | ||
46 | 27 | #include "unity-shared/AnimationUtils.h" | 28 | #include "unity-shared/AnimationUtils.h" |
47 | 28 | #include "unity-shared/UScreen.h" | 29 | #include "unity-shared/UScreen.h" |
48 | 29 | #include "unity-shared/WindowManager.h" | 30 | #include "unity-shared/WindowManager.h" |
49 | @@ -154,6 +155,20 @@ | |||
50 | 154 | primary_shield_->ActivatePanel(); | 155 | primary_shield_->ActivatePanel(); |
51 | 155 | } | 156 | } |
52 | 156 | 157 | ||
53 | 158 | UserPromptView* Controller::CreatePromptView() | ||
54 | 159 | { | ||
55 | 160 | auto* prompt_view = new UserPromptView(session_manager_); | ||
56 | 161 | |||
57 | 162 | auto width = 8 * Settings::GRID_SIZE; | ||
58 | 163 | auto height = 3 * Settings::GRID_SIZE; | ||
59 | 164 | |||
60 | 165 | prompt_view->SetMinimumWidth(width); | ||
61 | 166 | prompt_view->SetMaximumWidth(width); | ||
62 | 167 | prompt_view->SetMinimumHeight(height); | ||
63 | 168 | |||
64 | 169 | return prompt_view; | ||
65 | 170 | } | ||
66 | 171 | |||
67 | 157 | void Controller::ResetPostLockScreenSaver() | 172 | void Controller::ResetPostLockScreenSaver() |
68 | 158 | { | 173 | { |
69 | 159 | screensaver_post_lock_timeout_.reset(); | 174 | screensaver_post_lock_timeout_.reset(); |
70 | @@ -192,6 +207,8 @@ | |||
71 | 192 | 207 | ||
72 | 193 | shields_.resize(num_monitors); | 208 | shields_.resize(num_monitors); |
73 | 194 | 209 | ||
74 | 210 | prompt_view_ = test_mode_ ? nullptr : CreatePromptView(); | ||
75 | 211 | |||
76 | 195 | for (int i = 0; i < num_monitors; ++i) | 212 | for (int i = 0; i < num_monitors; ++i) |
77 | 196 | { | 213 | { |
78 | 197 | auto& shield = shields_[i]; | 214 | auto& shield = shields_[i]; |
79 | @@ -199,7 +216,7 @@ | |||
80 | 199 | 216 | ||
81 | 200 | if (i >= shields_size) | 217 | if (i >= shields_size) |
82 | 201 | { | 218 | { |
84 | 202 | shield = shield_factory_->CreateShield(session_manager_, indicators_, accelerator_controller_->GetAccelerators(), i, i == primary); | 219 | shield = shield_factory_->CreateShield(session_manager_, indicators_, accelerator_controller_->GetAccelerators(), prompt_view_, i, i == primary); |
85 | 203 | is_new = true; | 220 | is_new = true; |
86 | 204 | } | 221 | } |
87 | 205 | 222 | ||
88 | 206 | 223 | ||
89 | === modified file 'lockscreen/LockScreenController.h' | |||
90 | --- lockscreen/LockScreenController.h 2014-05-20 11:49:40 +0000 | |||
91 | +++ lockscreen/LockScreenController.h 2014-08-27 13:25:30 +0000 | |||
92 | @@ -27,6 +27,7 @@ | |||
93 | 27 | #include "LockScreenShieldFactory.h" | 27 | #include "LockScreenShieldFactory.h" |
94 | 28 | #include "LockScreenAcceleratorController.h" | 28 | #include "LockScreenAcceleratorController.h" |
95 | 29 | #include "ScreenSaverDBusManager.h" | 29 | #include "ScreenSaverDBusManager.h" |
96 | 30 | #include "UserPromptView.h" | ||
97 | 30 | #include "unity-shared/BackgroundEffectHelper.h" | 31 | #include "unity-shared/BackgroundEffectHelper.h" |
98 | 31 | #include "unity-shared/UpstartWrapper.h" | 32 | #include "unity-shared/UpstartWrapper.h" |
99 | 32 | 33 | ||
100 | @@ -35,6 +36,8 @@ | |||
101 | 35 | namespace lockscreen | 36 | namespace lockscreen |
102 | 36 | { | 37 | { |
103 | 37 | 38 | ||
104 | 39 | class UserPromptView; | ||
105 | 40 | |||
106 | 38 | class Controller : public sigc::trackable | 41 | class Controller : public sigc::trackable |
107 | 39 | { | 42 | { |
108 | 40 | public: | 43 | public: |
109 | @@ -51,6 +54,7 @@ | |||
110 | 51 | private: | 54 | private: |
111 | 52 | friend class TestLockScreenController; | 55 | friend class TestLockScreenController; |
112 | 53 | 56 | ||
113 | 57 | UserPromptView* CreatePromptView(); | ||
114 | 54 | void EnsureShields(std::vector<nux::Geometry> const& monitors); | 58 | void EnsureShields(std::vector<nux::Geometry> const& monitors); |
115 | 55 | void EnsureBlankWindow(); | 59 | void EnsureBlankWindow(); |
116 | 56 | void LockScreen(); | 60 | void LockScreen(); |
117 | @@ -79,6 +83,7 @@ | |||
118 | 79 | AcceleratorController::Ptr accelerator_controller_; | 83 | AcceleratorController::Ptr accelerator_controller_; |
119 | 80 | UpstartWrapper::Ptr upstart_wrapper_; | 84 | UpstartWrapper::Ptr upstart_wrapper_; |
120 | 81 | ShieldFactoryInterface::Ptr shield_factory_; | 85 | ShieldFactoryInterface::Ptr shield_factory_; |
121 | 86 | nux::ObjectPtr<UserPromptView> prompt_view_; | ||
122 | 82 | 87 | ||
123 | 83 | nux::animation::AnimateValue<double> fade_animator_; | 88 | nux::animation::AnimateValue<double> fade_animator_; |
124 | 84 | nux::animation::AnimateValue<double> blank_window_animator_; | 89 | nux::animation::AnimateValue<double> blank_window_animator_; |
125 | 85 | 90 | ||
126 | === modified file 'lockscreen/LockScreenShield.cpp' | |||
127 | --- lockscreen/LockScreenShield.cpp 2014-07-30 20:10:23 +0000 | |||
128 | +++ lockscreen/LockScreenShield.cpp 2014-08-27 13:25:30 +0000 | |||
129 | @@ -42,10 +42,13 @@ | |||
130 | 42 | const unsigned MAX_GRAB_WAIT = 50; | 42 | const unsigned MAX_GRAB_WAIT = 50; |
131 | 43 | } | 43 | } |
132 | 44 | 44 | ||
135 | 45 | Shield::Shield(session::Manager::Ptr const& session_manager, indicator::Indicators::Ptr const& indicators, Accelerators::Ptr const& accelerators, int monitor_num, bool is_primary) | 45 | Shield::Shield(session::Manager::Ptr const& session_manager, |
136 | 46 | : AbstractShield(session_manager, indicators, accelerators, monitor_num, is_primary) | 46 | indicator::Indicators::Ptr const& indicators, |
137 | 47 | Accelerators::Ptr const& accelerators, | ||
138 | 48 | nux::ObjectPtr<UserPromptView> const& prompt_view, | ||
139 | 49 | int monitor_num, bool is_primary) | ||
140 | 50 | : AbstractShield(session_manager, indicators, accelerators, prompt_view, monitor_num, is_primary) | ||
141 | 47 | , bg_settings_(std::make_shared<BackgroundSettings>()) | 51 | , bg_settings_(std::make_shared<BackgroundSettings>()) |
142 | 48 | , prompt_view_(nullptr) | ||
143 | 49 | , panel_view_(nullptr) | 52 | , panel_view_(nullptr) |
144 | 50 | { | 53 | { |
145 | 51 | is_primary ? ShowPrimaryView() : ShowSecondaryView(); | 54 | is_primary ? ShowPrimaryView() : ShowSecondaryView(); |
146 | @@ -117,6 +120,11 @@ | |||
147 | 117 | if (primary_layout_) | 120 | if (primary_layout_) |
148 | 118 | { | 121 | { |
149 | 119 | GrabScreen(false); | 122 | GrabScreen(false); |
150 | 123 | |||
151 | 124 | if (prompt_view_ && prompt_view_->GetParentObject()) | ||
152 | 125 | static_cast<nux::Layout*>(prompt_view_->GetParentObject())->RemoveChildObject(prompt_view_.GetPointer()); | ||
153 | 126 | prompt_layout_->AddView(prompt_view_.GetPointer()); | ||
154 | 127 | |||
155 | 120 | SetLayout(primary_layout_.GetPointer()); | 128 | SetLayout(primary_layout_.GetPointer()); |
156 | 121 | return; | 129 | return; |
157 | 122 | } | 130 | } |
158 | @@ -128,15 +136,16 @@ | |||
159 | 128 | 136 | ||
160 | 129 | main_layout->AddView(CreatePanel()); | 137 | main_layout->AddView(CreatePanel()); |
161 | 130 | 138 | ||
164 | 131 | nux::HLayout* prompt_layout = new nux::HLayout(); | 139 | prompt_layout_ = new nux::HLayout(); |
165 | 132 | prompt_layout->SetLeftAndRightPadding(2 * Settings::GRID_SIZE); | 140 | prompt_layout_->SetLeftAndRightPadding(2 * Settings::GRID_SIZE); |
166 | 133 | 141 | ||
169 | 134 | prompt_view_ = CreatePromptView(); | 142 | if (prompt_view_ && prompt_view_->GetParentObject()) |
170 | 135 | prompt_layout->AddView(prompt_view_); | 143 | static_cast<nux::Layout*>(prompt_view_->GetParentObject())->RemoveChildObject(prompt_view_.GetPointer()); |
171 | 144 | prompt_layout_->AddView(prompt_view_.GetPointer()); | ||
172 | 136 | 145 | ||
173 | 137 | // 10 is just a random number to center the prompt view. | 146 | // 10 is just a random number to center the prompt view. |
174 | 138 | main_layout->AddSpace(0, 10); | 147 | main_layout->AddSpace(0, 10); |
176 | 139 | main_layout->AddLayout(prompt_layout); | 148 | main_layout->AddLayout(prompt_layout_.GetPointer()); |
177 | 140 | main_layout->AddSpace(0, 10); | 149 | main_layout->AddSpace(0, 10); |
178 | 141 | } | 150 | } |
179 | 142 | 151 | ||
180 | @@ -182,20 +191,6 @@ | |||
181 | 182 | return panel_view_; | 191 | return panel_view_; |
182 | 183 | } | 192 | } |
183 | 184 | 193 | ||
184 | 185 | UserPromptView* Shield::CreatePromptView() | ||
185 | 186 | { | ||
186 | 187 | auto* prompt_view = new UserPromptView(session_manager_); | ||
187 | 188 | |||
188 | 189 | auto width = 8 * Settings::GRID_SIZE; | ||
189 | 190 | auto height = 3 * Settings::GRID_SIZE; | ||
190 | 191 | |||
191 | 192 | prompt_view->SetMinimumWidth(width); | ||
192 | 193 | prompt_view->SetMaximumWidth(width); | ||
193 | 194 | prompt_view->SetMinimumHeight(height); | ||
194 | 195 | |||
195 | 196 | return prompt_view; | ||
196 | 197 | } | ||
197 | 198 | |||
198 | 199 | nux::Area* Shield::FindKeyFocusArea(unsigned etype, unsigned long keysym, unsigned long modifiers) | 194 | nux::Area* Shield::FindKeyFocusArea(unsigned etype, unsigned long keysym, unsigned long modifiers) |
199 | 200 | { | 195 | { |
200 | 201 | if (primary) | 196 | if (primary) |
201 | 202 | 197 | ||
202 | === modified file 'lockscreen/LockScreenShield.h' | |||
203 | --- lockscreen/LockScreenShield.h 2014-07-30 18:33:31 +0000 | |||
204 | +++ lockscreen/LockScreenShield.h 2014-08-27 13:25:30 +0000 | |||
205 | @@ -37,7 +37,11 @@ | |||
206 | 37 | class Shield : public AbstractShield | 37 | class Shield : public AbstractShield |
207 | 38 | { | 38 | { |
208 | 39 | public: | 39 | public: |
210 | 40 | Shield(session::Manager::Ptr const&, indicator::Indicators::Ptr const&, Accelerators::Ptr const&, int monitor, bool is_primary); | 40 | Shield(session::Manager::Ptr const&, |
211 | 41 | indicator::Indicators::Ptr const&, | ||
212 | 42 | Accelerators::Ptr const&, | ||
213 | 43 | nux::ObjectPtr<UserPromptView> const&, | ||
214 | 44 | int monitor, bool is_primary); | ||
215 | 41 | 45 | ||
216 | 42 | bool IsIndicatorOpen() const override; | 46 | bool IsIndicatorOpen() const override; |
217 | 43 | void ActivatePanel() override; | 47 | void ActivatePanel() override; |
218 | @@ -53,16 +57,15 @@ | |||
219 | 53 | void ShowPrimaryView(); | 57 | void ShowPrimaryView(); |
220 | 54 | void ShowSecondaryView(); | 58 | void ShowSecondaryView(); |
221 | 55 | Panel* CreatePanel(); | 59 | Panel* CreatePanel(); |
222 | 56 | UserPromptView* CreatePromptView(); | ||
223 | 57 | 60 | ||
224 | 58 | std::shared_ptr<BackgroundSettings> bg_settings_; | 61 | std::shared_ptr<BackgroundSettings> bg_settings_; |
225 | 59 | std::unique_ptr<nux::AbstractPaintLayer> background_layer_; | 62 | std::unique_ptr<nux::AbstractPaintLayer> background_layer_; |
226 | 60 | nux::ObjectPtr<nux::Layout> primary_layout_; | 63 | nux::ObjectPtr<nux::Layout> primary_layout_; |
227 | 64 | nux::ObjectPtr<nux::Layout> prompt_layout_; | ||
228 | 61 | nux::ObjectPtr<nux::Layout> cof_layout_; | 65 | nux::ObjectPtr<nux::Layout> cof_layout_; |
229 | 62 | connection::Wrapper panel_active_conn_; | 66 | connection::Wrapper panel_active_conn_; |
230 | 63 | connection::Wrapper regrab_conn_; | 67 | connection::Wrapper regrab_conn_; |
231 | 64 | glib::Source::UniquePtr regrab_timeout_; | 68 | glib::Source::UniquePtr regrab_timeout_; |
232 | 65 | UserPromptView* prompt_view_; | ||
233 | 66 | Panel* panel_view_; | 69 | Panel* panel_view_; |
234 | 67 | }; | 70 | }; |
235 | 68 | 71 | ||
236 | 69 | 72 | ||
237 | === modified file 'lockscreen/LockScreenShieldFactory.cpp' | |||
238 | --- lockscreen/LockScreenShieldFactory.cpp 2014-04-17 13:08:05 +0000 | |||
239 | +++ lockscreen/LockScreenShieldFactory.cpp 2014-08-27 13:25:30 +0000 | |||
240 | @@ -19,15 +19,20 @@ | |||
241 | 19 | 19 | ||
242 | 20 | #include "LockScreenShieldFactory.h" | 20 | #include "LockScreenShieldFactory.h" |
243 | 21 | #include "LockScreenShield.h" | 21 | #include "LockScreenShield.h" |
244 | 22 | #include "UserPromptView.h" | ||
245 | 22 | 23 | ||
246 | 23 | namespace unity | 24 | namespace unity |
247 | 24 | { | 25 | { |
248 | 25 | namespace lockscreen | 26 | namespace lockscreen |
249 | 26 | { | 27 | { |
250 | 27 | 28 | ||
252 | 28 | nux::ObjectPtr<AbstractShield> ShieldFactory::CreateShield(session::Manager::Ptr const& session_manager, indicator::Indicators::Ptr const& indicators, Accelerators::Ptr const& accelerators, int monitor, bool is_primary) | 29 | nux::ObjectPtr<AbstractShield> ShieldFactory::CreateShield(session::Manager::Ptr const& session_manager, |
253 | 30 | indicator::Indicators::Ptr const& indicators, | ||
254 | 31 | Accelerators::Ptr const& accelerators, | ||
255 | 32 | nux::ObjectPtr<UserPromptView> const& prompt_view, | ||
256 | 33 | int monitor, bool is_primary) | ||
257 | 29 | { | 34 | { |
259 | 30 | return nux::ObjectPtr<Shield>(new Shield(session_manager, indicators, accelerators, monitor, is_primary)); | 35 | return nux::ObjectPtr<Shield>(new Shield(session_manager, indicators, accelerators, prompt_view, monitor, is_primary)); |
260 | 31 | } | 36 | } |
261 | 32 | 37 | ||
262 | 33 | } | 38 | } |
263 | 34 | 39 | ||
264 | === modified file 'lockscreen/LockScreenShieldFactory.h' | |||
265 | --- lockscreen/LockScreenShieldFactory.h 2014-04-17 13:08:05 +0000 | |||
266 | +++ lockscreen/LockScreenShieldFactory.h 2014-08-27 13:25:30 +0000 | |||
267 | @@ -31,18 +31,28 @@ | |||
268 | 31 | namespace lockscreen | 31 | namespace lockscreen |
269 | 32 | { | 32 | { |
270 | 33 | 33 | ||
271 | 34 | class UserPromptView; | ||
272 | 35 | |||
273 | 34 | struct ShieldFactoryInterface | 36 | struct ShieldFactoryInterface |
274 | 35 | { | 37 | { |
275 | 36 | typedef std::shared_ptr<ShieldFactoryInterface> Ptr; | 38 | typedef std::shared_ptr<ShieldFactoryInterface> Ptr; |
276 | 37 | 39 | ||
277 | 38 | virtual ~ShieldFactoryInterface() = default; | 40 | virtual ~ShieldFactoryInterface() = default; |
278 | 39 | 41 | ||
280 | 40 | virtual nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, indicator::Indicators::Ptr const&, Accelerators::Ptr const&, int monitor, bool is_primary) = 0; | 42 | virtual nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, |
281 | 43 | indicator::Indicators::Ptr const&, | ||
282 | 44 | Accelerators::Ptr const&, | ||
283 | 45 | nux::ObjectPtr<UserPromptView> const&, | ||
284 | 46 | int monitor, bool is_primary) = 0; | ||
285 | 41 | }; | 47 | }; |
286 | 42 | 48 | ||
287 | 43 | struct ShieldFactory : ShieldFactoryInterface | 49 | struct ShieldFactory : ShieldFactoryInterface |
288 | 44 | { | 50 | { |
290 | 45 | nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, indicator::Indicators::Ptr const&, Accelerators::Ptr const&, int monitor, bool is_primary) override; | 51 | nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, |
291 | 52 | indicator::Indicators::Ptr const&, | ||
292 | 53 | Accelerators::Ptr const&, | ||
293 | 54 | nux::ObjectPtr<UserPromptView> const&, | ||
294 | 55 | int monitor, bool is_primary) override; | ||
295 | 46 | }; | 56 | }; |
296 | 47 | 57 | ||
297 | 48 | } | 58 | } |
298 | 49 | 59 | ||
299 | === modified file 'tests/test_lockscreen_controller.cpp' | |||
300 | --- tests/test_lockscreen_controller.cpp 2014-06-07 16:26:59 +0000 | |||
301 | +++ tests/test_lockscreen_controller.cpp 2014-08-27 13:25:30 +0000 | |||
302 | @@ -20,6 +20,7 @@ | |||
303 | 20 | #include <gmock/gmock.h> | 20 | #include <gmock/gmock.h> |
304 | 21 | using namespace testing; | 21 | using namespace testing; |
305 | 22 | 22 | ||
306 | 23 | #include "lockscreen/UserPromptView.h" | ||
307 | 23 | #include "lockscreen/LockScreenController.h" | 24 | #include "lockscreen/LockScreenController.h" |
308 | 24 | 25 | ||
309 | 25 | #include <Nux/NuxTimerTickSource.h> | 26 | #include <Nux/NuxTimerTickSource.h> |
310 | @@ -29,6 +30,7 @@ | |||
311 | 29 | 30 | ||
312 | 30 | #include "lockscreen/LockScreenSettings.h" | 31 | #include "lockscreen/LockScreenSettings.h" |
313 | 31 | #include "lockscreen/ScreenSaverDBusManager.h" | 32 | #include "lockscreen/ScreenSaverDBusManager.h" |
314 | 33 | #include "unity-shared/DashStyle.h" | ||
315 | 32 | #include "unity-shared/PanelStyle.h" | 34 | #include "unity-shared/PanelStyle.h" |
316 | 33 | #include "unity-shared/UScreen.h" | 35 | #include "unity-shared/UScreen.h" |
317 | 34 | #include "test_mock_session_manager.h" | 36 | #include "test_mock_session_manager.h" |
318 | @@ -52,7 +54,7 @@ | |||
319 | 52 | struct MockShield : AbstractShield | 54 | struct MockShield : AbstractShield |
320 | 53 | { | 55 | { |
321 | 54 | MockShield() | 56 | MockShield() |
323 | 55 | : AbstractShield(nullptr, nullptr, nullptr, 0, false) | 57 | : AbstractShield(nullptr, nullptr, nullptr, nux::ObjectPtr<UserPromptView>(), 0, false) |
324 | 56 | {} | 58 | {} |
325 | 57 | 59 | ||
326 | 58 | MOCK_CONST_METHOD0(IsIndicatorOpen, bool()); | 60 | MOCK_CONST_METHOD0(IsIndicatorOpen, bool()); |
327 | @@ -61,7 +63,11 @@ | |||
328 | 61 | 63 | ||
329 | 62 | struct ShieldFactoryMock : ShieldFactoryInterface | 64 | struct ShieldFactoryMock : ShieldFactoryInterface |
330 | 63 | { | 65 | { |
332 | 64 | nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, indicator::Indicators::Ptr const&, Accelerators::Ptr const&, int, bool) override | 66 | nux::ObjectPtr<AbstractShield> CreateShield(session::Manager::Ptr const&, |
333 | 67 | indicator::Indicators::Ptr const&, | ||
334 | 68 | Accelerators::Ptr const&, | ||
335 | 69 | nux::ObjectPtr<UserPromptView> const&, | ||
336 | 70 | int, bool) override | ||
337 | 65 | { | 71 | { |
338 | 66 | return nux::ObjectPtr<AbstractShield>(new MockShield()); | 72 | return nux::ObjectPtr<AbstractShield>(new MockShield()); |
339 | 67 | } | 73 | } |
340 | @@ -95,6 +101,7 @@ | |||
341 | 95 | nux::animation::AnimationController animation_controller; | 101 | nux::animation::AnimationController animation_controller; |
342 | 96 | 102 | ||
343 | 97 | MockUScreen uscreen; | 103 | MockUScreen uscreen; |
344 | 104 | unity::dash::Style dash_style; | ||
345 | 98 | unity::panel::Style panel_style; | 105 | unity::panel::Style panel_style; |
346 | 99 | unity::lockscreen::Settings lockscreen_settings; | 106 | unity::lockscreen::Settings lockscreen_settings; |
347 | 100 | session::MockManager::Ptr session_manager; | 107 | session::MockManager::Ptr session_manager; |
FAILED: Continuous integration, rev:3791 /code.launchpad .net/~andyrock/ unity/fix- 1308540/ +merge/ 226455/ +edit-commit- message
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https:/
http:// jenkins. qa.ubuntu. com/job/ unity-ci/ 1021/ jenkins. qa.ubuntu. com/job/ unity-utopic- amd64-ci/ 108/console jenkins. qa.ubuntu. com/job/ unity-utopic- armhf-ci/ 108/console jenkins. qa.ubuntu. com/job/ unity-utopic- i386-ci/ 108/console
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild: s-jenkins. ubuntu- ci:8080/ job/unity- ci/1021/ rebuild
http://