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

Unified Diff: views/widget/widget.h

Issue 6688049: New InputMethod api for Views. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update according to review feedbacks. Created 9 years, 9 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: views/widget/widget.h
diff --git a/views/widget/widget.h b/views/widget/widget.h
index c164c166445badf7a3813951040c5ea882093495..171ebbbab61f7178c0b2ef327f0cc37489ba2669 100644
--- a/views/widget/widget.h
+++ b/views/widget/widget.h
@@ -91,6 +91,14 @@ class Widget : public internal::NativeWidgetDelegate,
// view hierarchies that the locale has changed.
static void NotifyLocaleChanged();
+ // Converts a rectangle from one Widget's coordinate system to another's.
+ // Returns false if the conversion couldn't be made, because either these two
+ // Widgets do not have a common ancestor or they are not on the screen yet.
+ // The value of |*rect| won't be changed when false is returned.
+ static bool ConvertRect(const Widget* from,
Ben Goodger (Google) 2011/03/22 20:45:14 source/target
James Su 2011/03/22 23:08:47 Done.
+ const Widget* to,
+ gfx::Rect* rect);
+
// Unconverted methods -------------------------------------------------------
// TODO(beng):
@@ -260,7 +268,7 @@ class Widget : public internal::NativeWidgetDelegate,
ui::AccessibilityTypes::Event event_type,
bool send_native_event) = 0;
- NativeWidget* native_widget() { return native_widget_; }
+ NativeWidget* native_widget() const { return native_widget_; }
Ben Goodger (Google) 2011/03/22 20:45:14 This method is deliberately non-const. If you nee
James Su 2011/03/22 23:08:47 This change is not necessary anymore.
// Overridden from NativeWidgetDelegate:
virtual void OnNativeFocus(gfx::NativeView focused_view) OVERRIDE;
« views/ime/input_method_gtk.h ('K') | « views/views.gyp ('k') | views/widget/widget_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698