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

Side by Side Diff: chrome/browser/chromeos/login/ui/lock_window_aura.cc

Issue 662763002: Support modal windows (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git/+/master
Patch Set: fix leaks Created 6 years, 2 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chromeos/login/ui/lock_window_aura.h" 5 #include "chrome/browser/chromeos/login/ui/lock_window_aura.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/shell_window_ids.h" 8 #include "ash/shell_window_ids.h"
9 #include "ash/wm/window_animations.h" 9 #include "ash/wm/window_animations.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 views::Widget::InitParams params( 63 views::Widget::InitParams params(
64 views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); 64 views::Widget::InitParams::TYPE_WINDOW_FRAMELESS);
65 params.delegate = this; 65 params.delegate = this;
66 params.show_state = ui::SHOW_STATE_FULLSCREEN; 66 params.show_state = ui::SHOW_STATE_FULLSCREEN;
67 #if defined(USE_ATHENA) 67 #if defined(USE_ATHENA)
68 // Don't set TRANSLUCENT_WINDOW because we don't have wallpaper manager yet. 68 // Don't set TRANSLUCENT_WINDOW because we don't have wallpaper manager yet.
69 // TODO(dpolukhin): fix this code when crbug.com/408734 fixed. 69 // TODO(dpolukhin): fix this code when crbug.com/408734 fixed.
70 athena::ScreenManager::ContainerParams container_params( 70 athena::ScreenManager::ContainerParams container_params(
71 "LoginScreen", athena::CP_LOGIN_SCREEN); 71 "LoginScreen", athena::CP_LOGIN_SCREEN);
72 container_params.can_activate_children = true; 72 container_params.can_activate_children = true;
73 container_params.grab_inputs = true; 73 container_params.block_events = true;
74 container_params.modal_container_priority =
75 athena::CP_LOGIN_SCREEN_SYSTEM_MODAL;
74 lock_screen_container_.reset( 76 lock_screen_container_.reset(
75 athena::ScreenManager::Get()->CreateContainer(container_params)); 77 athena::ScreenManager::Get()->CreateContainer(container_params));
76 params.parent = lock_screen_container_.get(); 78 params.parent = lock_screen_container_.get();
77 lock_screen_container_->SetLayoutManager( 79 lock_screen_container_->SetLayoutManager(
78 new athena::FillLayoutManager(lock_screen_container_.get())); 80 new athena::FillLayoutManager(lock_screen_container_.get()));
79 #else 81 #else
80 params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; 82 params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW;
81 // TODO(oshima): move the lock screen harness to ash. 83 // TODO(oshima): move the lock screen harness to ash.
82 params.parent = 84 params.parent =
83 ash::Shell::GetContainer(ash::Shell::GetPrimaryRootWindow(), 85 ash::Shell::GetContainer(ash::Shell::GetPrimaryRootWindow(),
84 ash::kShellWindowId_LockScreenContainer); 86 ash::kShellWindowId_LockScreenContainer);
85 #endif 87 #endif
86 views::Widget::Init(params); 88 views::Widget::Init(params);
87 wm::SetWindowVisibilityAnimationTransition( 89 wm::SetWindowVisibilityAnimationTransition(
88 GetNativeView(), wm::ANIMATE_NONE); 90 GetNativeView(), wm::ANIMATE_NONE);
89 } 91 }
90 92
91 } // namespace chromeos 93 } // namespace chromeos
OLDNEW
« no previous file with comments | « athena/wm/window_manager_unittest.cc ('k') | chrome/browser/chromeos/login/ui/login_display_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698