| 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 #ifndef ASH_SHELF_SHELF_VIEW_H_ | 5 #ifndef ASH_SHELF_SHELF_VIEW_H_ |
| 6 #define ASH_SHELF_SHELF_VIEW_H_ | 6 #define ASH_SHELF_SHELF_VIEW_H_ |
| 7 | 7 |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 228 // returns bounds from first item to last panel item. | 228 // returns bounds from first item to last panel item. |
| 229 // * In the overflow mode, returns only bubble's bounds. | 229 // * In the overflow mode, returns only bubble's bounds. |
| 230 gfx::Rect GetBoundsForDragInsertInScreen(); | 230 gfx::Rect GetBoundsForDragInsertInScreen(); |
| 231 | 231 |
| 232 // Common setup done for all children. | 232 // Common setup done for all children. |
| 233 void ConfigureChildView(views::View* view); | 233 void ConfigureChildView(views::View* view); |
| 234 | 234 |
| 235 // Toggles the overflow menu. | 235 // Toggles the overflow menu. |
| 236 void ToggleOverflowBubble(); | 236 void ToggleOverflowBubble(); |
| 237 | 237 |
| 238 // Update first launcher button's padding. This method adds padding to the |
| 239 // first button to include the leading inset. It needs to be called once on |
| 240 // button creation and every time when shelf alignment is changed. |
| 241 void UpdateFirstButtonPadding(); |
| 242 |
| 238 // Invoked after the fading out animation for item deletion is ended. | 243 // Invoked after the fading out animation for item deletion is ended. |
| 239 void OnFadeOutAnimationEnded(); | 244 void OnFadeOutAnimationEnded(); |
| 240 | 245 |
| 241 // Fade in last visible item. | 246 // Fade in last visible item. |
| 242 void StartFadeInLastVisibleItem(); | 247 void StartFadeInLastVisibleItem(); |
| 243 | 248 |
| 244 // Updates the visible range of overflow items in |overflow_view|. | 249 // Updates the visible range of overflow items in |overflow_view|. |
| 245 void UpdateOverflowRange(ShelfView* overflow_view); | 250 void UpdateOverflowRange(ShelfView* overflow_view); |
| 246 | 251 |
| 252 // Returns the launcher button size. |
| 253 int GetButtonSize() const; |
| 254 |
| 255 // Returns the button spacing. |
| 256 int GetButtonSpacing() const; |
| 257 |
| 247 // Overridden from views::View: | 258 // Overridden from views::View: |
| 248 virtual gfx::Size GetPreferredSize() OVERRIDE; | 259 virtual gfx::Size GetPreferredSize() OVERRIDE; |
| 249 virtual void OnBoundsChanged(const gfx::Rect& previous_bounds) OVERRIDE; | 260 virtual void OnBoundsChanged(const gfx::Rect& previous_bounds) OVERRIDE; |
| 250 virtual FocusTraversable* GetPaneFocusTraversable() OVERRIDE; | 261 virtual FocusTraversable* GetPaneFocusTraversable() OVERRIDE; |
| 251 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE; | 262 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE; |
| 252 | 263 |
| 253 // Overridden from ui::EventHandler: | 264 // Overridden from ui::EventHandler: |
| 254 virtual void OnGestureEvent(ui::GestureEvent* event) OVERRIDE; | 265 virtual void OnGestureEvent(ui::GestureEvent* event) OVERRIDE; |
| 255 | 266 |
| 256 // Overridden from ShelfModelObserver: | 267 // Overridden from ShelfModelObserver: |
| (...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 438 // True when ripped item from overflow bubble is entered into Shelf. | 449 // True when ripped item from overflow bubble is entered into Shelf. |
| 439 bool dragged_off_from_overflow_to_shelf_; | 450 bool dragged_off_from_overflow_to_shelf_; |
| 440 | 451 |
| 441 DISALLOW_COPY_AND_ASSIGN(ShelfView); | 452 DISALLOW_COPY_AND_ASSIGN(ShelfView); |
| 442 }; | 453 }; |
| 443 | 454 |
| 444 } // namespace internal | 455 } // namespace internal |
| 445 } // namespace ash | 456 } // namespace ash |
| 446 | 457 |
| 447 #endif // ASH_SHELF_SHELF_VIEW_H_ | 458 #endif // ASH_SHELF_SHELF_VIEW_H_ |
| OLD | NEW |