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

Side by Side Diff: athena/wm/overview_toolbar.h

Issue 537073002: athena: Improve the overview mode support for split-view mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | athena/wm/overview_toolbar.cc » ('j') | athena/wm/window_overview_mode.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 ATHENA_WM_OVERVIEW_TOOLBAR_H_ 5 #ifndef ATHENA_WM_OVERVIEW_TOOLBAR_H_
6 #define ATHENA_WM_OVERVIEW_TOOLBAR_H_ 6 #define ATHENA_WM_OVERVIEW_TOOLBAR_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "ui/gfx/geometry/rect.h" 10 #include "ui/gfx/geometry/rect.h"
(...skipping 29 matching lines...) Expand all
40 40
41 ActionType current_action() const { return current_action_; } 41 ActionType current_action() const { return current_action_; }
42 42
43 // Returns the action the gesture-event is targeting. 43 // Returns the action the gesture-event is targeting.
44 ActionType GetHighlightAction(const ui::GestureEvent& event) const; 44 ActionType GetHighlightAction(const ui::GestureEvent& event) const;
45 45
46 void SetHighlightAction(ActionType action); 46 void SetHighlightAction(ActionType action);
47 void ShowActionButtons(); 47 void ShowActionButtons();
48 void HideActionButtons(); 48 void HideActionButtons();
49 49
50 void DisableAction(ActionType action);
51
50 private: 52 private:
51 void ToggleActionButtonsVisibility(); 53 void ToggleActionButtonsVisibility();
54 bool IsActionEnabled(ActionType action) const;
52 bool IsEventOverButton(ActionButton* button, 55 bool IsEventOverButton(ActionButton* button,
53 const ui::GestureEvent& event) const; 56 const ui::GestureEvent& event) const;
54 gfx::Transform ComputeTransformFor(ActionButton* button) const; 57 gfx::Transform ComputeTransformFor(ActionButton* button) const;
55 void TransformButton(ActionButton* button); 58 void TransformButton(ActionButton* button);
56 59
57 bool shown_; 60 bool shown_;
61 uint64_t disabled_action_bitfields_;
58 scoped_ptr<ActionButton> close_; 62 scoped_ptr<ActionButton> close_;
59 scoped_ptr<ActionButton> split_; 63 scoped_ptr<ActionButton> split_;
60 ActionType current_action_; 64 ActionType current_action_;
61 const gfx::Rect container_bounds_; 65 const gfx::Rect container_bounds_;
62 66
63 DISALLOW_COPY_AND_ASSIGN(OverviewToolbar); 67 DISALLOW_COPY_AND_ASSIGN(OverviewToolbar);
64 }; 68 };
65 69
66 } // namespace athena 70 } // namespace athena
67 71
68 #endif // ATHENA_WM_OVERVIEW_TOOLBAR_H_ 72 #endif // ATHENA_WM_OVERVIEW_TOOLBAR_H_
OLDNEW
« no previous file with comments | « no previous file | athena/wm/overview_toolbar.cc » ('j') | athena/wm/window_overview_mode.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698