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

Unified Diff: ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc

Issue 2524873002: Rename WindowTreeHost G|SetBounds to indicate they are in pixels. (Closed)
Patch Set: rebase Created 4 years, 1 month 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: ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc b/ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
index 024396aac1997f2312b627a8bf60957c355f4f7f..7de68af939c7e1e86ec33ae4f15e5ca1a55145b4 100644
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_x11.cc
@@ -665,7 +665,7 @@ void DesktopWindowTreeHostX11::CenterWindow(const gfx::Size& size) {
// able to close or move it.
window_bounds_in_pixels.AdjustToFit(parent_bounds_in_pixels);
- SetBounds(window_bounds_in_pixels);
+ SetBoundsInPixels(window_bounds_in_pixels);
}
void DesktopWindowTreeHostX11::GetWindowPlacement(
@@ -850,7 +850,7 @@ void DesktopWindowTreeHostX11::Maximize() {
gfx::Rect adjusted_bounds_in_pixels(bounds_in_pixels_.origin(),
AdjustSize(bounds_in_pixels_.size()));
if (adjusted_bounds_in_pixels != bounds_in_pixels_)
- SetBounds(adjusted_bounds_in_pixels);
+ SetBoundsInPixels(adjusted_bounds_in_pixels);
}
// Some WMs do not respect maximization hints on unmapped windows, so we
@@ -1204,11 +1204,11 @@ void DesktopWindowTreeHostX11::HideImpl() {
native_widget_delegate_->OnNativeWidgetVisibilityChanged(false);
}
-gfx::Rect DesktopWindowTreeHostX11::GetBounds() const {
+gfx::Rect DesktopWindowTreeHostX11::GetBoundsInPixels() const {
return bounds_in_pixels_;
}
-void DesktopWindowTreeHostX11::SetBounds(
+void DesktopWindowTreeHostX11::SetBoundsInPixels(
const gfx::Rect& requested_bounds_in_pixel) {
gfx::Rect bounds_in_pixels(requested_bounds_in_pixel.origin(),
AdjustSize(requested_bounds_in_pixel.size()));
@@ -1579,7 +1579,7 @@ void DesktopWindowTreeHostX11::OnWMStateUpdated() {
// calling OnHostResized() with an empty size. In particular,
// HWNDMessageHandler::GetClientAreaBounds() returns an empty size when the
// window is minimized. On Linux, returning empty size in GetBounds() or
- // SetBounds() does not work.
+ // SetBoundsInPixels() does not work.
// We also propagate the minimization to the compositor, to makes sure that we
// don't draw any 'blank' frames that could be noticed in applications such as
// window manager previews, which show content even when a window is

Powered by Google App Engine
This is Rietveld 408576698