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

Side by Side Diff: chrome/browser/ui/ash/launcher/launcher_item_controller.h

Issue 107163005: [ash] Add TYPE_DIALOG and its item's LauncherContextMenu (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 6 years, 11 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 CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_
7 7
8 #include "ash/launcher/launcher_types.h" 8 #include "ash/launcher/launcher_types.h"
9 #include "ash/shelf/shelf_item_delegate.h" 9 #include "ash/shelf/shelf_item_delegate.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 virtual bool IsVisible() const = 0; 71 virtual bool IsVisible() const = 0;
72 72
73 // Launches a new instance of the app associated with this item. 73 // Launches a new instance of the app associated with this item.
74 virtual void Launch(ash::LaunchSource source, int event_flags) = 0; 74 virtual void Launch(ash::LaunchSource source, int event_flags) = 0;
75 75
76 // Shows and activates the most-recently-active window associated with the 76 // Shows and activates the most-recently-active window associated with the
77 // item, or launches the item if it is not currently open. 77 // item, or launches the item if it is not currently open.
78 // Returns true when a new item got created. 78 // Returns true when a new item got created.
79 virtual bool Activate(ash::LaunchSource source) = 0; 79 virtual bool Activate(ash::LaunchSource source) = 0;
80 80
81 // Closes all windows associated with this item.
82 virtual void Close() = 0;
83
84 // Called to retrieve the list of running applications. 81 // Called to retrieve the list of running applications.
85 virtual ChromeLauncherAppMenuItems GetApplicationList(int event_flags) = 0; 82 virtual ChromeLauncherAppMenuItems GetApplicationList(int event_flags) = 0;
86 83
87 // Helper function to get the ash::LauncherItemType for the item type. 84 // Helper function to get the ash::LauncherItemType for the item type.
88 ash::LauncherItemType GetLauncherItemType() const; 85 ash::LauncherItemType GetLauncherItemType() const;
89 86
90 protected: 87 protected:
91 // Helper function to return the title associated with |app_id_|. 88 // Helper function to return the title associated with |app_id_|.
92 // Returns an empty title if no matching extension can be found. 89 // Returns an empty title if no matching extension can be found.
93 base::string16 GetAppTitle() const; 90 base::string16 GetAppTitle() const;
(...skipping 10 matching lines...) Expand all
104 // applications. 101 // applications.
105 int locked_; 102 int locked_;
106 103
107 // Set to true if the launcher item image has been set by the controller. 104 // Set to true if the launcher item image has been set by the controller.
108 bool image_set_by_controller_; 105 bool image_set_by_controller_;
109 106
110 DISALLOW_COPY_AND_ASSIGN(LauncherItemController); 107 DISALLOW_COPY_AND_ASSIGN(LauncherItemController);
111 }; 108 };
112 109
113 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_ 110 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_ITEM_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698