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

Unified Diff: chrome/browser/ui/touch/frame/touch_browser_frame_view.h

Issue 6384004: Browser should get notified if a views textfield changes focus. In addition, (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Modified according to comments Created 9 years, 11 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: chrome/browser/ui/touch/frame/touch_browser_frame_view.h
diff --git a/chrome/browser/ui/touch/frame/touch_browser_frame_view.h b/chrome/browser/ui/touch/frame/touch_browser_frame_view.h
index c06600faa6233d630558b303ceae7777ad01a6cd..2e088e03884ce6f45cf72ebf1c2c95ab640c6d62 100644
--- a/chrome/browser/ui/touch/frame/touch_browser_frame_view.h
+++ b/chrome/browser/ui/touch/frame/touch_browser_frame_view.h
@@ -10,6 +10,7 @@
#include "chrome/browser/tabs/tab_strip_model_observer.h"
#include "chrome/common/notification_observer.h"
#include "chrome/common/notification_registrar.h"
+#include "views/focus/focus_manager.h"
class BrowserFrame;
class BrowserView;
@@ -18,6 +19,7 @@ class NotificationDetails;
class NotificationSource;
class TouchBrowserFrameView : public OpaqueBrowserFrameView,
+ public views::FocusChangeListener,
public TabStripModelObserver,
public NotificationObserver {
public:
@@ -28,11 +30,22 @@ class TouchBrowserFrameView : public OpaqueBrowserFrameView,
// Overridden from OpaqueBrowserFrameView
virtual void Layout();
+ // views::FocusChangeListener implementation
+ virtual void FocusWillChange(views::View* focused_before,
+ views::View* focused_now);
+
protected:
// Overridden from OpaqueBrowserFrameView
virtual int GetReservedHeight() const;
+ virtual void ViewHierarchyChanged(bool is_add, View* parent, View* child);
oshima 2011/02/04 10:15:27 any specific reason why they're in protected?
varunjain 2011/02/04 16:38:46 Its listed as protected in views::View
private:
+ enum VirtualKeyboardType {
+ NONE,
+ GENERIC,
+ URL,
+ };
+
virtual void InitVirtualKeyboard();
virtual void UpdateKeyboardAndLayout(bool should_show_keyboard);
@@ -47,9 +60,12 @@ class TouchBrowserFrameView : public OpaqueBrowserFrameView,
const NotificationSource& source,
const NotificationDetails& details);
+ virtual VirtualKeyboardType GetKeyboardType(views::View* view);
oshima 2011/02/04 10:15:27 why virtual? can this be just a static function, p
varunjain 2011/02/04 16:38:46 Done.
+
bool keyboard_showing_;
KeyboardContainerView* keyboard_;
NotificationRegistrar registrar_;
+ bool focus_listener_added_;
rjkroege 2011/02/04 15:18:30 put the bools next to each other so the compiler p
varunjain 2011/02/04 16:38:46 Done.
DISALLOW_COPY_AND_ASSIGN(TouchBrowserFrameView);
};

Powered by Google App Engine
This is Rietveld 408576698