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 "apps/app_load_service.h" | 5 #include "apps/app_load_service.h" |
6 | 6 |
7 #include "apps/app_load_service_factory.h" | 7 #include "apps/app_load_service_factory.h" |
8 #include "apps/launcher.h" | 8 #include "apps/launcher.h" |
9 #include "apps/shell_window_registry.h" | 9 #include "apps/shell_window_registry.h" |
10 #include "chrome/browser/chrome_notification_types.h" | 10 #include "chrome/browser/chrome_notification_types.h" |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 | 92 |
93 switch (it->second.action_type) { | 93 switch (it->second.action_type) { |
94 case LAUNCH: | 94 case LAUNCH: |
95 LaunchPlatformApp(profile_, extension); | 95 LaunchPlatformApp(profile_, extension); |
96 break; | 96 break; |
97 case RESTART: | 97 case RESTART: |
98 RestartPlatformApp(profile_, extension); | 98 RestartPlatformApp(profile_, extension); |
99 break; | 99 break; |
100 case LAUNCH_WITH_COMMAND_LINE: | 100 case LAUNCH_WITH_COMMAND_LINE: |
101 LaunchPlatformAppWithCommandLine( | 101 LaunchPlatformAppWithCommandLine( |
102 profile_, extension, &it->second.command_line, | 102 profile_, extension, it->second.command_line, |
103 it->second.current_dir); | 103 it->second.current_dir); |
104 break; | 104 break; |
105 default: | 105 default: |
106 NOTREACHED(); | 106 NOTREACHED(); |
107 } | 107 } |
108 | 108 |
109 post_reload_actions_.erase(it); | 109 post_reload_actions_.erase(it); |
110 break; | 110 break; |
111 } | 111 } |
112 case chrome::NOTIFICATION_EXTENSION_UNLOADED: { | 112 case chrome::NOTIFICATION_EXTENSION_UNLOADED: { |
(...skipping 27 matching lines...) Expand all Loading... |
140 Extension::DISABLE_RELOAD) != 0; | 140 Extension::DISABLE_RELOAD) != 0; |
141 } | 141 } |
142 return false; | 142 return false; |
143 } | 143 } |
144 | 144 |
145 bool AppLoadService::HasPostReloadAction(const std::string& extension_id) { | 145 bool AppLoadService::HasPostReloadAction(const std::string& extension_id) { |
146 return post_reload_actions_.find(extension_id) != post_reload_actions_.end(); | 146 return post_reload_actions_.find(extension_id) != post_reload_actions_.end(); |
147 } | 147 } |
148 | 148 |
149 } // namespace apps | 149 } // namespace apps |
OLD | NEW |