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

Side by Side Diff: ash/test/test_launcher_delegate.h

Issue 14533006: Drag and drop between app list and launcher - First patch (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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_TEST_TEST_LAUNCHER_DELEGATE_H_ 5 #ifndef ASH_TEST_TEST_LAUNCHER_DELEGATE_H_
6 #define ASH_TEST_TEST_LAUNCHER_DELEGATE_H_ 6 #define ASH_TEST_TEST_LAUNCHER_DELEGATE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 10
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 virtual ui::MenuModel* CreateContextMenu(const LauncherItem& item, 43 virtual ui::MenuModel* CreateContextMenu(const LauncherItem& item,
44 aura::RootWindow* root) OVERRIDE; 44 aura::RootWindow* root) OVERRIDE;
45 virtual ash::LauncherMenuModel* CreateApplicationMenu( 45 virtual ash::LauncherMenuModel* CreateApplicationMenu(
46 const LauncherItem& item, 46 const LauncherItem& item,
47 int event_flags) OVERRIDE; 47 int event_flags) OVERRIDE;
48 virtual ash::LauncherID GetIDByWindow(aura::Window* window) OVERRIDE; 48 virtual ash::LauncherID GetIDByWindow(aura::Window* window) OVERRIDE;
49 virtual bool IsDraggable(const ash::LauncherItem& item) OVERRIDE; 49 virtual bool IsDraggable(const ash::LauncherItem& item) OVERRIDE;
50 virtual bool ShouldShowTooltip(const LauncherItem& item) OVERRIDE; 50 virtual bool ShouldShowTooltip(const LauncherItem& item) OVERRIDE;
51 virtual void OnLauncherCreated(Launcher* launcher) OVERRIDE; 51 virtual void OnLauncherCreated(Launcher* launcher) OVERRIDE;
52 virtual void OnLauncherDestroyed(Launcher* launcher) OVERRIDE; 52 virtual void OnLauncherDestroyed(Launcher* launcher) OVERRIDE;
53 virtual LauncherID GetLauncherIDForAppID(const std::string& app_id) OVERRIDE;
54 virtual void PinAppWithID(const std::string& app_id) OVERRIDE;
55 virtual void UnpinAppsWithID(const std::string& app_id) OVERRIDE;
53 56
54 private: 57 private:
55 typedef std::map<aura::Window*, ash::LauncherID> WindowToID; 58 typedef std::map<aura::Window*, ash::LauncherID> WindowToID;
56 typedef std::set<aura::Window*> ObservedWindows; 59 typedef std::set<aura::Window*> ObservedWindows;
57 60
58 static TestLauncherDelegate* instance_; 61 static TestLauncherDelegate* instance_;
59 62
60 aura::Window* GetWindowByID(ash::LauncherID id); 63 aura::Window* GetWindowByID(ash::LauncherID id);
61 64
62 LauncherModel* model_; 65 LauncherModel* model_;
63 66
64 // Maps from window to the id we gave it. 67 // Maps from window to the id we gave it.
65 WindowToID window_to_id_; 68 WindowToID window_to_id_;
66 69
67 // Parent windows we are watching. 70 // Parent windows we are watching.
68 ObservedWindows observed_windows_; 71 ObservedWindows observed_windows_;
69 72
70 DISALLOW_COPY_AND_ASSIGN(TestLauncherDelegate); 73 DISALLOW_COPY_AND_ASSIGN(TestLauncherDelegate);
71 }; 74 };
72 75
73 } // namespace test 76 } // namespace test
74 } // namespace ash 77 } // namespace ash
75 78
76 #endif // ASH_TEST_TEST_LAUNCHER_DELEGATE_H_ 79 #endif // ASH_TEST_TEST_LAUNCHER_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698