Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(88)

Side by Side Diff: ash/login/views/lock_contents_view.cc

Issue 2873433005: cros: Move ash/login/views to ash/login/ui (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ash/login/views/lock_contents_view.h ('k') | ash/login/views/lock_screen.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "ash/login/views/lock_contents_view.h"
6
7 #include "base/strings/utf_string_conversions.h"
8 #include "ui/views/background.h"
9 #include "ui/views/border.h"
10 #include "ui/views/layout/box_layout.h"
11
12 namespace ash {
13
14 LockContentsView::LockContentsView() {
15 auto* layout = new views::BoxLayout(views::BoxLayout::kVertical, 0, 0, 0);
16 SetLayoutManager(layout);
17
18 views::Label* label = new views::Label();
19 label->SetBorder(views::CreateEmptyBorder(2, 3, 4, 5));
20 label->set_background(views::Background::CreateThemedSolidBackground(
21 label, ui::NativeTheme::kColorId_BubbleBackground));
22 label->SetText(base::ASCIIToUTF16("User"));
23 AddChildView(label);
24
25 unlock_button_ =
26 views::MdTextButton::Create(this, base::ASCIIToUTF16("Unlock"));
27 AddChildView(unlock_button_);
28 }
29
30 LockContentsView::~LockContentsView() {}
31
32 void LockContentsView::ButtonPressed(views::Button* sender,
33 const ui::Event& event) {
34 DCHECK(unlock_button_ == sender);
35
36 // TODO: Run mojo call that talks to backend which unlocks the device.
37 NOTIMPLEMENTED();
38 }
39
40 } // namespace ash
OLDNEW
« no previous file with comments | « ash/login/views/lock_contents_view.h ('k') | ash/login/views/lock_screen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698