| Index: chrome/browser/chromeos/login/helper.h
|
| diff --git a/chrome/browser/chromeos/login/helper.h b/chrome/browser/chromeos/login/helper.h
|
| index 0ecfe4f94618dca3df2baf629b3b32a794d9474f..791fbf98ddff61c440524c8100b8b6884906d10f 100644
|
| --- a/chrome/browser/chromeos/login/helper.h
|
| +++ b/chrome/browser/chromeos/login/helper.h
|
| @@ -8,8 +8,9 @@
|
| #define CHROME_BROWSER_CHROMEOS_LOGIN_HELPER_H_
|
| #pragma once
|
|
|
| -#include "views/controls/button/native_button.h"
|
| #include "third_party/skia/include/core/SkColor.h"
|
| +#include "views/controls/button/native_button.h"
|
| +#include "views/widget/widget_gtk.h"
|
|
|
| class GURL;
|
|
|
| @@ -24,10 +25,44 @@ class MenuButton;
|
| class Painter;
|
| class Textfield;
|
| class Throbber;
|
| +class Widget;
|
| } // namespace views
|
|
|
| namespace chromeos {
|
|
|
| +// This class manages showing the throbber in the separate popup widget.
|
| +class ThrobberManager {
|
| + public:
|
| + ThrobberManager();
|
| + virtual ~ThrobberManager();
|
| +
|
| + // Creates throbber above the given host in the right side with the given
|
| + // margin. Also places throbber in the middle of the vertical host size. It
|
| + // takes the ownership of the |throbber|. At most one throbber is shown at
|
| + // each moment, so calling this method will close the previously created
|
| + // throbber.
|
| + void CreateAndStart(views::Widget* host,
|
| + views::Throbber* throbber,
|
| + int right_margin);
|
| +
|
| + // Creates throbber above the given host using the relative bounds given. It
|
| + // takes the ownership of the |throbber|. At most one throbber is shown at
|
| + // each moment, so calling this method will close the previously created
|
| + // throbber.
|
| + void CreateAndStart(views::Widget* host,
|
| + views::Throbber* throbber,
|
| + const gfx::Rect& relative_bounds);
|
| +
|
| + // Stops and closes the throbber (if any).
|
| + void StopAndClose();
|
| +
|
| + private:
|
| + // Holds the widget that shows the throbber.
|
| + views::Widget* throbber_widget_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(ThrobberManager);
|
| +};
|
| +
|
| // Creates default smoothed throbber for time consuming operations on login.
|
| views::Throbber* CreateDefaultSmoothedThrobber();
|
|
|
| @@ -81,6 +116,8 @@ const SkColor kTextColor = SK_ColorWHITE;
|
| // Default link color on login/OOBE controls.
|
| const SkColor kLinkColor = 0xFF0066CC;
|
|
|
| +const int kThrobberRightMargin = 10;
|
| +
|
| // Default size of the OOBE screen. Includes 10px shadow from each side.
|
| // See rounded_rect_painter.cc for border definitions.
|
| const int kWizardScreenWidth = 800;
|
|
|