OLD | NEW |
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 #include "ash/test/test_shelf_delegate.h" | 5 #include "ash/test/test_shelf_delegate.h" |
6 | 6 |
7 #include "ash/shelf/shelf_item_delegate_manager.h" | 7 #include "ash/shelf/shelf_item_delegate_manager.h" |
8 #include "ash/shelf/shelf_model.h" | 8 #include "ash/shelf/shelf_model.h" |
9 #include "ash/shelf/shelf_util.h" | 9 #include "ash/shelf/shelf_util.h" |
10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 } | 64 } |
65 | 65 |
66 void TestShelfDelegate::OnWindowDestroying(aura::Window* window) { | 66 void TestShelfDelegate::OnWindowDestroying(aura::Window* window) { |
67 RemoveLauncherItemForWindow(window); | 67 RemoveLauncherItemForWindow(window); |
68 } | 68 } |
69 | 69 |
70 void TestShelfDelegate::OnWindowHierarchyChanging( | 70 void TestShelfDelegate::OnWindowHierarchyChanging( |
71 const HierarchyChangeParams& params) { | 71 const HierarchyChangeParams& params) { |
72 // The window may be legitimately reparented while staying open if it moves | 72 // The window may be legitimately reparented while staying open if it moves |
73 // to another display or container. If the window does not have a new parent | 73 // to another display or container. If the window does not have a new parent |
74 // then remove the launcher item. | 74 // then remove the shelf item. |
75 if (!params.new_parent) | 75 if (!params.new_parent) |
76 RemoveLauncherItemForWindow(params.target); | 76 RemoveLauncherItemForWindow(params.target); |
77 } | 77 } |
78 | 78 |
79 void TestShelfDelegate::OnLauncherCreated(Launcher* launcher) { | 79 void TestShelfDelegate::OnShelfCreated(Shelf* shelf) { |
80 } | 80 } |
81 | 81 |
82 void TestShelfDelegate::OnLauncherDestroyed(Launcher* launcher) { | 82 void TestShelfDelegate::OnShelfDestroyed(Shelf* shelf) { |
83 } | 83 } |
84 | 84 |
85 LauncherID TestShelfDelegate::GetLauncherIDForAppID(const std::string& app_id) { | 85 LauncherID TestShelfDelegate::GetLauncherIDForAppID(const std::string& app_id) { |
86 return 0; | 86 return 0; |
87 } | 87 } |
88 | 88 |
89 const std::string& TestShelfDelegate::GetAppIDForLauncherID(LauncherID id) { | 89 const std::string& TestShelfDelegate::GetAppIDForLauncherID(LauncherID id) { |
90 return base::EmptyString(); | 90 return base::EmptyString(); |
91 } | 91 } |
92 | 92 |
93 void TestShelfDelegate::PinAppWithID(const std::string& app_id) { | 93 void TestShelfDelegate::PinAppWithID(const std::string& app_id) { |
94 } | 94 } |
95 | 95 |
96 bool TestShelfDelegate::CanPin() const { | 96 bool TestShelfDelegate::CanPin() const { |
97 return true; | 97 return true; |
98 } | 98 } |
99 | 99 |
100 bool TestShelfDelegate::IsAppPinned(const std::string& app_id) { | 100 bool TestShelfDelegate::IsAppPinned(const std::string& app_id) { |
101 return false; | 101 return false; |
102 } | 102 } |
103 | 103 |
104 void TestShelfDelegate::UnpinAppWithID(const std::string& app_id) { | 104 void TestShelfDelegate::UnpinAppWithID(const std::string& app_id) { |
105 } | 105 } |
106 | 106 |
107 } // namespace test | 107 } // namespace test |
108 } // namespace ash | 108 } // namespace ash |
OLD | NEW |