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

Side by Side Diff: chrome/browser/ui/webui/settings/chromeos/internet_handler.h

Issue 2426473009: mash: Place views Wi-Fi network config dialogs in correct window parent (Closed)
Patch Set: rebase Created 4 years, 2 months 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "chrome/browser/ui/webui/settings/settings_page_ui_handler.h" 11 #include "chrome/browser/ui/webui/settings/settings_page_ui_handler.h"
12 #include "ui/gfx/native_widget_types.h" 12 #include "ui/gfx/native_widget_types.h"
13 13
14 namespace views {
15 struct WidgetParent;
16 }
17
14 namespace chromeos { 18 namespace chromeos {
15 namespace settings { 19 namespace settings {
16 20
17 // Chrome OS Internet settings page UI handler. 21 // Chrome OS Internet settings page UI handler.
18 class InternetHandler : public ::settings::SettingsPageUIHandler { 22 class InternetHandler : public ::settings::SettingsPageUIHandler {
19 public: 23 public:
20 InternetHandler(); 24 InternetHandler();
21 ~InternetHandler() override; 25 ~InternetHandler() override;
22 26
23 // SettingsPageUIHandler implementation. 27 // SettingsPageUIHandler implementation.
24 void RegisterMessages() override; 28 void RegisterMessages() override;
25 void OnJavascriptAllowed() override; 29 void OnJavascriptAllowed() override;
26 void OnJavascriptDisallowed() override; 30 void OnJavascriptDisallowed() override;
27 31
28 private: 32 private:
29 // Settings JS handlers. 33 // Settings JS handlers.
30 void AddNetwork(const base::ListValue* args); 34 void AddNetwork(const base::ListValue* args);
31 void ConfigureNetwork(const base::ListValue* args); 35 void ConfigureNetwork(const base::ListValue* args);
32 36
37 // Deprecated: Use GetWidgetParent() instead.
33 gfx::NativeWindow GetNativeWindow() const; 38 gfx::NativeWindow GetNativeWindow() const;
34 39
40 // Returns a parent for hosting dialogs.
41 views::WidgetParent GetWidgetParent() const;
42
35 DISALLOW_COPY_AND_ASSIGN(InternetHandler); 43 DISALLOW_COPY_AND_ASSIGN(InternetHandler);
36 }; 44 };
37 45
38 } // namespace settings 46 } // namespace settings
39 } // namespace chromeos 47 } // namespace chromeos
40 48
41 #endif // CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_ 49 #endif // CHROME_BROWSER_UI_WEBUI_SETTINGS_CHROMEOS_INTERNET_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698