| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/ui/views/chrome_views_delegate.h" | 5 #include "chrome/browser/ui/views/chrome_views_delegate.h" |
| 6 | 6 |
| 7 #include "base/time/time.h" |
| 8 #include "chrome/browser/chromeos/ui/password_echo_controller.h" |
| 9 |
| 7 views::Widget::InitParams::WindowOpacity | 10 views::Widget::InitParams::WindowOpacity |
| 8 ChromeViewsDelegate::GetOpacityForInitParams( | 11 ChromeViewsDelegate::GetOpacityForInitParams( |
| 9 const views::Widget::InitParams& params) { | 12 const views::Widget::InitParams& params) { |
| 10 return views::Widget::InitParams::TRANSLUCENT_WINDOW; | 13 return views::Widget::InitParams::TRANSLUCENT_WINDOW; |
| 11 } | 14 } |
| 15 |
| 16 base::TimeDelta ChromeViewsDelegate::GetTextfieldPasswordRevealDuration() { |
| 17 const base::TimeDelta kTextfieldPasswordRevealDuration = |
| 18 base::TimeDelta::FromSeconds(1); |
| 19 chromeos::PasswordEchoController* const controller = |
| 20 chromeos::PasswordEchoController::Get(); |
| 21 return controller && controller->enabled() ? kTextfieldPasswordRevealDuration |
| 22 : base::TimeDelta(); |
| 23 } |
| OLD | NEW |