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

Unified Diff: ash/shelf/shelf_layout_manager.h

Issue 14477010: Partial fix for keyboard occlusion. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: ash/shelf/shelf_layout_manager.h
diff --git a/ash/shelf/shelf_layout_manager.h b/ash/shelf/shelf_layout_manager.h
index fa16158d70052dd584779ec4b1dde0a7ec086758..99aefeb369e55f44fd8eaa5051ed84cb3f9962c5 100644
--- a/ash/shelf/shelf_layout_manager.h
+++ b/ash/shelf/shelf_layout_manager.h
@@ -20,6 +20,7 @@
#include "ui/aura/layout_manager.h"
#include "ui/gfx/insets.h"
#include "ui/gfx/rect.h"
+#include "ui/keyboard/keyboard_controller.h"
namespace aura {
class RootWindow;
@@ -47,7 +48,8 @@ class WorkspaceController;
class ASH_EXPORT ShelfLayoutManager :
public aura::LayoutManager,
public ash::ShellObserver,
- public aura::client::ActivationChangeObserver {
+ public aura::client::ActivationChangeObserver,
+ public keyboard::KeyboardController::Observer {
public:
// TODO(rharrison): Move this observer out of ash::internal::
@@ -277,6 +279,12 @@ class ASH_EXPORT ShelfLayoutManager :
int GetWorkAreaSize(const State& state, int size) const;
+ gfx::Rect GetAvailableBounds() const;
+
+ // Overridden from keyboard::KeyboardController::Observer:
+ virtual void OnKeyboardBoundsChanged(
+ const gfx::Rect& keyboard_bounds) OVERRIDE;
+
// The RootWindow is cached so that we don't invoke Shell::GetInstance() from
// our destructor. We avoid that as at the time we're deleted Shell is being
// deleted too.
@@ -330,6 +338,9 @@ class ASH_EXPORT ShelfLayoutManager :
// Used to delay updating shelf background.
UpdateShelfObserver* update_shelf_observer_;
+ // The bounds of the keyboard.
+ gfx::Rect keyboard_bounds_;
+
DISALLOW_COPY_AND_ASSIGN(ShelfLayoutManager);
};

Powered by Google App Engine
This is Rietveld 408576698