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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_AUTOFILL_PASSWORD_GENERATION_POPUP_VIEW_H_
6 #define CHROME_BROWSER_UI_AUTOFILL_PASSWORD_GENERATION_POPUP_VIEW_H_
8 #include "third_party/skia/include/core/SkColor.h"
12 class PasswordGenerationPopupController
;
14 // Interface for creating and controlling a platform dependent view.
15 class PasswordGenerationPopupView
{
17 // This is the amount of vertical whitespace that is left above and below the
18 // password when it is highlighted.
19 static const int kPasswordVerticalInset
= 7;
22 virtual void Show() = 0;
24 // This will cause the popup to be deleted.
25 virtual void Hide() = 0;
27 // Updates layout information from the controller.
28 virtual void UpdateBoundsAndRedrawPopup() = 0;
30 // Called when the password selection state has changed.
31 virtual void PasswordSelectionUpdated() = 0;
33 // Note that PasswordGenerationPopupView owns itself, and will only be deleted
34 // when Hide() is called.
35 static PasswordGenerationPopupView
* Create(
36 PasswordGenerationPopupController
* controller
);
38 static const SkColor kExplanatoryTextBackgroundColor
;
39 static const SkColor kExplanatoryTextColor
;
40 static const SkColor kDividerColor
;
41 static const SkColor kLinkColor
;
44 } // namespace autofill
46 #endif // CHROME_BROWSER_UI_AUTOFILL_PASSWORD_GENERATION_POPUP_VIEW_H_