Commit b6723a55 authored by ben@chromium.org's avatar ben@chromium.org

Use browser::ShowWebDialog() directly in MobileSetup rather than using BrowserList.

http://crbug.com/129187
TEST=none
Review URL: https://chromiumcodereview.appspot.com/10409068

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@138355 0039d316-1c4b-4281-b951-d872f2087c98
parent db821e71
......@@ -8,13 +8,14 @@
#include "base/memory/singleton.h"
#include "base/utf_string_conversions.h"
#include "chrome/browser/platform_util.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "chrome/browser/ui/browser_dialogs.h"
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/webui/web_dialog_delegate.h"
#include "chrome/common/url_constants.h"
#include "content/public/browser/browser_thread.h"
#include "grit/generated_resources.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/gfx/size.h"
using content::BrowserThread;
using content::WebContents;
......@@ -72,10 +73,10 @@ MobileSetupDialogDelegate::~MobileSetupDialogDelegate() {
}
void MobileSetupDialogDelegate::ShowDialog() {
Browser* browser = BrowserList::GetLastActive();
if (!browser)
return;
browser->BrowserShowWebDialog(this, NULL);
browser::ShowWebDialog(NULL,
ProfileManager::GetDefaultProfileOrOffTheRecord(),
NULL,
this);
}
ui::ModalType MobileSetupDialogDelegate::GetDialogModalType() const {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment