Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(377)

Side by Side Diff: chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc

Issue 11434074: browser: Move FindBrowserWithWebContents() into chrome namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ui/webui/options/chromeos/internet_options_handler.h" 5 #include "chrome/browser/ui/webui/options/chromeos/internet_options_handler.h"
6 6
7 #include <ctype.h> 7 #include <ctype.h>
8 8
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 1491 matching lines...) Expand 10 before | Expand all | Expand 10 after
1502 // chrome://mobilesetup/ will open carrier specific portal. 1502 // chrome://mobilesetup/ will open carrier specific portal.
1503 dictionary->SetBoolean(kTagShowViewAccountButton, true); 1503 dictionary->SetBoolean(kTagShowViewAccountButton, true);
1504 } 1504 }
1505 } 1505 }
1506 } 1506 }
1507 1507
1508 gfx::NativeWindow InternetOptionsHandler::GetNativeWindow() const { 1508 gfx::NativeWindow InternetOptionsHandler::GetNativeWindow() const {
1509 // TODO(beng): This is an improper direct dependency on Browser. Route this 1509 // TODO(beng): This is an improper direct dependency on Browser. Route this
1510 // through some sort of delegate. 1510 // through some sort of delegate.
1511 Browser* browser = 1511 Browser* browser =
1512 browser::FindBrowserWithWebContents(web_ui()->GetWebContents()); 1512 chrome::FindBrowserWithWebContents(web_ui()->GetWebContents());
1513 return browser->window()->GetNativeWindow(); 1513 return browser->window()->GetNativeWindow();
1514 } 1514 }
1515 1515
1516 Browser* InternetOptionsHandler::GetAppropriateBrowser() { 1516 Browser* InternetOptionsHandler::GetAppropriateBrowser() {
1517 return browser::FindOrCreateTabbedBrowser( 1517 return browser::FindOrCreateTabbedBrowser(
1518 ProfileManager::GetDefaultProfileOrOffTheRecord(), 1518 ProfileManager::GetDefaultProfileOrOffTheRecord(),
1519 chrome::HOST_DESKTOP_TYPE_ASH); 1519 chrome::HOST_DESKTOP_TYPE_ASH);
1520 } 1520 }
1521 1521
1522 void InternetOptionsHandler::NetworkCommandCallback(const ListValue* args) { 1522 void InternetOptionsHandler::NetworkCommandCallback(const ListValue* args) {
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
1764 1764
1765 dictionary->SetBoolean(kTagWimaxEnabled, cros_->wimax_enabled()); 1765 dictionary->SetBoolean(kTagWimaxEnabled, cros_->wimax_enabled());
1766 dictionary->SetBoolean(kTagWimaxAvailable, cros_->wimax_available()); 1766 dictionary->SetBoolean(kTagWimaxAvailable, cros_->wimax_available());
1767 dictionary->SetBoolean(kTagWimaxBusy, cros_->wimax_busy()); 1767 dictionary->SetBoolean(kTagWimaxBusy, cros_->wimax_busy());
1768 // TODO(kevers): The use of 'offline_mode' is not quite correct. Update once 1768 // TODO(kevers): The use of 'offline_mode' is not quite correct. Update once
1769 // we have proper back-end support. 1769 // we have proper back-end support.
1770 dictionary->SetBoolean(kTagAirplaneMode, cros_->offline_mode()); 1770 dictionary->SetBoolean(kTagAirplaneMode, cros_->offline_mode());
1771 } 1771 }
1772 1772
1773 } // namespace options 1773 } // namespace options
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698