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

Unified Diff: ui/views/mus/desktop_window_tree_host_mus.cc

Issue 2525113002: Rename WindowTreeHost functions to indicate pixels/dips. (Closed)
Patch Set: win 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
« no previous file with comments | « ui/views/mus/desktop_window_tree_host_mus.h ('k') | ui/views/mus/drop_target_mus.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/mus/desktop_window_tree_host_mus.cc
diff --git a/ui/views/mus/desktop_window_tree_host_mus.cc b/ui/views/mus/desktop_window_tree_host_mus.cc
index 2083b000a07a952372dcdcf4dacdf93ff96f16a9..47b5d2b5c9d4e48092b7f87dc5565cee2588f226 100644
--- a/ui/views/mus/desktop_window_tree_host_mus.cc
+++ b/ui/views/mus/desktop_window_tree_host_mus.cc
@@ -171,15 +171,14 @@ float DesktopWindowTreeHostMus::GetScaleFactor() const {
.device_scale_factor();
}
-void DesktopWindowTreeHostMus::SetBoundsInDips(
- const gfx::Rect& bounds_in_dips) {
- SetBoundsInPixels(gfx::ConvertRectToPixel(GetScaleFactor(), bounds_in_dips));
+void DesktopWindowTreeHostMus::SetBoundsInDIP(const gfx::Rect& bounds_in_dip) {
+ SetBoundsInPixels(gfx::ConvertRectToPixel(GetScaleFactor(), bounds_in_dip));
}
void DesktopWindowTreeHostMus::Init(aura::Window* content_window,
const Widget::InitParams& params) {
if (!params.bounds.IsEmpty())
- SetBoundsInDips(params.bounds);
+ SetBoundsInDIP(params.bounds);
}
void DesktopWindowTreeHostMus::OnNativeWidgetCreated(
@@ -283,7 +282,7 @@ void DesktopWindowTreeHostMus::SetSize(const gfx::Size& size) {
gfx::Rect screen_bounds =
gfx::ConvertRectToDIP(GetScaleFactor(), GetBoundsInPixels());
screen_bounds.set_size(size);
- SetBoundsInDips(screen_bounds);
+ SetBoundsInDIP(screen_bounds);
}
void DesktopWindowTreeHostMus::StackAbove(aura::Window* window) {
@@ -312,7 +311,7 @@ void DesktopWindowTreeHostMus::CenterWindow(const gfx::Size& size) {
gfx::Rect resulting_bounds(bounds_to_center_in);
resulting_bounds.ClampToCenteredSize(size);
- SetBoundsInDips(resulting_bounds);
+ SetBoundsInDIP(resulting_bounds);
}
void DesktopWindowTreeHostMus::GetWindowPlacement(
« no previous file with comments | « ui/views/mus/desktop_window_tree_host_mus.h ('k') | ui/views/mus/drop_target_mus.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698