Index: chrome/browser/automation/automation_provider_observers.cc |
diff --git a/chrome/browser/automation/automation_provider_observers.cc b/chrome/browser/automation/automation_provider_observers.cc |
index bff1f5c4def082bca8ada65456dda009c01fcefe..fd78085cf89f2e29753487cb35836bff3cdd802e 100644 |
--- a/chrome/browser/automation/automation_provider_observers.cc |
+++ b/chrome/browser/automation/automation_provider_observers.cc |
@@ -396,19 +396,22 @@ void TabStripNotificationObserver::Observe( |
} |
TabAppendedNotificationObserver::TabAppendedNotificationObserver( |
- Browser* parent, AutomationProvider* automation, |
- IPC::Message* reply_message) |
+ Browser* parent, |
+ AutomationProvider* automation, |
+ IPC::Message* reply_message, |
+ bool use_json_interface) |
: TabStripNotificationObserver(chrome::NOTIFICATION_TAB_PARENTED, |
automation), |
parent_(parent), |
- reply_message_(reply_message) { |
+ reply_message_(reply_message), |
+ use_json_interface_(use_json_interface) { |
} |
TabAppendedNotificationObserver::~TabAppendedNotificationObserver() {} |
void TabAppendedNotificationObserver::ObserveTab( |
NavigationController* controller) { |
- if (!automation_) |
+ if (!automation_ || !reply_message_.get()) |
return; |
if (automation_->GetIndexForNavigationController(controller, parent_) == |
@@ -419,7 +422,11 @@ void TabAppendedNotificationObserver::ObserveTab( |
new NavigationNotificationObserver(controller, automation_, |
reply_message_.release(), |
- 1, false, false); |
+ 1, false, use_json_interface_); |
+} |
+ |
+IPC::Message* TabAppendedNotificationObserver::ReleaseReply() { |
+ return reply_message_.release(); |
} |
TabClosedNotificationObserver::TabClosedNotificationObserver( |
@@ -3099,4 +3106,3 @@ void BrowserOpenedWithExistingProfileNotificationObserver::Observe( |
NOTREACHED(); |
} |
} |
- |