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

Side by Side Diff: ash/launcher/launcher_delegate.h

Issue 9835081: Change the launcher to create new tabs instead of windows when (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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
« no previous file with comments | « no previous file | ash/launcher/launcher_view.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) 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_LAUNCHER_LAUNCHER_DELEGATE_H_ 5 #ifndef ASH_LAUNCHER_LAUNCHER_DELEGATE_H_
6 #define ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ 6 #define ASH_LAUNCHER_LAUNCHER_DELEGATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include "ash/ash_export.h" 9 #include "ash/ash_export.h"
10 #include "ash/launcher/launcher_types.h" 10 #include "ash/launcher/launcher_types.h"
11 #include "base/string16.h" 11 #include "base/string16.h"
12 12
13 namespace ui { 13 namespace ui {
14 class MenuModel; 14 class MenuModel;
15 } 15 }
16 16
17 namespace ash { 17 namespace ash {
18 18
19 // Delegate for the Launcher. 19 // Delegate for the Launcher.
20 class ASH_EXPORT LauncherDelegate { 20 class ASH_EXPORT LauncherDelegate {
21 public: 21 public:
22 virtual ~LauncherDelegate() {} 22 virtual ~LauncherDelegate() {}
23 23
24 // Invoked when the user clicks on button in the launcher to create a new 24 // Invoked when the user clicks on button in the launcher to create a new
25 // window. 25 // tab.
26 virtual void CreateNewWindow() = 0; 26 virtual void CreateNewTab() = 0;
27 27
28 // Invoked when the user clicks on a window entry in the launcher. 28 // Invoked when the user clicks on a window entry in the launcher.
29 virtual void ItemClicked(const LauncherItem& item) = 0; 29 virtual void ItemClicked(const LauncherItem& item) = 0;
30 30
31 // Returns the resource id of the image to show on the browser shortcut 31 // Returns the resource id of the image to show on the browser shortcut
32 // button. 32 // button.
33 virtual int GetBrowserShortcutResourceId() = 0; 33 virtual int GetBrowserShortcutResourceId() = 0;
34 34
35 // Returns the title to display for the specified launcher item. 35 // Returns the title to display for the specified launcher item.
36 virtual string16 GetTitle(const LauncherItem& item) = 0; 36 virtual string16 GetTitle(const LauncherItem& item) = 0;
37 37
38 // Returns the context menumodel for the specified item. Return NULL if there 38 // Returns the context menumodel for the specified item. Return NULL if there
39 // should be no context menu. The caller takes ownership of the returned 39 // should be no context menu. The caller takes ownership of the returned
40 // model. 40 // model.
41 virtual ui::MenuModel* CreateContextMenu(const LauncherItem& item) = 0; 41 virtual ui::MenuModel* CreateContextMenu(const LauncherItem& item) = 0;
42 42
43 // Returns the id of the item associated with the specified window, or 0 if 43 // Returns the id of the item associated with the specified window, or 0 if
44 // there isn't one. 44 // there isn't one.
45 virtual ash::LauncherID GetIDByWindow(aura::Window* window) = 0; 45 virtual ash::LauncherID GetIDByWindow(aura::Window* window) = 0;
46 }; 46 };
47 47
48 } // namespace ash 48 } // namespace ash
49 49
50 #endif // ASH_LAUNCHER_LAUNCHER_DELEGATE_H_ 50 #endif // ASH_LAUNCHER_LAUNCHER_DELEGATE_H_
OLDNEW
« no previous file with comments | « no previous file | ash/launcher/launcher_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698