summaryrefslogtreecommitdiff
diff options
authorAndrea Azzarone <azzaronea@gmail.com>2014-03-05 14:04:06 +0100
committerAndrea Azzarone <azzaronea@gmail.com>2014-03-05 14:04:06 +0100
commitd992585c2323aa05fd53d86e485ee53f0db13241 (patch)
tree61af8a93510c9333c7684247c3b3c3ddcf042b61
parent8243abd39ceddc1daae6080ab04c1fc04e0663bf (diff)
Minor change.
(bzr r3566.5.453)
-rw-r--r--lockscreen/LockScreenShield.cpp16
-rw-r--r--lockscreen/LockScreenShield.h2
2 files changed, 10 insertions, 8 deletions
diff --git a/lockscreen/LockScreenShield.cpp b/lockscreen/LockScreenShield.cpp
index e96778307..9ecf4f16e 100644
--- a/lockscreen/LockScreenShield.cpp
+++ b/lockscreen/LockScreenShield.cpp
@@ -74,7 +74,9 @@ void Shield::ShowPrimaryView()
nux::HLayout* prompt_layout = new nux::HLayout();
prompt_layout->SetLeftAndRightPadding(2 * Settings::GRID_SIZE);
- prompt_layout->AddView(CreatePromptView());
+
+ prompt_view_ = CreatePromptView();
+ prompt_layout->AddView(prompt_view_);
// 10 is just a random number to center the prompt view.
main_layout->AddSpace(0, 10);
@@ -109,18 +111,18 @@ nux::View* Shield::CreatePanel()
return panel_view;
}
-nux::View* Shield::CreatePromptView()
+UserPromptView* Shield::CreatePromptView()
{
- prompt_view_ = new UserPromptView(session_manager_);
+ auto* prompt_view = new UserPromptView(session_manager_);
auto width = 8 * Settings::GRID_SIZE;
auto height = 3 * Settings::GRID_SIZE;
- prompt_view_->SetMinimumWidth(width);
- prompt_view_->SetMaximumWidth(width);
- prompt_view_->SetMinimumHeight(height);
+ prompt_view->SetMinimumWidth(width);
+ prompt_view->SetMaximumWidth(width);
+ prompt_view->SetMinimumHeight(height);
- return prompt_view_;
+ return prompt_view;
}
void Shield::OnIndicatorEntryShowMenu(std::string const&, unsigned, int, int, unsigned)
diff --git a/lockscreen/LockScreenShield.h b/lockscreen/LockScreenShield.h
index c37e6ab0e..8265becaf 100644
--- a/lockscreen/LockScreenShield.h
+++ b/lockscreen/LockScreenShield.h
@@ -53,7 +53,7 @@ private:
void ShowPrimaryView();
void ShowSecondaryView();
nux::View* CreatePanel();
- nux::View* CreatePromptView();
+ UserPromptView* CreatePromptView();
void OnIndicatorEntryShowMenu(std::string const&, unsigned, int, int, unsigned);
void OnIndicatorEntryActivated(std::string const& panel, std::string const& entry, nux::Geometry const& geo);