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

Side by Side Diff: chrome/browser/chromeos/login/proxy_settings_dialog.cc

Issue 8342048: Make NotificationService an interface in the content namespace, and switch callers to use it. Mov... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/proxy_settings_dialog.h" 5 #include "chrome/browser/chromeos/login/proxy_settings_dialog.h"
6 6
7 #include "chrome/browser/chromeos/login/helper.h" 7 #include "chrome/browser/chromeos/login/helper.h"
8 #include "chrome/common/url_constants.h" 8 #include "chrome/common/url_constants.h"
9 #include "chrome/common/chrome_notification_types.h" 9 #include "chrome/common/chrome_notification_types.h"
10 #include "content/common/notification_service.h" 10 #include "content/public/browser/notification_service.h"
11 #include "ui/gfx/rect.h" 11 #include "ui/gfx/rect.h"
12 #include "ui/gfx/size.h" 12 #include "ui/gfx/size.h"
13 13
14 namespace { 14 namespace {
15 15
16 // Hints for size of proxy settings dialog. 16 // Hints for size of proxy settings dialog.
17 const int kProxySettingsDialogReasonableWidth = 750; 17 const int kProxySettingsDialogReasonableWidth = 750;
18 const int kProxySettingsDialogReasonableHeight = 550; 18 const int kProxySettingsDialogReasonableHeight = 550;
19 const float kProxySettingsDialogReasonableWidthRatio = 0.4f; 19 const float kProxySettingsDialogReasonableWidthRatio = 0.4f;
20 const float kProxySettingsDialogReasonableHeightRatio = 0.4f; 20 const float kProxySettingsDialogReasonableHeightRatio = 0.4f;
(...skipping 20 matching lines...) Expand all
41 SetDialogSize(CalculateSize(screen_bounds.width(), 41 SetDialogSize(CalculateSize(screen_bounds.width(),
42 kProxySettingsDialogReasonableWidth, 42 kProxySettingsDialogReasonableWidth,
43 kProxySettingsDialogReasonableWidthRatio), 43 kProxySettingsDialogReasonableWidthRatio),
44 CalculateSize(screen_bounds.height(), 44 CalculateSize(screen_bounds.height(),
45 kProxySettingsDialogReasonableHeight, 45 kProxySettingsDialogReasonableHeight,
46 kProxySettingsDialogReasonableHeightRatio)); 46 kProxySettingsDialogReasonableHeightRatio));
47 } 47 }
48 48
49 void ProxySettingsDialog::OnDialogClosed(const std::string& json_retval) { 49 void ProxySettingsDialog::OnDialogClosed(const std::string& json_retval) {
50 LoginHtmlDialog::OnDialogClosed(json_retval); 50 LoginHtmlDialog::OnDialogClosed(json_retval);
51 NotificationService::current()->Notify( 51 content::NotificationService::current()->Notify(
52 chrome::NOTIFICATION_LOGIN_PROXY_CHANGED, 52 chrome::NOTIFICATION_LOGIN_PROXY_CHANGED,
53 NotificationService::AllSources(), 53 content::NotificationService::AllSources(),
54 NotificationService::NoDetails()); 54 content::NotificationService::NoDetails());
55 } 55 }
56 56
57 } // namespace chromeos 57 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/profile_image_downloader.cc ('k') | chrome/browser/chromeos/login/screen_lock_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698