OLD | NEW |
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 #include "chrome/browser/automation/automation_provider_observers.h" | 5 #include "chrome/browser/automation/automation_provider_observers.h" |
6 | 6 |
7 #include <deque> | 7 #include <deque> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 870 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
881 content::Details<bool> close_app(details); | 881 content::Details<bool> close_app(details); |
882 | 882 |
883 if (use_json_interface_) { | 883 if (use_json_interface_) { |
884 AutomationJSONReply(automation_, | 884 AutomationJSONReply(automation_, |
885 reply_message_.release()).SendSuccess(NULL); | 885 reply_message_.release()).SendSuccess(NULL); |
886 } else { | 886 } else { |
887 if (for_browser_command_) { | 887 if (for_browser_command_) { |
888 AutomationMsg_WindowExecuteCommand::WriteReplyParams(reply_message_.get(), | 888 AutomationMsg_WindowExecuteCommand::WriteReplyParams(reply_message_.get(), |
889 true); | 889 true); |
890 } else { | 890 } else { |
891 AutomationMsg_CloseBrowser::WriteReplyParams(reply_message_.get(), true); | 891 AutomationMsg_CloseBrowser::WriteReplyParams(reply_message_.get(), true, |
| 892 *(close_app.ptr())); |
892 } | 893 } |
893 automation_->Send(reply_message_.release()); | 894 automation_->Send(reply_message_.release()); |
894 } | 895 } |
895 delete this; | 896 delete this; |
896 } | 897 } |
897 | 898 |
898 void BrowserClosedNotificationObserver::set_for_browser_command( | 899 void BrowserClosedNotificationObserver::set_for_browser_command( |
899 bool for_browser_command) { | 900 bool for_browser_command) { |
900 for_browser_command_ = for_browser_command; | 901 for_browser_command_ = for_browser_command; |
901 } | 902 } |
(...skipping 2249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3151 if (automation_) { | 3152 if (automation_) { |
3152 AutomationJSONReply(automation_, reply_message_.release()) | 3153 AutomationJSONReply(automation_, reply_message_.release()) |
3153 .SendSuccess(NULL); | 3154 .SendSuccess(NULL); |
3154 } | 3155 } |
3155 delete this; | 3156 delete this; |
3156 } | 3157 } |
3157 } else { | 3158 } else { |
3158 NOTREACHED(); | 3159 NOTREACHED(); |
3159 } | 3160 } |
3160 } | 3161 } |
OLD | NEW |