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

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

Issue 1851883002: Cleanup shelf initialization and observation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Check for shelf before setting prefs in ChromeLauncherController. Created 4 years, 8 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_SHELF_DELEGATE_H_ 5 #ifndef ASH_TEST_TEST_SHELF_DELEGATE_H_
6 #define ASH_TEST_TEST_SHELF_DELEGATE_H_ 6 #define ASH_TEST_TEST_SHELF_DELEGATE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 46
47 static TestShelfDelegate* instance() { return instance_; } 47 static TestShelfDelegate* instance() { return instance_; }
48 48
49 // WindowObserver implementation 49 // WindowObserver implementation
50 void OnWindowDestroying(aura::Window* window) override; 50 void OnWindowDestroying(aura::Window* window) override;
51 void OnWindowHierarchyChanging(const HierarchyChangeParams& params) override; 51 void OnWindowHierarchyChanging(const HierarchyChangeParams& params) override;
52 52
53 // ShelfDelegate implementation. 53 // ShelfDelegate implementation.
54 void OnShelfCreated(Shelf* shelf) override; 54 void OnShelfCreated(Shelf* shelf) override;
55 void OnShelfDestroyed(Shelf* shelf) override; 55 void OnShelfDestroyed(Shelf* shelf) override;
56 void OnShelfAlignmentChanged(Shelf* shelf) override;
57 void OnShelfAutoHideBehaviorChanged(Shelf* shelf) override;
56 ShelfID GetShelfIDForAppID(const std::string& app_id) override; 58 ShelfID GetShelfIDForAppID(const std::string& app_id) override;
57 bool HasShelfIDToAppIDMapping(ShelfID id) const override; 59 bool HasShelfIDToAppIDMapping(ShelfID id) const override;
58 const std::string& GetAppIDForShelfID(ShelfID id) override; 60 const std::string& GetAppIDForShelfID(ShelfID id) override;
59 void PinAppWithID(const std::string& app_id) override; 61 void PinAppWithID(const std::string& app_id) override;
60 bool IsAppPinned(const std::string& app_id) override; 62 bool IsAppPinned(const std::string& app_id) override;
61 void UnpinAppWithID(const std::string& app_id) override; 63 void UnpinAppWithID(const std::string& app_id) override;
62 64
63 private: 65 private:
64 // Adds a mapping from a ShelfID to an app id. 66 // Adds a mapping from a ShelfID to an app id.
65 void AddShelfIDToAppIDMapping(ShelfID shelf_id, const std::string& app_id); 67 void AddShelfIDToAppIDMapping(ShelfID shelf_id, const std::string& app_id);
(...skipping 10 matching lines...) Expand all
76 // Tracks the ShelfID to app id mappings. 78 // Tracks the ShelfID to app id mappings.
77 std::map<ShelfID, std::string> shelf_id_to_app_id_map_; 79 std::map<ShelfID, std::string> shelf_id_to_app_id_map_;
78 80
79 DISALLOW_COPY_AND_ASSIGN(TestShelfDelegate); 81 DISALLOW_COPY_AND_ASSIGN(TestShelfDelegate);
80 }; 82 };
81 83
82 } // namespace test 84 } // namespace test
83 } // namespace ash 85 } // namespace ash
84 86
85 #endif // ASH_TEST_TEST_SHELF_DELEGATE_H_ 87 #endif // ASH_TEST_TEST_SHELF_DELEGATE_H_
OLDNEW
« ash/shelf/shelf.cc ('K') | « ash/shell_observer.h ('k') | ash/test/test_shelf_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698