Index: ui/aura/window_tree_host.h |
diff --git a/ui/aura/window_tree_host.h b/ui/aura/window_tree_host.h |
index fcbcbd82516f3329f3faf4daaff6e320defb0fe0..ba0089a3e3257f2dc0ebf834fb2f73c627c7238d 100644 |
--- a/ui/aura/window_tree_host.h |
+++ b/ui/aura/window_tree_host.h |
@@ -52,7 +52,7 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
~WindowTreeHost() override; |
// Creates a new WindowTreeHost. The caller owns the returned value. |
- static WindowTreeHost* Create(const gfx::Rect& bounds); |
+ static WindowTreeHost* Create(const gfx::Rect& bounds_in_pixels); |
// Returns the WindowTreeHost for the specified accelerated widget, or NULL |
// if there is none associated. |
@@ -85,33 +85,33 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
// Sets padding applied to the output surface. The output surface is sized to |
// to the size of the host plus output surface padding. |window()| is offset |
- // by |padding|, that is, |window|'s origin is set to padding.left(), |
- // padding.top(). |
+ // by |padding_in_pixel|, that is, |window|'s origin is set to |
+ // padding_in_pixel.left(), padding_in_pixel.top(). |
// This does not impact the bounds as returned from GetBounds(), only the |
// output surface size and location of window(). Additionally window() is |
// sized to the size set by bounds (more specifically the size passed to |
- // OnHostResized()), but the location of window() is set to that of |
- // |padding|. |
- void SetOutputSurfacePadding(const gfx::Insets& padding); |
+ // OnHostResizedInPixel()), but the location of window() is set to that of |
+ // |padding_in_pixel|. |
+ void SetOutputSurfacePaddingInPixel(const gfx::Insets& padding_in_pixel); |
- // Updates the root window's size using |host_size|, current |
+ // Updates the root window's size using |host_size_in_pixel|, current |
// transform and outsets. |
- virtual void UpdateRootWindowSize(const gfx::Size& host_size); |
+ virtual void UpdateRootWindowSizeInPixel(const gfx::Size& host_size_in_pixel); |
// Converts |point| from the root window's coordinate system to native |
// screen's. |
- void ConvertPointToNativeScreen(gfx::Point* point) const; |
+ void ConvertPointFromDIPToNativeScreen(gfx::Point* point) const; |
// Converts |point| from native screen coordinate system to the root window's. |
- void ConvertPointFromNativeScreen(gfx::Point* point) const; |
+ void ConvertPointFromNativeScreenToDIP(gfx::Point* point) const; |
// Converts |point| from the root window's coordinate system to the |
// host window's. |
- void ConvertPointToHost(gfx::Point* point) const; |
+ void ConvertPointFromDIPToHost(gfx::Point* point) const; |
// Converts |point| from the host window's coordinate system to the |
// root window's. |
- void ConvertPointFromHost(gfx::Point* point) const; |
+ void ConvertPointFromHostToDIP(gfx::Point* point) const; |
// Cursor. |
// Sets the currently-displayed cursor. If the cursor was previously hidden |
@@ -124,10 +124,11 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
void OnCursorVisibilityChanged(bool visible); |
// Moves the cursor to the specified location relative to the root window. |
- void MoveCursorTo(const gfx::Point& location); |
+ void MoveCursorToLocationInDIP(const gfx::Point& location_in_dip); |
// Moves the cursor to the |host_location| given in host coordinates. |
- void MoveCursorToHostLocation(const gfx::Point& host_location); |
+ void MoveCursorToHostLocationInPixel( |
sky
2016/11/23 23:04:48
You are patch uses Pixels. Please be consistent. P
riajiang
2016/11/23 23:16:44
I was using pixel/pixels based on if the noun is s
|
+ const gfx::Point& host_location_in_pixel); |
gfx::NativeCursor last_cursor() const { return last_cursor_; } |
@@ -195,10 +196,10 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
void OnAcceleratedWidgetAvailable(); |
// Returns the location of the RootWindow on native screen. |
- virtual gfx::Point GetLocationOnNativeScreen() const = 0; |
+ virtual gfx::Point GetLocationOnNativeScreenInPixel() const = 0; |
- void OnHostMoved(const gfx::Point& new_location); |
- void OnHostResized(const gfx::Size& new_size); |
+ void OnHostMovedInPixel(const gfx::Point& new_location_in_pixel); |
+ void OnHostResizedInPixel(const gfx::Size& new_size_in_pixel); |
void OnHostWorkspaceChanged(); |
void OnHostCloseRequested(); |
void OnHostActivated(); |
@@ -208,7 +209,8 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
virtual void SetCursorNative(gfx::NativeCursor cursor) = 0; |
// Moves the cursor to the specified location relative to the root window. |
- virtual void MoveCursorToNative(const gfx::Point& location) = 0; |
+ virtual void MoveCursorToNativeInPixel( |
+ const gfx::Point& location_in_pixel) = 0; |
// kCalled when the cursor visibility has changed. |
virtual void OnCursorVisibilityChangedNative(bool show) = 0; |
@@ -228,7 +230,7 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
friend class test::WindowTreeHostTestApi; |
// Moves the cursor to the specified location. This method is internally used |
- // by MoveCursorTo() and MoveCursorToHostLocation(). |
+ // by MoveCursorToLocationInDIP() and MoveCursorToHostLocationInPixel(). |
void MoveCursorToInternal(const gfx::Point& root_location, |
const gfx::Point& host_location); |
@@ -258,7 +260,7 @@ class AURA_EXPORT WindowTreeHost : public ui::internal::InputMethodDelegate, |
// Whether the InputMethod instance is owned by this WindowTreeHost. |
bool owned_input_method_; |
- gfx::Insets output_surface_padding_; |
+ gfx::Insets output_surface_padding_in_pixel_; |
DISALLOW_COPY_AND_ASSIGN(WindowTreeHost); |
}; |