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

Side by Side Diff: ui/aura_shell/launcher/launcher.h

Issue 8953004: Now that the launcher is sized to the width of the root window we need (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Tweaks Created 9 years 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
« no previous file with comments | « ui/aura_shell/aura_shell.gyp ('k') | ui/aura_shell/launcher/launcher.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_ 5 #ifndef UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_
6 #define UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_ 6 #define UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 10
(...skipping 12 matching lines...) Expand all
23 23
24 namespace aura_shell { 24 namespace aura_shell {
25 25
26 class LauncherModel; 26 class LauncherModel;
27 27
28 class AURA_SHELL_EXPORT Launcher : public aura::WindowObserver { 28 class AURA_SHELL_EXPORT Launcher : public aura::WindowObserver {
29 public: 29 public:
30 explicit Launcher(aura::Window* window_container); 30 explicit Launcher(aura::Window* window_container);
31 ~Launcher(); 31 ~Launcher();
32 32
33 // Sets the width of the status area.
34 void SetStatusWidth(int width);
35 int GetStatusWidth();
36
33 LauncherModel* model() { return model_.get(); } 37 LauncherModel* model() { return model_.get(); }
34 views::Widget* widget() { return widget_; } 38 views::Widget* widget() { return widget_; }
35 39
36 private: 40 private:
41 class DelegateView;
42
37 typedef std::map<aura::Window*, bool> WindowMap; 43 typedef std::map<aura::Window*, bool> WindowMap;
38 44
39 // If necessary asks the delegate if an entry should be created in the 45 // If necessary asks the delegate if an entry should be created in the
40 // launcher for |window|. This only asks the delegate once for a window. 46 // launcher for |window|. This only asks the delegate once for a window.
41 void MaybeAdd(aura::Window* window); 47 void MaybeAdd(aura::Window* window);
42 48
43 // WindowObserver overrides: 49 // WindowObserver overrides:
44 virtual void OnWindowAdded(aura::Window* new_window) OVERRIDE; 50 virtual void OnWindowAdded(aura::Window* new_window) OVERRIDE;
45 virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE; 51 virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE;
46 virtual void OnWindowVisibilityChanged(aura::Window* window, 52 virtual void OnWindowVisibilityChanged(aura::Window* window,
47 bool visibile) OVERRIDE; 53 bool visibile) OVERRIDE;
48 54
49 scoped_ptr<LauncherModel> model_; 55 scoped_ptr<LauncherModel> model_;
50 56
51 // Widget hosting the view. 57 // Widget hosting the view.
52 views::Widget* widget_; 58 views::Widget* widget_;
53 59
54 aura::Window* window_container_; 60 aura::Window* window_container_;
55 61
56 // The set of windows we know about. The boolean indicates whether we've asked 62 // The set of windows we know about. The boolean indicates whether we've asked
57 // the delegate if the window should added to the launcher. 63 // the delegate if the window should added to the launcher.
58 WindowMap known_windows_; 64 WindowMap known_windows_;
59 65
66 // Contents view of the widget. Houses the LauncherView.
67 DelegateView* delegate_view_;
68
60 DISALLOW_COPY_AND_ASSIGN(Launcher); 69 DISALLOW_COPY_AND_ASSIGN(Launcher);
61 }; 70 };
62 71
63 } // namespace aura_shell 72 } // namespace aura_shell
64 73
65 #endif // UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_ 74 #endif // UI_AURA_SHELL_LAUNCHER_LAUNCHER_H_
OLDNEW
« no previous file with comments | « ui/aura_shell/aura_shell.gyp ('k') | ui/aura_shell/launcher/launcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698