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

Unified Diff: ash/wm/panels/panel_layout_manager.cc

Issue 138003007: [Cleanup] Screen cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: make sure screen_for_shutdown is reset everytime Created 6 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
« no previous file with comments | « ash/wm/overview/window_selector_unittest.cc ('k') | ash/wm/panels/panel_layout_manager_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/panels/panel_layout_manager.cc
diff --git a/ash/wm/panels/panel_layout_manager.cc b/ash/wm/panels/panel_layout_manager.cc
index 1338133245c6dced207bfa3351611676e6f68f5d..7bfe4ad5e207ef5213c6da373248b400e52127e3 100644
--- a/ash/wm/panels/panel_layout_manager.cc
+++ b/ash/wm/panels/panel_layout_manager.cc
@@ -7,7 +7,7 @@
#include <algorithm>
#include <map>
-#include "ash/screen_ash.h"
+#include "ash/screen_util.h"
#include "ash/shelf/shelf.h"
#include "ash/shelf/shelf_layout_manager.h"
#include "ash/shelf/shelf_types.h"
@@ -232,7 +232,7 @@ class PanelCalloutWidget : public views::Widget {
params.keep_on_top = true;
params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET;
params.parent = parent;
- params.bounds = ScreenAsh::ConvertRectToScreen(parent, gfx::Rect());
+ params.bounds = ScreenUtil::ConvertRectToScreen(parent, gfx::Rect());
params.bounds.set_width(kArrowWidth);
params.bounds.set_height(kArrowHeight);
// Why do we need this and can_activate = false?
@@ -586,7 +586,7 @@ void PanelLayoutManager::Relayout() {
ShelfAlignment alignment = shelf_->shelf_widget()->GetAlignment();
bool horizontal = alignment == SHELF_ALIGNMENT_TOP ||
alignment == SHELF_ALIGNMENT_BOTTOM;
- gfx::Rect shelf_bounds = ash::ScreenAsh::ConvertRectFromScreen(
+ gfx::Rect shelf_bounds = ash::ScreenUtil::ConvertRectFromScreen(
panel_container_, shelf_->shelf_widget()->GetWindowBoundsInScreen());
int panel_start_bounds = kPanelIdealSpacing;
int panel_end_bounds = horizontal ?
@@ -630,8 +630,8 @@ void PanelLayoutManager::Relayout() {
DCHECK(!active_panel);
active_panel = panel;
}
- icon_bounds = ScreenAsh::ConvertRectFromScreen(panel_container_,
- icon_bounds);
+ icon_bounds = ScreenUtil::ConvertRectFromScreen(panel_container_,
+ icon_bounds);
gfx::Point icon_origin = icon_bounds.origin();
VisiblePanelPositionInfo position_info;
int icon_start = horizontal ? icon_origin.x() : icon_origin.y();
@@ -796,8 +796,9 @@ void PanelLayoutManager::UpdateCallouts() {
views::Widget* callout_widget = iter->callout_widget;
gfx::Rect current_bounds = panel->GetBoundsInScreen();
- gfx::Rect bounds = ScreenAsh::ConvertRectToScreen(panel->parent(),
- panel->GetTargetBounds());
+ gfx::Rect bounds = ScreenUtil::ConvertRectToScreen(
+ panel->parent(),
+ panel->GetTargetBounds());
gfx::Rect icon_bounds = shelf_->GetScreenBoundsOfItemIconForWindow(panel);
if (icon_bounds.IsEmpty() || !panel->layer()->GetTargetVisibility() ||
panel == dragged_panel_) {
@@ -838,7 +839,7 @@ void PanelLayoutManager::UpdateCallouts() {
callout_bounds.set_y(bounds.y() - callout_bounds.height());
break;
}
- callout_bounds = ScreenAsh::ConvertRectFromScreen(
+ callout_bounds = ScreenUtil::ConvertRectFromScreen(
callout_widget->GetNativeWindow()->parent(),
callout_bounds);
« no previous file with comments | « ash/wm/overview/window_selector_unittest.cc ('k') | ash/wm/panels/panel_layout_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698