OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/external_tab_container_win.h" | 5 #include "chrome/browser/external_tab_container_win.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 GURL(chrome::kPageInfoHelpCenterURL)); | 114 GURL(chrome::kPageInfoHelpCenterURL)); |
115 container_->OpenURLFromTab(container_->tab_contents(), url, GURL(), | 115 container_->OpenURLFromTab(container_->tab_contents(), url, GURL(), |
116 NEW_FOREGROUND_TAB, | 116 NEW_FOREGROUND_TAB, |
117 content::PAGE_TRANSITION_LINK); | 117 content::PAGE_TRANSITION_LINK); |
118 } | 118 } |
119 private: | 119 private: |
120 scoped_refptr<ExternalTabContainer> container_; | 120 scoped_refptr<ExternalTabContainer> container_; |
121 }; | 121 }; |
122 | 122 |
123 base::LazyInstance<ExternalTabContainer::PendingTabs> | 123 base::LazyInstance<ExternalTabContainer::PendingTabs> |
124 ExternalTabContainer::pending_tabs_(base::LINKER_INITIALIZED); | 124 ExternalTabContainer::pending_tabs_ = LAZY_INSTANCE_INITIALIZER; |
125 | 125 |
126 ExternalTabContainer::ExternalTabContainer( | 126 ExternalTabContainer::ExternalTabContainer( |
127 AutomationProvider* automation, AutomationResourceMessageFilter* filter) | 127 AutomationProvider* automation, AutomationResourceMessageFilter* filter) |
128 : views::NativeWidgetWin(new views::Widget), | 128 : views::NativeWidgetWin(new views::Widget), |
129 automation_(automation), | 129 automation_(automation), |
130 tab_contents_container_(NULL), | 130 tab_contents_container_(NULL), |
131 tab_handle_(0), | 131 tab_handle_(0), |
132 ignore_next_load_notification_(false), | 132 ignore_next_load_notification_(false), |
133 automation_resource_message_filter_(filter), | 133 automation_resource_message_filter_(filter), |
134 load_requests_via_automation_(false), | 134 load_requests_via_automation_(false), |
(...skipping 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1226 if (params.disposition == CURRENT_TAB) { | 1226 if (params.disposition == CURRENT_TAB) { |
1227 DCHECK(route_all_top_level_navigations_); | 1227 DCHECK(route_all_top_level_navigations_); |
1228 forward_params.disposition = NEW_FOREGROUND_TAB; | 1228 forward_params.disposition = NEW_FOREGROUND_TAB; |
1229 } | 1229 } |
1230 TabContents* new_contents = | 1230 TabContents* new_contents = |
1231 ExternalTabContainer::OpenURLFromTab(source, forward_params); | 1231 ExternalTabContainer::OpenURLFromTab(source, forward_params); |
1232 // support only one navigation for a dummy tab before it is killed. | 1232 // support only one navigation for a dummy tab before it is killed. |
1233 ::DestroyWindow(GetNativeView()); | 1233 ::DestroyWindow(GetNativeView()); |
1234 return new_contents; | 1234 return new_contents; |
1235 } | 1235 } |
OLD | NEW |