summaryrefslogtreecommitdiffstats
path: root/chrome/browser/ui
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/ui')
-rw-r--r--chrome/browser/ui/auto_login_prompter.cc2
-rw-r--r--chrome/browser/ui/blocked_content/blocked_content_tab_helper.cc2
-rw-r--r--chrome/browser/ui/bookmarks/bookmark_tab_helper.cc2
-rw-r--r--chrome/browser/ui/browser.cc4
-rw-r--r--chrome/browser/ui/find_bar/find_backend_unittest.cc2
-rw-r--r--chrome/browser/ui/find_bar/find_tab_helper.cc4
-rw-r--r--chrome/browser/ui/gtk/infobars/infobar_gtk.cc2
-rw-r--r--chrome/browser/ui/gtk/tabs/dragged_view_gtk.cc2
-rw-r--r--chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc2
-rw-r--r--chrome/browser/ui/search_engines/search_engine_tab_helper.cc4
-rw-r--r--chrome/browser/ui/tab_contents/tab_contents_wrapper.cc2
-rw-r--r--chrome/browser/ui/toolbar/back_forward_menu_model.cc2
-rw-r--r--chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc2
-rw-r--r--chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.cc2
-rw-r--r--chrome/browser/ui/webui/about_ui.cc2
-rw-r--r--chrome/browser/ui/webui/active_downloads_ui.cc2
-rw-r--r--chrome/browser/ui/webui/aura/app_list_ui.cc2
-rw-r--r--chrome/browser/ui/webui/bookmarks_ui.cc2
-rw-r--r--chrome/browser/ui/webui/bug_report_ui.cc6
-rw-r--r--chrome/browser/ui/webui/certificate_viewer_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chrome_web_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chrome_web_ui_factory.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc5
-rw-r--r--chrome/browser/ui/webui/chromeos/imageburner/imageburner_utils.cc4
-rw-r--r--chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_screen_handler.cc6
-rw-r--r--chrome/browser/ui/webui/chromeos/login/oobe_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/register_page_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc2
-rw-r--r--chrome/browser/ui/webui/chromeos/system_info_ui.cc2
-rw-r--r--chrome/browser/ui/webui/conflicts_ui.cc2
-rw-r--r--chrome/browser/ui/webui/crashes_ui.cc2
-rw-r--r--chrome/browser/ui/webui/devtools_ui.cc2
-rw-r--r--chrome/browser/ui/webui/downloads_ui.cc2
-rw-r--r--chrome/browser/ui/webui/edit_search_engine_dialog_ui_webui.cc2
-rw-r--r--chrome/browser/ui/webui/extensions/extensions_ui.cc2
-rw-r--r--chrome/browser/ui/webui/flags_ui.cc2
-rw-r--r--chrome/browser/ui/webui/flash_ui.cc2
-rw-r--r--chrome/browser/ui/webui/gpu_internals_ui.cc2
-rw-r--r--chrome/browser/ui/webui/history_ui.cc2
-rw-r--r--chrome/browser/ui/webui/hung_renderer_dialog_ui.cc2
-rw-r--r--chrome/browser/ui/webui/input_window_dialog_ui.cc2
-rw-r--r--chrome/browser/ui/webui/keyboard_ui.cc2
-rw-r--r--chrome/browser/ui/webui/media/media_internals_ui.cc2
-rw-r--r--chrome/browser/ui/webui/ntp/new_tab_ui.cc2
-rw-r--r--chrome/browser/ui/webui/options/advanced_options_handler.cc4
-rw-r--r--chrome/browser/ui/webui/options/options_ui.cc2
-rw-r--r--chrome/browser/ui/webui/options/personal_options_handler.cc2
-rw-r--r--chrome/browser/ui/webui/options2/advanced_options_handler2.cc4
-rw-r--r--chrome/browser/ui/webui/options2/options_ui2.cc2
-rw-r--r--chrome/browser/ui/webui/options2/personal_options_handler2.cc2
-rw-r--r--chrome/browser/ui/webui/plugins_ui.cc2
-rw-r--r--chrome/browser/ui/webui/policy_ui.cc2
-rw-r--r--chrome/browser/ui/webui/print_preview_ui.cc2
-rw-r--r--chrome/browser/ui/webui/profiler_ui.cc2
-rw-r--r--chrome/browser/ui/webui/quota_internals_ui.cc2
-rw-r--r--chrome/browser/ui/webui/sessions_ui.cc2
-rw-r--r--chrome/browser/ui/webui/sync_internals_ui.cc2
-rw-r--r--chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc2
-rw-r--r--chrome/browser/ui/webui/task_manager_ui.cc2
-rw-r--r--chrome/browser/ui/webui/test_chrome_web_ui_factory.cc2
-rw-r--r--chrome/browser/ui/webui/tracing_ui.cc2
-rw-r--r--chrome/browser/ui/webui/uber/uber_ui.cc2
-rw-r--r--chrome/browser/ui/webui/web_ui_unittest.cc4
-rw-r--r--chrome/browser/ui/webui/workers_ui.cc2
69 files changed, 82 insertions, 81 deletions
diff --git a/chrome/browser/ui/auto_login_prompter.cc b/chrome/browser/ui/auto_login_prompter.cc
index ae47d63..3aba710 100644
--- a/chrome/browser/ui/auto_login_prompter.cc
+++ b/chrome/browser/ui/auto_login_prompter.cc
@@ -292,7 +292,7 @@ void AutoLoginPrompter::ShowInfoBarUIThread(const std::string& account,
// If auto-login is turned off, then simply return.
Profile* profile =
- Profile::FromBrowserContext(tab_contents->browser_context());
+ Profile::FromBrowserContext(tab_contents->GetBrowserContext());
if (!profile->GetPrefs()->GetBoolean(prefs::kAutologinEnabled))
return;
diff --git a/chrome/browser/ui/blocked_content/blocked_content_tab_helper.cc b/chrome/browser/ui/blocked_content/blocked_content_tab_helper.cc
index ac3b8d6..bf91a8c 100644
--- a/chrome/browser/ui/blocked_content/blocked_content_tab_helper.cc
+++ b/chrome/browser/ui/blocked_content/blocked_content_tab_helper.cc
@@ -84,7 +84,7 @@ void BlockedContentTabHelper::AddPopup(TabContentsWrapper* new_contents,
tab_contents()->GetController().GetLastCommittedEntry();
GURL creator = entry ? entry->virtual_url() : GURL::EmptyGURL();
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
if (creator.is_valid() &&
profile->GetHostContentSettingsMap()->GetContentSetting(
diff --git a/chrome/browser/ui/bookmarks/bookmark_tab_helper.cc b/chrome/browser/ui/bookmarks/bookmark_tab_helper.cc
index b4aa381..84fdc4c 100644
--- a/chrome/browser/ui/bookmarks/bookmark_tab_helper.cc
+++ b/chrome/browser/ui/bookmarks/bookmark_tab_helper.cc
@@ -101,7 +101,7 @@ BookmarkTabHelper::BookmarkDrag*
void BookmarkTabHelper::UpdateStarredStateForCurrentURL() {
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
BookmarkModel* model = profile->GetBookmarkModel();
const bool old_state = is_starred_;
is_starred_ = (model && model->IsBookmarked(tab_contents()->GetURL()));
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index d9ffe73..95bbefc 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -2530,7 +2530,7 @@ Browser* Browser::GetBrowserForController(
void Browser::RunFileChooserHelper(
TabContents* tab, const content::FileChooserParams& params) {
Profile* profile =
- Profile::FromBrowserContext(tab->browser_context());
+ Profile::FromBrowserContext(tab->GetBrowserContext());
// FileSelectHelper adds a reference to itself and only releases it after
// sending the result message. It won't be destroyed when this reference
// goes out of scope.
@@ -2548,7 +2548,7 @@ void Browser::EnumerateDirectoryHelper(TabContents* tab, int request_id,
return;
Profile* profile =
- Profile::FromBrowserContext(tab->browser_context());
+ Profile::FromBrowserContext(tab->GetBrowserContext());
// FileSelectHelper adds a reference to itself and only releases it after
// sending the result message. It won't be destroyed when this reference
// goes out of scope.
diff --git a/chrome/browser/ui/find_bar/find_backend_unittest.cc b/chrome/browser/ui/find_bar/find_backend_unittest.cc
index c1f4ceb..f151b6d 100644
--- a/chrome/browser/ui/find_bar/find_backend_unittest.cc
+++ b/chrome/browser/ui/find_bar/find_backend_unittest.cc
@@ -29,7 +29,7 @@ class FindBackendTest : public TabContentsWrapperTestHarness {
namespace {
string16 FindPrepopulateText(TabContents* contents) {
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
return FindBarState::GetLastPrepopulateText(profile);
}
diff --git a/chrome/browser/ui/find_bar/find_tab_helper.cc b/chrome/browser/ui/find_bar/find_tab_helper.cc
index 974db90..a401f3f 100644
--- a/chrome/browser/ui/find_bar/find_tab_helper.cc
+++ b/chrome/browser/ui/find_bar/find_tab_helper.cc
@@ -39,7 +39,7 @@ void FindTabHelper::StartFinding(string16 search_string,
// shortcut so unless we have something to search for we return early.
if (search_string.empty() && find_text_.empty()) {
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
string16 last_search_prepopulate_text =
FindBarState::GetLastPrepopulateText(profile);
@@ -76,7 +76,7 @@ void FindTabHelper::StartFinding(string16 search_string,
// Keep track of what the last search was across the tabs.
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
FindBarState* find_bar_state = profile->GetFindBarState();
find_bar_state->set_last_prepopulate_text(find_text_);
diff --git a/chrome/browser/ui/gtk/infobars/infobar_gtk.cc b/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
index fe15111..1e82093 100644
--- a/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
+++ b/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
@@ -53,7 +53,7 @@ const int InfoBarGtk::kEndOfLabelSpacing = 6;
InfoBarGtk::InfoBarGtk(InfoBarTabHelper* owner, InfoBarDelegate* delegate)
: InfoBar(owner, delegate),
theme_service_(GtkThemeService::GetFrom(Profile::FromBrowserContext(
- owner->tab_contents()->browser_context()))),
+ owner->tab_contents()->GetBrowserContext()))),
signals_(new ui::GtkSignalRegistrar) {
DCHECK(delegate);
// Create |hbox_| and pad the sides.
diff --git a/chrome/browser/ui/gtk/tabs/dragged_view_gtk.cc b/chrome/browser/ui/gtk/tabs/dragged_view_gtk.cc
index 7afd2148..86ed7c8 100644
--- a/chrome/browser/ui/gtk/tabs/dragged_view_gtk.cc
+++ b/chrome/browser/ui/gtk/tabs/dragged_view_gtk.cc
@@ -66,7 +66,7 @@ DraggedViewGtk::DraggedViewGtk(DragData* drag_data,
std::vector<TabContents*> data_sources(drag_data_->GetDraggedTabsContents());
for (size_t i = 0; i < data_sources.size(); i++) {
renderers_.push_back(new TabRendererGtk(GtkThemeService::GetFrom(
- Profile::FromBrowserContext(data_sources[i]->browser_context()))));
+ Profile::FromBrowserContext(data_sources[i]->GetBrowserContext()))));
}
for (size_t i = 0; i < drag_data_->size(); i++) {
diff --git a/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc b/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc
index 497bed2..cee692e 100644
--- a/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc
+++ b/chrome/browser/ui/gtk/tabs/tab_renderer_gtk.cc
@@ -331,7 +331,7 @@ void TabRendererGtk::UpdateData(TabContents* contents,
if (!loading_only) {
data_.title = contents->GetTitle();
- data_.incognito = contents->browser_context()->IsOffTheRecord();
+ data_.incognito = contents->GetBrowserContext()->IsOffTheRecord();
data_.crashed = contents->is_crashed();
SkBitmap* app_icon =
diff --git a/chrome/browser/ui/search_engines/search_engine_tab_helper.cc b/chrome/browser/ui/search_engines/search_engine_tab_helper.cc
index 5ba0c11..07e61e9 100644
--- a/chrome/browser/ui/search_engines/search_engine_tab_helper.cc
+++ b/chrome/browser/ui/search_engines/search_engine_tab_helper.cc
@@ -59,7 +59,7 @@ void SearchEngineTabHelper::OnPageHasOSDD(
// Make sure page_id is the current page and other basic checks.
DCHECK(doc_url.is_valid());
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
if (!tab_contents()->IsActiveEntry(page_id))
return;
if (!profile->GetTemplateURLFetcher())
@@ -132,7 +132,7 @@ void SearchEngineTabHelper::GenerateKeywordIfNecessary(
return;
Profile* profile =
- Profile::FromBrowserContext(tab_contents()->browser_context());
+ Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
if (profile->IsOffTheRecord())
return;
diff --git a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
index 00dd82e..7705c3f 100644
--- a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
+++ b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
@@ -172,7 +172,7 @@ const TabContentsWrapper* TabContentsWrapper::GetCurrentWrapperForContents(
}
Profile* TabContentsWrapper::profile() const {
- return Profile::FromBrowserContext(tab_contents()->browser_context());
+ return Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
}
////////////////////////////////////////////////////////////////////////////////
diff --git a/chrome/browser/ui/toolbar/back_forward_menu_model.cc b/chrome/browser/ui/toolbar/back_forward_menu_model.cc
index fbea791..c3b30d2 100644
--- a/chrome/browser/ui/toolbar/back_forward_menu_model.cc
+++ b/chrome/browser/ui/toolbar/back_forward_menu_model.cc
@@ -91,7 +91,7 @@ string16 BackForwardMenuModel::GetLabelAt(int index) const {
// super long.
NavigationEntry* entry = GetNavigationEntry(index);
Profile* profile =
- Profile::FromBrowserContext(GetTabContents()->browser_context());
+ Profile::FromBrowserContext(GetTabContents()->GetBrowserContext());
string16 menu_text(entry->GetTitleForDisplay(
profile->GetPrefs()->GetString(prefs::kAcceptLanguages)));
menu_text =
diff --git a/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc b/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
index 92e3b9a..5758df3 100644
--- a/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
+++ b/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
@@ -438,7 +438,7 @@ void BrowserTabStripController::SetTabRendererDataFromModel(
data->url = contents->GetURL();
data->loading = contents->IsLoading();
data->crashed_status = contents->crashed_status();
- data->incognito = contents->browser_context()->IsOffTheRecord();
+ data->incognito = contents->GetBrowserContext()->IsOffTheRecord();
data->show_icon = wrapper->favicon_tab_helper()->ShouldDisplayFavicon();
data->mini = model_->IsMiniTab(model_index);
data->blocked = model_->IsTabBlocked(model_index);
diff --git a/chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.cc b/chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.cc
index b346cd8..6da4b32 100644
--- a/chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.cc
+++ b/chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.cc
@@ -404,7 +404,7 @@ void KeyboardWidget::TextInputTypeChanged(ui::TextInputType type,
Profile* profile =
Profile::FromBrowserContext(
- dom_view_->dom_contents()->tab_contents()->browser_context());
+ dom_view_->dom_contents()->tab_contents()->GetBrowserContext());
profile->GetExtensionEventRouter()->DispatchEventToRenderers(
kOnTextInputTypeChanged, json_args, NULL, GURL());
diff --git a/chrome/browser/ui/webui/about_ui.cc b/chrome/browser/ui/webui/about_ui.cc
index fdd8beb..c07f19d 100644
--- a/chrome/browser/ui/webui/about_ui.cc
+++ b/chrome/browser/ui/webui/about_ui.cc
@@ -1379,7 +1379,7 @@ std::string AboutUIHTMLSource::GetMimeType(const std::string& path) const {
AboutUI::AboutUI(TabContents* contents, const std::string& name)
: ChromeWebUI(contents) {
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
ChromeURLDataManager::DataSource* source =
new AboutUIHTMLSource(name, profile);
if (source)
diff --git a/chrome/browser/ui/webui/active_downloads_ui.cc b/chrome/browser/ui/webui/active_downloads_ui.cc
index f59af2a..460c093 100644
--- a/chrome/browser/ui/webui/active_downloads_ui.cc
+++ b/chrome/browser/ui/webui/active_downloads_ui.cc
@@ -369,7 +369,7 @@ ActiveDownloadsUI::ActiveDownloadsUI(TabContents* contents)
handler_->Init();
// Set up the chrome://active-downloads/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateActiveDownloadsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/aura/app_list_ui.cc b/chrome/browser/ui/webui/aura/app_list_ui.cc
index d63d784..e876431 100644
--- a/chrome/browser/ui/webui/aura/app_list_ui.cc
+++ b/chrome/browser/ui/webui/aura/app_list_ui.cc
@@ -125,7 +125,7 @@ AppListUI::AppListUI(TabContents* contents)
AddMessageHandler((new AppLauncherHandler(service))->Attach(this));
// Set up the source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
PrefService* prefs = profile->GetPrefs();
profile->GetChromeURLDataManager()->AddDataSource(
CreateAppListUIHTMLSource(prefs));
diff --git a/chrome/browser/ui/webui/bookmarks_ui.cc b/chrome/browser/ui/webui/bookmarks_ui.cc
index 7673997..c4363ae 100644
--- a/chrome/browser/ui/webui/bookmarks_ui.cc
+++ b/chrome/browser/ui/webui/bookmarks_ui.cc
@@ -59,7 +59,7 @@ BookmarksUI::BookmarksUI(TabContents* contents) : ChromeWebUI(contents) {
BookmarksUIHTMLSource* html_source = new BookmarksUIHTMLSource();
// Set up the chrome://bookmarks/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/bug_report_ui.cc b/chrome/browser/ui/webui/bug_report_ui.cc
index ca36cca..bbb603a 100644
--- a/chrome/browser/ui/webui/bug_report_ui.cc
+++ b/chrome/browser/ui/webui/bug_report_ui.cc
@@ -332,7 +332,7 @@ void BugReportHandler::ClobberScreenshotsSource() {
// Re-create our screenshots data source (this clobbers the last source)
// setting the screenshot to NULL, effectively disabling the source
// TODO(rkc): Once there is a method to 'remove' a source, change this code
- Profile* profile = Profile::FromBrowserContext(tab_->browser_context());
+ Profile* profile = Profile::FromBrowserContext(tab_->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(new ScreenshotSource(NULL));
BugReportUtil::ClearScreenshotPng();
@@ -345,7 +345,7 @@ void BugReportHandler::SetupScreenshotsSource() {
new ScreenshotSource(BugReportUtil::GetScreenshotPng());
}
// Add the source to the data manager.
- Profile* profile = Profile::FromBrowserContext(tab_->browser_context());
+ Profile* profile = Profile::FromBrowserContext(tab_->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(screenshot_source_);
}
@@ -624,6 +624,6 @@ BugReportUI::BugReportUI(TabContents* tab) : HtmlDialogUI(tab) {
CreateBugReportUIHTMLSource(handler->Init());
// Set up the chrome://bugreport/ source.
- Profile* profile = Profile::FromBrowserContext(tab->browser_context());
+ Profile* profile = Profile::FromBrowserContext(tab->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/certificate_viewer_ui.cc b/chrome/browser/ui/webui/certificate_viewer_ui.cc
index e366afe..1c41b09 100644
--- a/chrome/browser/ui/webui/certificate_viewer_ui.cc
+++ b/chrome/browser/ui/webui/certificate_viewer_ui.cc
@@ -61,7 +61,7 @@ CertificateViewerUI::CertificateViewerUI(TabContents* contents)
IDR_CERTIFICATE_VIEWER_CSS);
html_source->set_default_resource(IDR_CERTIFICATE_VIEWER_HTML);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/chrome_web_ui.cc b/chrome/browser/ui/webui/chrome_web_ui.cc
index 4663098..91294e5 100644
--- a/chrome/browser/ui/webui/chrome_web_ui.cc
+++ b/chrome/browser/ui/webui/chrome_web_ui.cc
@@ -29,7 +29,7 @@ ChromeWebUI::~ChromeWebUI() {
}
Profile* ChromeWebUI::GetProfile() const {
- return Profile::FromBrowserContext(tab_contents()->browser_context());
+ return Profile::FromBrowserContext(tab_contents()->GetBrowserContext());
}
bool ChromeWebUI::CanShowBookmarkBar() const {
diff --git a/chrome/browser/ui/webui/chrome_web_ui_factory.cc b/chrome/browser/ui/webui/chrome_web_ui_factory.cc
index fe3c031..ad737b6 100644
--- a/chrome/browser/ui/webui/chrome_web_ui_factory.cc
+++ b/chrome/browser/ui/webui/chrome_web_ui_factory.cc
@@ -387,7 +387,7 @@ WebUI* ChromeWebUIFactory::CreateWebUIForURL(
TabContents* tab_contents,
const GURL& url) const {
Profile* profile =
- Profile::FromBrowserContext(tab_contents->browser_context());
+ Profile::FromBrowserContext(tab_contents->GetBrowserContext());
WebUIFactoryFunction function = GetWebUIFactoryFunction(tab_contents,
profile, url);
if (!function)
diff --git a/chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc b/chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc
index 7294f2c..7ff1fb5 100644
--- a/chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc
@@ -211,7 +211,7 @@ ChooseMobileNetworkUI::ChooseMobileNetworkUI(TabContents* contents)
ChooseMobileNetworkHandler* handler = new ChooseMobileNetworkHandler();
AddMessageHandler((handler)->Attach(this));
// Set up the "chrome://choose-mobile-network" source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateChooseMobileNetworkUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc b/chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc
index 9c64749..f746ecf 100644
--- a/chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc
@@ -414,7 +414,8 @@ void WebUIHandler::OnConfigFileFetched(const ConfigFile&
}
if (!download_manager_) {
- download_manager_ = tab_contents_->browser_context()->GetDownloadManager();
+ download_manager_ =
+ tab_contents_->GetBrowserContext()->GetDownloadManager();
download_manager_->AddObserver(this);
}
if (!state_machine_->download_started()) {
@@ -650,7 +651,7 @@ ImageBurnUI::ImageBurnUI(TabContents* contents) : ChromeWebUI(contents) {
imageburner::WebUIHandler* handler = new imageburner::WebUIHandler(contents);
AddMessageHandler((handler)->Attach(this));
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateImageburnerUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/chromeos/imageburner/imageburner_utils.cc b/chrome/browser/ui/webui/chromeos/imageburner/imageburner_utils.cc
index 3f7276a..15ce2bb 100644
--- a/chrome/browser/ui/webui/chromeos/imageburner/imageburner_utils.cc
+++ b/chrome/browser/ui/webui/chromeos/imageburner/imageburner_utils.cc
@@ -314,7 +314,7 @@ void BurnManager::FetchConfigFile(TabContents* tab_contents,
config_file_requested_ = true;
config_file_path_ = GetImageDir().Append(kConfigFileName);
- download_manager_ = tab_contents->browser_context()->GetDownloadManager();
+ download_manager_ = tab_contents->GetBrowserContext()->GetDownloadManager();
download_manager_->AddObserver(this);
downloader()->AddListener(this, config_file_url_);
downloader()->DownloadFile(config_file_url_, config_file_path_, tab_contents);
@@ -438,7 +438,7 @@ void Downloader::OnFileStreamCreatedOnUIThread(const GURL& url,
if (created_file_stream) {
DownloadManager* download_manager =
- tab_contents->browser_context()->GetDownloadManager();
+ tab_contents->GetBrowserContext()->GetDownloadManager();
DownloadSaveInfo save_info;
save_info.file_path = file_path;
save_info.file_stream = linked_ptr<net::FileStream>(created_file_stream);
diff --git a/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc b/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc
index 512a1d9..29c9022 100644
--- a/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc
@@ -287,7 +287,7 @@ void KeyboardOverlayHandler::GetLabelMap(const ListValue* args) {
KeyboardOverlayUI::KeyboardOverlayUI(TabContents* contents)
: HtmlDialogUI(contents) {
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
KeyboardOverlayHandler* handler = new KeyboardOverlayHandler(profile);
AddMessageHandler((handler)->Attach(this));
diff --git a/chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_screen_handler.cc b/chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_screen_handler.cc
index e98bedc..7dd3e1f 100644
--- a/chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_screen_handler.cc
+++ b/chrome/browser/ui/webui/chromeos/login/enterprise_oauth_enrollment_screen_handler.cc
@@ -308,7 +308,7 @@ void EnterpriseOAuthEnrollmentScreenHandler::HandleCompleteLogin(
}
Profile* profile =
- Profile::FromBrowserContext(web_ui_->tab_contents()->browser_context());
+ Profile::FromBrowserContext(web_ui_->tab_contents()->GetBrowserContext());
oauth_fetcher_.reset(
new GaiaOAuthFetcher(this,
profile->GetRequestContext(),
@@ -353,7 +353,7 @@ void EnterpriseOAuthEnrollmentScreenHandler::ResetAuth() {
return;
Profile* profile =
- Profile::FromBrowserContext(web_ui_->tab_contents()->browser_context());
+ Profile::FromBrowserContext(web_ui_->tab_contents()->GetBrowserContext());
browsing_data_remover_ =
new BrowsingDataRemover(profile,
BrowsingDataRemover::EVERYTHING,
@@ -364,7 +364,7 @@ void EnterpriseOAuthEnrollmentScreenHandler::ResetAuth() {
void EnterpriseOAuthEnrollmentScreenHandler::RevokeTokens() {
Profile* profile =
- Profile::FromBrowserContext(web_ui_->tab_contents()->browser_context());
+ Profile::FromBrowserContext(web_ui_->tab_contents()->GetBrowserContext());
if (!access_token_.empty()) {
new TokenRevoker(access_token_, access_token_secret_, profile);
diff --git a/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc b/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc
index f3360c3..160fb42 100644
--- a/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/login/oobe_ui.cc
@@ -148,7 +148,7 @@ OobeUI::OobeUI(TabContents* contents)
DictionaryValue* localized_strings = new DictionaryValue();
GetLocalizedStrings(localized_strings);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
// Set up the chrome://theme/ source, for Chrome logo.
ThemeSource* theme = new ThemeSource(profile);
profile->GetChromeURLDataManager()->AddDataSource(theme);
diff --git a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc
index 1554d3a..472d7c5 100644
--- a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc
+++ b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc
@@ -770,7 +770,7 @@ void SigninScreenHandler::StartClearingCookies() {
cookie_remover_->RemoveObserver(this);
cookie_remover_ = new BrowsingDataRemover(
- Profile::FromBrowserContext(web_ui_->tab_contents()->browser_context()),
+ Profile::FromBrowserContext(web_ui_->tab_contents()->GetBrowserContext()),
BrowsingDataRemover::EVERYTHING,
base::Time());
cookie_remover_->AddObserver(this);
diff --git a/chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc b/chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc
index 578a66c..c6963bc 100644
--- a/chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc
@@ -1371,7 +1371,7 @@ MobileSetupUI::MobileSetupUI(TabContents* contents) : ChromeWebUI(contents) {
new MobileSetupUIHTMLSource(service_path);
// Set up the chrome://mobilesetup/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc b/chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc
index dc78e10..bbb063e 100644
--- a/chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc
@@ -80,7 +80,7 @@ ProxySettingsUI::ProxySettingsUI(TabContents* contents)
ProxySettingsHTMLSource* source =
new ProxySettingsHTMLSource(localized_strings);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(source);
}
diff --git a/chrome/browser/ui/webui/chromeos/register_page_ui.cc b/chrome/browser/ui/webui/chromeos/register_page_ui.cc
index 8bee89e..e1e582f 100644
--- a/chrome/browser/ui/webui/chromeos/register_page_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/register_page_ui.cc
@@ -308,6 +308,6 @@ RegisterPageUI::RegisterPageUI(TabContents* contents) : ChromeWebUI(contents) {
RegisterPageUIHTMLSource* html_source = new RegisterPageUIHTMLSource();
// Set up the chrome://register/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc b/chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc
index e08e9ed..36ef28e 100644
--- a/chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc
@@ -681,7 +681,7 @@ SimUnlockUI::SimUnlockUI(TabContents* contents) : ChromeWebUI(contents) {
SimUnlockUIHTMLSource* html_source = new SimUnlockUIHTMLSource();
// Set up the chrome://sim-unlock/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/chromeos/system_info_ui.cc b/chrome/browser/ui/webui/chromeos/system_info_ui.cc
index 86273ab..edaf793 100644
--- a/chrome/browser/ui/webui/chromeos/system_info_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/system_info_ui.cc
@@ -180,6 +180,6 @@ SystemInfoUI::SystemInfoUI(TabContents* contents) : ChromeWebUI(contents) {
SystemInfoUIHTMLSource* html_source = new SystemInfoUIHTMLSource();
// Set up the chrome://system/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/conflicts_ui.cc b/chrome/browser/ui/webui/conflicts_ui.cc
index 142bbcf..d410bc5 100644
--- a/chrome/browser/ui/webui/conflicts_ui.cc
+++ b/chrome/browser/ui/webui/conflicts_ui.cc
@@ -161,7 +161,7 @@ ConflictsUI::ConflictsUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new ConflictsDOMHandler())->Attach(this));
// Set up the about:conflicts source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateConflictsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/crashes_ui.cc b/chrome/browser/ui/webui/crashes_ui.cc
index ddc01ab..d0cf130 100644
--- a/chrome/browser/ui/webui/crashes_ui.cc
+++ b/chrome/browser/ui/webui/crashes_ui.cc
@@ -163,7 +163,7 @@ CrashesUI::CrashesUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new CrashesDOMHandler())->Attach(this));
// Set up the chrome://crashes/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateCrashesUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/devtools_ui.cc b/chrome/browser/ui/webui/devtools_ui.cc
index 0d1ae7f..21da8e9 100644
--- a/chrome/browser/ui/webui/devtools_ui.cc
+++ b/chrome/browser/ui/webui/devtools_ui.cc
@@ -101,7 +101,7 @@ void DevToolsUI::RegisterDevToolsDataSource(Profile* profile) {
DevToolsUI::DevToolsUI(TabContents* contents) : ChromeWebUI(contents) {
DevToolsDataSource* data_source = new DevToolsDataSource();
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(data_source);
}
diff --git a/chrome/browser/ui/webui/downloads_ui.cc b/chrome/browser/ui/webui/downloads_ui.cc
index 60722e2..9c2edbe 100644
--- a/chrome/browser/ui/webui/downloads_ui.cc
+++ b/chrome/browser/ui/webui/downloads_ui.cc
@@ -93,7 +93,7 @@ DownloadsUI::DownloadsUI(TabContents* contents) : ChromeWebUI(contents) {
handler->Init();
// Set up the chrome://downloads/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateDownloadsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/edit_search_engine_dialog_ui_webui.cc b/chrome/browser/ui/webui/edit_search_engine_dialog_ui_webui.cc
index f69b65f..8ead4b7 100644
--- a/chrome/browser/ui/webui/edit_search_engine_dialog_ui_webui.cc
+++ b/chrome/browser/ui/webui/edit_search_engine_dialog_ui_webui.cc
@@ -47,7 +47,7 @@ EditSearchEngineDialogUI::EditSearchEngineDialogUI(TabContents* contents)
// Set default resource.
source->set_default_resource(IDR_EDIT_SEARCH_ENGINE_DIALOG_HTML);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(source);
}
diff --git a/chrome/browser/ui/webui/extensions/extensions_ui.cc b/chrome/browser/ui/webui/extensions/extensions_ui.cc
index 3be781f..1340c3e 100644
--- a/chrome/browser/ui/webui/extensions/extensions_ui.cc
+++ b/chrome/browser/ui/webui/extensions/extensions_ui.cc
@@ -29,7 +29,7 @@ ChromeWebUIDataSource* CreateExtensionsHTMLSource() {
} // namespace
ExtensionsUI::ExtensionsUI(TabContents* contents) : ChromeWebUI(contents) {
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
ChromeWebUIDataSource* source = CreateExtensionsHTMLSource();
profile->GetChromeURLDataManager()->AddDataSource(source);
profile->GetChromeURLDataManager()->AddDataSource(
diff --git a/chrome/browser/ui/webui/flags_ui.cc b/chrome/browser/ui/webui/flags_ui.cc
index feeab52..c952feb 100644
--- a/chrome/browser/ui/webui/flags_ui.cc
+++ b/chrome/browser/ui/webui/flags_ui.cc
@@ -159,7 +159,7 @@ FlagsUI::FlagsUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new FlagsDOMHandler())->Attach(this));
// Set up the about:flags source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(CreateFlagsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/flash_ui.cc b/chrome/browser/ui/webui/flash_ui.cc
index 3924527..d836b90 100644
--- a/chrome/browser/ui/webui/flash_ui.cc
+++ b/chrome/browser/ui/webui/flash_ui.cc
@@ -371,7 +371,7 @@ FlashUI::FlashUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new FlashDOMHandler())->Attach(this));
// Set up the about:flash source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(CreateFlashUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/gpu_internals_ui.cc b/chrome/browser/ui/webui/gpu_internals_ui.cc
index cb9087b..4aed34117 100644
--- a/chrome/browser/ui/webui/gpu_internals_ui.cc
+++ b/chrome/browser/ui/webui/gpu_internals_ui.cc
@@ -247,6 +247,6 @@ GpuInternalsUI::GpuInternalsUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new GpuMessageHandler())->Attach(this));
// Set up the chrome://gpu-internals/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(CreateGpuHTMLSource());
}
diff --git a/chrome/browser/ui/webui/history_ui.cc b/chrome/browser/ui/webui/history_ui.cc
index 9e6209c..b6f0b10 100644
--- a/chrome/browser/ui/webui/history_ui.cc
+++ b/chrome/browser/ui/webui/history_ui.cc
@@ -428,7 +428,7 @@ HistoryUI::HistoryUI(TabContents* contents) : ChromeWebUI(contents) {
HistoryUIHTMLSource* html_source = new HistoryUIHTMLSource();
// Set up the chrome://history/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/hung_renderer_dialog_ui.cc b/chrome/browser/ui/webui/hung_renderer_dialog_ui.cc
index 3f896cd..0b3f7e9 100644
--- a/chrome/browser/ui/webui/hung_renderer_dialog_ui.cc
+++ b/chrome/browser/ui/webui/hung_renderer_dialog_ui.cc
@@ -34,7 +34,7 @@ HungRendererDialogUI::HungRendererDialogUI(TabContents* contents)
// Set default resource.
source->set_default_resource(IDR_HUNG_RENDERER_DIALOG_HTML);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(source);
// Set up the chrome://theme/ source.
diff --git a/chrome/browser/ui/webui/input_window_dialog_ui.cc b/chrome/browser/ui/webui/input_window_dialog_ui.cc
index 7b14efc..913d765 100644
--- a/chrome/browser/ui/webui/input_window_dialog_ui.cc
+++ b/chrome/browser/ui/webui/input_window_dialog_ui.cc
@@ -25,7 +25,7 @@ InputWindowDialogUI::InputWindowDialogUI(TabContents* contents)
// Set default resource.
source->set_default_resource(IDR_INPUT_WINDOW_DIALOG_HTML);
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(source);
}
diff --git a/chrome/browser/ui/webui/keyboard_ui.cc b/chrome/browser/ui/webui/keyboard_ui.cc
index b18e21c..cae330e0 100644
--- a/chrome/browser/ui/webui/keyboard_ui.cc
+++ b/chrome/browser/ui/webui/keyboard_ui.cc
@@ -19,7 +19,7 @@
KeyboardUI::KeyboardUI(TabContents* contents)
: ChromeWebUI(contents) {
KeyboardHTMLSource* html_source = new KeyboardHTMLSource();
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/media/media_internals_ui.cc b/chrome/browser/ui/webui/media/media_internals_ui.cc
index fded7ac..7ca2848 100644
--- a/chrome/browser/ui/webui/media/media_internals_ui.cc
+++ b/chrome/browser/ui/webui/media/media_internals_ui.cc
@@ -40,7 +40,7 @@ MediaInternalsUI::MediaInternalsUI(TabContents* contents)
: ChromeWebUI(contents) {
AddMessageHandler((new MediaInternalsMessageHandler())->Attach(this));
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateMediaInternalsHTMLSource());
}
diff --git a/chrome/browser/ui/webui/ntp/new_tab_ui.cc b/chrome/browser/ui/webui/ntp/new_tab_ui.cc
index e08d377..a4e6907 100644
--- a/chrome/browser/ui/webui/ntp/new_tab_ui.cc
+++ b/chrome/browser/ui/webui/ntp/new_tab_ui.cc
@@ -109,7 +109,7 @@ NewTabUI::NewTabUI(TabContents* contents)
InitializeCSSCaches();
NewTabHTMLSource* html_source =
new NewTabHTMLSource(GetProfile()->GetOriginalProfile());
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
// Listen for theme installation.
diff --git a/chrome/browser/ui/webui/options/advanced_options_handler.cc b/chrome/browser/ui/webui/options/advanced_options_handler.cc
index a32f584..329c03b 100644
--- a/chrome/browser/ui/webui/options/advanced_options_handler.cc
+++ b/chrome/browser/ui/webui/options/advanced_options_handler.cc
@@ -389,7 +389,7 @@ void AdvancedOptionsHandler::OnCloudPrintSetupClosed() {
void AdvancedOptionsHandler::HandleAutoOpenButton(const ListValue* args) {
content::RecordAction(UserMetricsAction("Options_ResetAutoOpenFiles"));
DownloadManager* manager =
- web_ui_->tab_contents()->browser_context()->GetDownloadManager();
+ web_ui_->tab_contents()->GetBrowserContext()->GetDownloadManager();
if (manager)
DownloadPrefs::FromDownloadManager(manager)->ResetAutoOpen();
}
@@ -617,7 +617,7 @@ void AdvancedOptionsHandler::SetupAutoOpenFileTypesDisabledAttribute() {
// Set the enabled state for the AutoOpenFileTypesResetToDefault button.
// We enable the button if the user has any auto-open file types registered.
DownloadManager* manager =
- web_ui_->tab_contents()->browser_context()->GetDownloadManager();
+ web_ui_->tab_contents()->GetBrowserContext()->GetDownloadManager();
bool disabled = !(manager &&
DownloadPrefs::FromDownloadManager(manager)->IsAutoOpenUsed());
base::FundamentalValue value(disabled);
diff --git a/chrome/browser/ui/webui/options/options_ui.cc b/chrome/browser/ui/webui/options/options_ui.cc
index 51433e9..cdcdde0 100644
--- a/chrome/browser/ui/webui/options/options_ui.cc
+++ b/chrome/browser/ui/webui/options/options_ui.cc
@@ -272,7 +272,7 @@ OptionsUI::OptionsUI(TabContents* contents)
new OptionsUIHTMLSource(localized_strings);
// Set up the chrome://settings/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
// Set up the chrome://theme/ source.
diff --git a/chrome/browser/ui/webui/options/personal_options_handler.cc b/chrome/browser/ui/webui/options/personal_options_handler.cc
index 5d53dc5..e0aa630 100644
--- a/chrome/browser/ui/webui/options/personal_options_handler.cc
+++ b/chrome/browser/ui/webui/options/personal_options_handler.cc
@@ -410,7 +410,7 @@ void PersonalOptionsHandler::SendProfilesInfo() {
g_browser_process->profile_manager()->GetProfileInfoCache();
ListValue profile_info_list;
FilePath current_profile_path =
- web_ui_->tab_contents()->browser_context()->GetPath();
+ web_ui_->tab_contents()->GetBrowserContext()->GetPath();
for (size_t i = 0, e = cache.GetNumberOfProfiles(); i < e; ++i) {
DictionaryValue* profile_value = new DictionaryValue();
FilePath profile_path = cache.GetPathOfProfileAtIndex(i);
diff --git a/chrome/browser/ui/webui/options2/advanced_options_handler2.cc b/chrome/browser/ui/webui/options2/advanced_options_handler2.cc
index 72e6f4c..02f8e1b 100644
--- a/chrome/browser/ui/webui/options2/advanced_options_handler2.cc
+++ b/chrome/browser/ui/webui/options2/advanced_options_handler2.cc
@@ -391,7 +391,7 @@ void AdvancedOptionsHandler::OnCloudPrintSetupClosed() {
void AdvancedOptionsHandler::HandleAutoOpenButton(const ListValue* args) {
content::RecordAction(UserMetricsAction("Options_ResetAutoOpenFiles"));
DownloadManager* manager =
- web_ui_->tab_contents()->browser_context()->GetDownloadManager();
+ web_ui_->tab_contents()->GetBrowserContext()->GetDownloadManager();
if (manager)
DownloadPrefs::FromDownloadManager(manager)->ResetAutoOpen();
}
@@ -619,7 +619,7 @@ void AdvancedOptionsHandler::SetupAutoOpenFileTypesDisabledAttribute() {
// Set the enabled state for the AutoOpenFileTypesResetToDefault button.
// We enable the button if the user has any auto-open file types registered.
DownloadManager* manager =
- web_ui_->tab_contents()->browser_context()->GetDownloadManager();
+ web_ui_->tab_contents()->GetBrowserContext()->GetDownloadManager();
bool disabled = !(manager &&
DownloadPrefs::FromDownloadManager(manager)->IsAutoOpenUsed());
base::FundamentalValue value(disabled);
diff --git a/chrome/browser/ui/webui/options2/options_ui2.cc b/chrome/browser/ui/webui/options2/options_ui2.cc
index fc5cba8..0439ff8 100644
--- a/chrome/browser/ui/webui/options2/options_ui2.cc
+++ b/chrome/browser/ui/webui/options2/options_ui2.cc
@@ -270,7 +270,7 @@ OptionsUI::OptionsUI(TabContents* contents)
new OptionsUIHTMLSource(localized_strings);
// Set up the chrome://settings-frame/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
// Set up the chrome://theme/ source.
diff --git a/chrome/browser/ui/webui/options2/personal_options_handler2.cc b/chrome/browser/ui/webui/options2/personal_options_handler2.cc
index c756cc7..64d5093 100644
--- a/chrome/browser/ui/webui/options2/personal_options_handler2.cc
+++ b/chrome/browser/ui/webui/options2/personal_options_handler2.cc
@@ -412,7 +412,7 @@ void PersonalOptionsHandler::SendProfilesInfo() {
g_browser_process->profile_manager()->GetProfileInfoCache();
ListValue profile_info_list;
FilePath current_profile_path =
- web_ui_->tab_contents()->browser_context()->GetPath();
+ web_ui_->tab_contents()->GetBrowserContext()->GetPath();
for (size_t i = 0, e = cache.GetNumberOfProfiles(); i < e; ++i) {
DictionaryValue* profile_value = new DictionaryValue();
FilePath profile_path = cache.GetPathOfProfileAtIndex(i);
diff --git a/chrome/browser/ui/webui/plugins_ui.cc b/chrome/browser/ui/webui/plugins_ui.cc
index e4449cb..6f49abd 100644
--- a/chrome/browser/ui/webui/plugins_ui.cc
+++ b/chrome/browser/ui/webui/plugins_ui.cc
@@ -380,7 +380,7 @@ PluginsUI::PluginsUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new PluginsDOMHandler())->Attach(this));
// Set up the chrome://plugins/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreatePluginsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/policy_ui.cc b/chrome/browser/ui/webui/policy_ui.cc
index 3d7106c..4bd7ade 100644
--- a/chrome/browser/ui/webui/policy_ui.cc
+++ b/chrome/browser/ui/webui/policy_ui.cc
@@ -234,7 +234,7 @@ PolicyUI::PolicyUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new PolicyUIHandler)->Attach(this));
// Set up the chrome://policy/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(CreatePolicyUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/print_preview_ui.cc b/chrome/browser/ui/webui/print_preview_ui.cc
index f16a03f..543af45 100644
--- a/chrome/browser/ui/webui/print_preview_ui.cc
+++ b/chrome/browser/ui/webui/print_preview_ui.cc
@@ -82,7 +82,7 @@ PrintPreviewUI::PrintPreviewUI(TabContents* contents)
is_dummy_ = (!controller || !controller->is_creating_print_preview_tab());
// Set up the chrome://print/ data source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
new PrintPreviewDataSource(is_dummy_));
if (is_dummy_)
diff --git a/chrome/browser/ui/webui/profiler_ui.cc b/chrome/browser/ui/webui/profiler_ui.cc
index b57a9ab..594ad5b 100644
--- a/chrome/browser/ui/webui/profiler_ui.cc
+++ b/chrome/browser/ui/webui/profiler_ui.cc
@@ -155,7 +155,7 @@ ProfilerUI::ProfilerUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new ProfilerMessageHandler())->Attach(this));
// Set up the chrome://profiler/ source.
- Profile::FromBrowserContext(contents->browser_context())->
+ Profile::FromBrowserContext(contents->GetBrowserContext())->
GetChromeURLDataManager()->AddDataSource(CreateProfilerHTMLSource());
}
diff --git a/chrome/browser/ui/webui/quota_internals_ui.cc b/chrome/browser/ui/webui/quota_internals_ui.cc
index 793bc42..b91ed18 100644
--- a/chrome/browser/ui/webui/quota_internals_ui.cc
+++ b/chrome/browser/ui/webui/quota_internals_ui.cc
@@ -39,7 +39,7 @@ QuotaInternalsUI::QuotaInternalsUI(TabContents* contents)
: ChromeWebUI(contents) {
WebUIMessageHandler* handler = new quota_internals::QuotaInternalsHandler;
AddMessageHandler(handler->Attach(this));
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateQuotaInternalsHTMLSource());
}
diff --git a/chrome/browser/ui/webui/sessions_ui.cc b/chrome/browser/ui/webui/sessions_ui.cc
index 946fc47f..fcc7709 100644
--- a/chrome/browser/ui/webui/sessions_ui.cc
+++ b/chrome/browser/ui/webui/sessions_ui.cc
@@ -262,7 +262,7 @@ SessionsUI::SessionsUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new SessionsDOMHandler())->Attach(this));
// Set up the chrome://sessions/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateSessionsUIHTMLSource());
}
diff --git a/chrome/browser/ui/webui/sync_internals_ui.cc b/chrome/browser/ui/webui/sync_internals_ui.cc
index ef53b9b..8d054c4 100644
--- a/chrome/browser/ui/webui/sync_internals_ui.cc
+++ b/chrome/browser/ui/webui/sync_internals_ui.cc
@@ -76,7 +76,7 @@ SyncInternalsUI::SyncInternalsUI(TabContents* contents)
: ChromeWebUI(contents),
weak_ptr_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {
// TODO(akalin): Fix.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(
CreateSyncInternalsHTMLSource());
ProfileSyncService* sync_service = GetProfileSyncService(profile);
diff --git a/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc b/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
index 6c809c4..9f92d22 100644
--- a/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
+++ b/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
@@ -112,7 +112,7 @@ SyncPromoUI::SyncPromoUI(TabContents* contents) : ChromeWebUI(contents) {
handler->Attach(this);
// Set up the chrome://theme/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
ThemeSource* theme = new ThemeSource(profile);
profile->GetChromeURLDataManager()->AddDataSource(theme);
diff --git a/chrome/browser/ui/webui/task_manager_ui.cc b/chrome/browser/ui/webui/task_manager_ui.cc
index 0359b69..5252c55 100644
--- a/chrome/browser/ui/webui/task_manager_ui.cc
+++ b/chrome/browser/ui/webui/task_manager_ui.cc
@@ -85,6 +85,6 @@ TaskManagerUI::TaskManagerUI(TabContents* contents) : ChromeWebUI(contents) {
// Set up the chrome://taskmanager/ source.
ChromeWebUIDataSource* html_source = CreateTaskManagerUIHTMLSource();
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}
diff --git a/chrome/browser/ui/webui/test_chrome_web_ui_factory.cc b/chrome/browser/ui/webui/test_chrome_web_ui_factory.cc
index 3176cd1..8231c93 100644
--- a/chrome/browser/ui/webui/test_chrome_web_ui_factory.cc
+++ b/chrome/browser/ui/webui/test_chrome_web_ui_factory.cc
@@ -38,7 +38,7 @@ WebUI::TypeID TestChromeWebUIFactory::GetWebUIType(
WebUI* TestChromeWebUIFactory::CreateWebUIForURL(TabContents* tab_contents,
const GURL& url) const {
Profile* profile =
- Profile::FromBrowserContext(tab_contents->browser_context());
+ Profile::FromBrowserContext(tab_contents->GetBrowserContext());
WebUIProvider* provider = GetWebUIProvider(profile, url);
return provider ? provider->NewWebUI(tab_contents, url) :
ChromeWebUIFactory::CreateWebUIForURL(tab_contents, url);
diff --git a/chrome/browser/ui/webui/tracing_ui.cc b/chrome/browser/ui/webui/tracing_ui.cc
index 5c83c0d..571f9d2 100644
--- a/chrome/browser/ui/webui/tracing_ui.cc
+++ b/chrome/browser/ui/webui/tracing_ui.cc
@@ -419,6 +419,6 @@ TracingUI::TracingUI(TabContents* contents) : ChromeWebUI(contents) {
AddMessageHandler((new TracingMessageHandler())->Attach(this));
// Set up the chrome://tracing/ source.
- Profile::FromBrowserContext(contents->browser_context())->
+ Profile::FromBrowserContext(contents->GetBrowserContext())->
GetChromeURLDataManager()->AddDataSource(CreateTracingHTMLSource());
}
diff --git a/chrome/browser/ui/webui/uber/uber_ui.cc b/chrome/browser/ui/webui/uber/uber_ui.cc
index ded7554..97a4778 100644
--- a/chrome/browser/ui/webui/uber/uber_ui.cc
+++ b/chrome/browser/ui/webui/uber/uber_ui.cc
@@ -30,7 +30,7 @@ ChromeWebUIDataSource* CreateUberHTMLSource() {
} // namespace
UberUI::UberUI(TabContents* contents) : ChromeWebUI(contents) {
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(CreateUberHTMLSource());
RegisterSubpage(chrome::kChromeUISettingsFrameURL);
diff --git a/chrome/browser/ui/webui/web_ui_unittest.cc b/chrome/browser/ui/webui/web_ui_unittest.cc
index 40f0eee..dc78455 100644
--- a/chrome/browser/ui/webui/web_ui_unittest.cc
+++ b/chrome/browser/ui/webui/web_ui_unittest.cc
@@ -167,8 +167,8 @@ class TabContentsForFocusTest : public TestTabContents {
TEST_F(WebUITest, FocusOnNavigate) {
// Setup. |tc| will be used to track when we try to focus the location bar.
TabContentsForFocusTest* tc = new TabContentsForFocusTest(
- contents()->browser_context(),
- SiteInstance::CreateSiteInstance(contents()->browser_context()));
+ contents()->GetBrowserContext(),
+ SiteInstance::CreateSiteInstance(contents()->GetBrowserContext()));
tc->GetController().CopyStateFrom(controller());
SetContents(tc);
int page_id = 200;
diff --git a/chrome/browser/ui/webui/workers_ui.cc b/chrome/browser/ui/webui/workers_ui.cc
index 1dc7e0d..a0b0a3c 100644
--- a/chrome/browser/ui/webui/workers_ui.cc
+++ b/chrome/browser/ui/webui/workers_ui.cc
@@ -257,7 +257,7 @@ WorkersUI::WorkersUI(TabContents* contents)
WorkersUIHTMLSource* html_source = new WorkersUIHTMLSource();
// Set up the chrome://workers/ source.
- Profile* profile = Profile::FromBrowserContext(contents->browser_context());
+ Profile* profile = Profile::FromBrowserContext(contents->GetBrowserContext());
profile->GetChromeURLDataManager()->AddDataSource(html_source);
}