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

Side by Side Diff: ash/display/display_controller.h

Issue 10905242: add ash_resources.grd and necessary changes to use images in ash/resources (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: presubmit.py Created 8 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 | Annotate | Revision Log
OLDNEW
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_DISPLAY_DISPLAY_CONTROLLER_H_ 5 #ifndef ASH_DISPLAY_DISPLAY_CONTROLLER_H_
6 #define ASH_DISPLAY_DISPLAY_CONTROLLER_H_ 6 #define ASH_DISPLAY_DISPLAY_CONTROLLER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 return default_display_layout_; 107 return default_display_layout_;
108 } 108 }
109 void SetDefaultDisplayLayout(const DisplayLayout& layout); 109 void SetDefaultDisplayLayout(const DisplayLayout& layout);
110 110
111 // Sets/gets the display layout for the specified display name. Getter 111 // Sets/gets the display layout for the specified display name. Getter
112 // returns the default value in case it doesn't have its own layout yet. 112 // returns the default value in case it doesn't have its own layout yet.
113 void SetLayoutForDisplayName(const std::string& name, 113 void SetLayoutForDisplayName(const std::string& name,
114 const DisplayLayout& layout); 114 const DisplayLayout& layout);
115 const DisplayLayout& GetLayoutForDisplayName(const std::string& name); 115 const DisplayLayout& GetLayoutForDisplayName(const std::string& name);
116 116
117 // Swaps primary and secondary display. This also updated DisplayLayout so tha t
118 // the phisical display layout does not change.
119 void SwapPrimaryAndSecondary();
120
117 // aura::DisplayObserver overrides: 121 // aura::DisplayObserver overrides:
118 virtual void OnDisplayBoundsChanged( 122 virtual void OnDisplayBoundsChanged(
119 const gfx::Display& display) OVERRIDE; 123 const gfx::Display& display) OVERRIDE;
120 virtual void OnDisplayAdded(const gfx::Display& display) OVERRIDE; 124 virtual void OnDisplayAdded(const gfx::Display& display) OVERRIDE;
121 virtual void OnDisplayRemoved(const gfx::Display& display) OVERRIDE; 125 virtual void OnDisplayRemoved(const gfx::Display& display) OVERRIDE;
122 126
123 private: 127 private:
124 // Creates a root window for |display| and stores it in the |root_windows_| 128 // Creates a root window for |display| and stores it in the |root_windows_|
125 // map. 129 // map.
126 aura::RootWindow* AddRootWindowForDisplay(const gfx::Display& display); 130 aura::RootWindow* AddRootWindowForDisplay(const gfx::Display& display);
(...skipping 12 matching lines...) Expand all
139 std::map<std::string, DisplayLayout> secondary_layouts_; 143 std::map<std::string, DisplayLayout> secondary_layouts_;
140 144
141 ObserverList<Observer> observers_; 145 ObserverList<Observer> observers_;
142 146
143 DISALLOW_COPY_AND_ASSIGN(DisplayController); 147 DISALLOW_COPY_AND_ASSIGN(DisplayController);
144 }; 148 };
145 149
146 } // namespace ash 150 } // namespace ash
147 151
148 #endif // ASH_DISPLAY_DISPLAY_CONTROLLER_H_ 152 #endif // ASH_DISPLAY_DISPLAY_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698