| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ash/shelf/shelf_widget.h" | 5 #include "ash/shelf/shelf_widget.h" |
| 6 | 6 |
| 7 #include "ash/ash_switches.h" | 7 #include "ash/ash_switches.h" |
| 8 #include "ash/focus_cycler.h" | 8 #include "ash/focus_cycler.h" |
| 9 #include "ash/root_window_controller.h" | 9 #include "ash/root_window_controller.h" |
| 10 #include "ash/session_state_delegate.h" | 10 #include "ash/session_state_delegate.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 #include "ui/compositor/layer.h" | 30 #include "ui/compositor/layer.h" |
| 31 #include "ui/compositor/scoped_layer_animation_settings.h" | 31 #include "ui/compositor/scoped_layer_animation_settings.h" |
| 32 #include "ui/events/event_constants.h" | 32 #include "ui/events/event_constants.h" |
| 33 #include "ui/gfx/canvas.h" | 33 #include "ui/gfx/canvas.h" |
| 34 #include "ui/gfx/image/image.h" | 34 #include "ui/gfx/image/image.h" |
| 35 #include "ui/gfx/image/image_skia_operations.h" | 35 #include "ui/gfx/image/image_skia_operations.h" |
| 36 #include "ui/gfx/skbitmap_operations.h" | 36 #include "ui/gfx/skbitmap_operations.h" |
| 37 #include "ui/views/accessible_pane_view.h" | 37 #include "ui/views/accessible_pane_view.h" |
| 38 #include "ui/views/widget/widget.h" | 38 #include "ui/views/widget/widget.h" |
| 39 #include "ui/views/widget/widget_delegate.h" | 39 #include "ui/views/widget/widget_delegate.h" |
| 40 #include "ui/wm/public/easy_resize_window_targeter.h" | 40 #include "ui/wm/core/easy_resize_window_targeter.h" |
| 41 | 41 |
| 42 namespace { | 42 namespace { |
| 43 // Size of black border at bottom (or side) of shelf. | 43 // Size of black border at bottom (or side) of shelf. |
| 44 const int kNumBlackPixels = 3; | 44 const int kNumBlackPixels = 3; |
| 45 // Alpha to paint dimming image with. | 45 // Alpha to paint dimming image with. |
| 46 const int kDimAlpha = 128; | 46 const int kDimAlpha = 128; |
| 47 | 47 |
| 48 // The time to dim and un-dim. | 48 // The time to dim and un-dim. |
| 49 const int kTimeToDimMs = 3000; // Slow in dimming. | 49 const int kTimeToDimMs = 3000; // Slow in dimming. |
| 50 const int kTimeToUnDimMs = 200; // Fast in activating. | 50 const int kTimeToUnDimMs = 200; // Fast in activating. |
| (...skipping 755 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 806 DCHECK(delegate_view_); | 806 DCHECK(delegate_view_); |
| 807 return delegate_view_->disable_dimming_animations_for_test(); | 807 return delegate_view_->disable_dimming_animations_for_test(); |
| 808 } | 808 } |
| 809 | 809 |
| 810 void ShelfWidget::WillDeleteShelf() { | 810 void ShelfWidget::WillDeleteShelf() { |
| 811 shelf_layout_manager_->RemoveObserver(this); | 811 shelf_layout_manager_->RemoveObserver(this); |
| 812 shelf_layout_manager_ = NULL; | 812 shelf_layout_manager_ = NULL; |
| 813 } | 813 } |
| 814 | 814 |
| 815 } // namespace ash | 815 } // namespace ash |
| OLD | NEW |