Index: ash/wm/shelf_layout_manager.cc |
diff --git a/ash/wm/shelf_layout_manager.cc b/ash/wm/shelf_layout_manager.cc |
index 188449a775e752ae0e01c695189bbf8f2a5b1b16..0d344fee09db2c0a0dd73391898e79add1b0f86c 100644 |
--- a/ash/wm/shelf_layout_manager.cc |
+++ b/ash/wm/shelf_layout_manager.cc |
@@ -14,7 +14,6 @@ |
#include "base/auto_reset.h" |
#include "base/i18n/rtl.h" |
#include "ui/aura/client/activation_client.h" |
-#include "ui/aura/dip_util.h" |
#include "ui/aura/event.h" |
#include "ui/aura/event_filter.h" |
#include "ui/aura/root_window.h" |
@@ -37,11 +36,6 @@ ui::Layer* GetLayer(views::Widget* widget) { |
return widget->GetNativeView()->layer(); |
} |
-void SetLayerBounds(views::Widget* widget, const gfx::Rect& bounds) { |
- aura::Window* window = widget->GetNativeView(); |
- window->layer()->SetBounds(aura::ConvertRectToPixel(window, bounds)); |
-} |
- |
} // namespace |
// static |
@@ -195,6 +189,7 @@ void ShelfLayoutManager::LayoutShelf() { |
CalculateTargetBounds(state_, &target_bounds); |
if (launcher_widget()) { |
GetLayer(launcher_widget())->SetOpacity(target_bounds.opacity); |
+ |
launcher_widget()->SetBounds(target_bounds.launcher_bounds); |
launcher_->SetStatusWidth( |
target_bounds.status_bounds.width()); |
@@ -334,7 +329,7 @@ void ShelfLayoutManager::SetState(VisibilityState visibility_state) { |
launcher_animation_setter.SetTransitionDuration( |
base::TimeDelta::FromMilliseconds(130)); |
launcher_animation_setter.SetTweenType(ui::Tween::EASE_OUT); |
- SetLayerBounds(launcher_widget(), target_bounds.launcher_bounds); |
+ GetLayer(launcher_widget())->SetBounds(target_bounds.launcher_bounds); |
GetLayer(launcher_widget())->SetOpacity(target_bounds.opacity); |
} |
ui::ScopedLayerAnimationSettings status_animation_setter( |
@@ -342,7 +337,7 @@ void ShelfLayoutManager::SetState(VisibilityState visibility_state) { |
status_animation_setter.SetTransitionDuration( |
base::TimeDelta::FromMilliseconds(130)); |
status_animation_setter.SetTweenType(ui::Tween::EASE_OUT); |
- SetLayerBounds(status_, target_bounds.status_bounds); |
+ GetLayer(status_)->SetBounds(target_bounds.status_bounds); |
GetLayer(status_)->SetOpacity(target_bounds.opacity); |
Shell::GetInstance()->SetMonitorWorkAreaInsets( |
Shell::GetRootWindow(), |