OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/chromeos/login/signin/merge_session_load_page.h" | 5 #include "chrome/browser/chromeos/login/signin/merge_session_load_page.h" |
6 | 6 |
7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
8 #include "ash/shell_delegate.h" | 8 #include "ash/shell_delegate.h" |
9 #include "ash/system/tray/system_tray_delegate.h" | 9 #include "ash/system/tray/system_tray_delegate.h" |
10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 strings.SetInteger("show_delay_time", kShowDelayTimeMS); | 83 strings.SetInteger("show_delay_time", kShowDelayTimeMS); |
84 strings.SetInteger("total_wait_time", kTotalWaitTimeMS); | 84 strings.SetInteger("total_wait_time", kTotalWaitTimeMS); |
85 // TODO(zelidrag): Flip the message to IDS_MERGE_SESSION_LOAD_HEADLINE | 85 // TODO(zelidrag): Flip the message to IDS_MERGE_SESSION_LOAD_HEADLINE |
86 // after merge. | 86 // after merge. |
87 strings.SetString("heading", | 87 strings.SetString("heading", |
88 l10n_util::GetStringUTF16(IDS_TAB_LOADING_TITLE)); | 88 l10n_util::GetStringUTF16(IDS_TAB_LOADING_TITLE)); |
89 | 89 |
90 bool rtl = base::i18n::IsRTL(); | 90 bool rtl = base::i18n::IsRTL(); |
91 strings.SetString("textdirection", rtl ? "rtl" : "ltr"); | 91 strings.SetString("textdirection", rtl ? "rtl" : "ltr"); |
92 | 92 |
| 93 webui::UseVersion2 version2; |
93 base::StringPiece html( | 94 base::StringPiece html( |
94 ResourceBundle::GetSharedInstance().GetRawDataResource( | 95 ResourceBundle::GetSharedInstance().GetRawDataResource( |
95 IDR_MERGE_SESSION_LOAD_HTML)); | 96 IDR_MERGE_SESSION_LOAD_HTML)); |
96 return webui::GetI18nTemplateHtml(html, &strings); | 97 return webui::GetI18nTemplateHtml(html, &strings); |
97 } | 98 } |
98 | 99 |
99 void MergeSessionLoadPage::OverrideRendererPrefs( | 100 void MergeSessionLoadPage::OverrideRendererPrefs( |
100 content::RendererPreferences* prefs) { | 101 content::RendererPreferences* prefs) { |
101 Profile* profile = Profile::FromBrowserContext( | 102 Profile* profile = Profile::FromBrowserContext( |
102 web_contents_->GetBrowserContext()); | 103 web_contents_->GetBrowserContext()); |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 " NOT " : "") | 164 " NOT " : "") |
164 << " be blocking now, " | 165 << " be blocking now, " |
165 << state; | 166 << state; |
166 if (!manager->ShouldBlockTabLoading()) { | 167 if (!manager->ShouldBlockTabLoading()) { |
167 manager->RemoveObserver(this); | 168 manager->RemoveObserver(this); |
168 interstitial_page_->Proceed(); | 169 interstitial_page_->Proceed(); |
169 } | 170 } |
170 } | 171 } |
171 | 172 |
172 } // namespace chromeos | 173 } // namespace chromeos |
OLD | NEW |