| Index: chrome/browser/ui/panels/auto_hide_bottom_bar.h
|
| ===================================================================
|
| --- chrome/browser/ui/panels/auto_hide_bottom_bar.h (revision 0)
|
| +++ chrome/browser/ui/panels/auto_hide_bottom_bar.h (revision 0)
|
| @@ -0,0 +1,55 @@
|
| +// Copyright (c) 2011 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CHROME_BROWSER_UI_PANELS_AUTO_HIDE_BOTTOM_BAR_H_
|
| +#define CHROME_BROWSER_UI_PANELS_AUTO_HIDE_BOTTOM_BAR_H_
|
| +#pragma once
|
| +
|
| +#include "base/memory/ref_counted.h"
|
| +
|
| +namespace gfx {
|
| +class Rect;
|
| +}
|
| +
|
| +// Encapsulates the logic to deal with always-on-top system/app bar that is
|
| +// located at the bottom of the screen and set to auto-hide, like Windows
|
| +// taskbar or MacOSX dock.
|
| +class AutoHideBottomBar : public base::RefCountedThreadSafe<AutoHideBottomBar> {
|
| + public:
|
| + enum Visibility {
|
| + VISIBLE,
|
| + ANIMATING,
|
| + HIDDEN
|
| + };
|
| +
|
| + // Observer can listen to various events regarding the bottom bar changes.
|
| + // StartMonitoring should be called first if you want observer to receive
|
| + // the notifications.
|
| + class Observer {
|
| + public:
|
| + virtual void OnAutoHideBottomBarVisibilityChanged(
|
| + Visibility visibility) = 0;
|
| + virtual void OnAutoHideBottomBarHeightChanged(int height) = 0;
|
| + };
|
| +
|
| + static AutoHideBottomBar* Create(Observer* observer);
|
| +
|
| + virtual ~AutoHideBottomBar() { }
|
| +
|
| + // This should be called each time when the work area is changed. We only
|
| + // care about the bottom bar that sits on the screen that hosts the specified
|
| + // work area.
|
| + virtual void UpdateWorkArea(const gfx::Rect& work_area) = 0;
|
| +
|
| + // Returns true if the auto-hide bottom bar exists.
|
| + virtual bool Exists() = 0;
|
| +
|
| + // Returns the fixed height of the bottom bar. Note that the height remains
|
| + // unchanged no matter whether the bottom bar is brought up or down.
|
| + virtual int GetHeight() = 0;
|
| +
|
| + virtual Visibility GetVisibility() = 0;
|
| +};
|
| +
|
| +#endif // CHROME_BROWSER_UI_PANELS_AUTO_HIDE_BOTTOM_BAR_H_
|
|
|
| Property changes on: chrome\browser\ui\panels\auto_hide_bottom_bar.h
|
| ___________________________________________________________________
|
| Added: svn:eol-style
|
| + LF
|
|
|
|
|