summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/browser.cc6
-rw-r--r--chrome/browser/ssl/ssl_manager.cc2
-rw-r--r--chrome/browser/ssl/ssl_policy.cc6
-rw-r--r--chrome/common/notification_type.h23
4 files changed, 24 insertions, 13 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc
index 6c5a2c6..c1915aa 100644
--- a/chrome/browser/browser.cc
+++ b/chrome/browser/browser.cc
@@ -183,7 +183,7 @@ Browser::Browser(Type type, Profile* profile)
NotificationService::current()->AddObserver(
this,
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
NotificationService::AllSources());
InitCommandState();
@@ -228,7 +228,7 @@ Browser::~Browser() {
NotificationService::current()->RemoveObserver(
this,
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
NotificationService::AllSources());
if (profile_->IsOffTheRecord() &&
@@ -1932,7 +1932,7 @@ void Browser::Observe(NotificationType type,
}
break;
- case NotificationType::SSL_STATE_CHANGED:
+ case NotificationType::SSL_VISIBLE_STATE_CHANGED:
// When the current tab's SSL state changes, we need to update the URL
// bar to reflect the new state. Note that it's possible for the selected
// tab contents to be NULL. This is because we listen for all sources
diff --git a/chrome/browser/ssl/ssl_manager.cc b/chrome/browser/ssl/ssl_manager.cc
index 42fc860..f10a344 100644
--- a/chrome/browser/ssl/ssl_manager.cc
+++ b/chrome/browser/ssl/ssl_manager.cc
@@ -633,7 +633,7 @@ void SSLManager::DidCommitProvisionalLoad(
if (changed) {
// Only send the notification when something actually changed.
NotificationService::current()->Notify(
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
Source<NavigationController>(controller_),
NotificationService::NoDetails());
}
diff --git a/chrome/browser/ssl/ssl_policy.cc b/chrome/browser/ssl/ssl_policy.cc
index 6e627fb..599f45c 100644
--- a/chrome/browser/ssl/ssl_policy.cc
+++ b/chrome/browser/ssl/ssl_policy.cc
@@ -267,7 +267,7 @@ class DefaultPolicy : public SSLPolicy {
if (error->manager()->SetMaxSecurityStyle(
SECURITY_STYLE_AUTHENTICATION_BROKEN)) {
NotificationService::current()->Notify(
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
Source<NavigationController>(error->manager()->controller()),
Details<NavigationEntry>(
error->manager()->controller()->GetActiveEntry()));
@@ -322,7 +322,7 @@ class DefaultPolicy : public SSLPolicy {
AddMessageToConsole(msg, MESSAGE_LEVEL_WARNING);
NotificationService::current()->Notify(
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
Source<NavigationController>(navigation_controller),
Details<NavigationEntry>(entry));
}
@@ -420,7 +420,7 @@ void SSLPolicy::OnRequestStarted(SSLManager* manager, const GURL& url,
if (changed) {
// Only send the notification when something actually changed.
NotificationService::current()->Notify(
- NotificationType::SSL_STATE_CHANGED,
+ NotificationType::SSL_VISIBLE_STATE_CHANGED,
Source<NavigationController>(manager->controller()),
NotificationService::NoDetails());
}
diff --git a/chrome/common/notification_type.h b/chrome/common/notification_type.h
index 5e59742..942c072 100644
--- a/chrome/common/notification_type.h
+++ b/chrome/common/notification_type.h
@@ -132,15 +132,26 @@ class NotificationType {
// are provided.
RESOURCE_RECEIVED_REDIRECT,
- // The SSL state of a page has changed somehow. For example, if an insecure
- // resource is loaded on a secure page. Note that a toplevel load commit
- // will also update the SSL state (since the NavigationEntry is new) and
- // this message won't always be sent in that case.
+ // The SSL state of a page has changed in some visible way. For example,
+ // if an insecure resource is loaded on a secure page. Note that a
+ // toplevel load commit will also update the SSL state (since the
+ // NavigationEntry is new) and this message won't always be sent in that
+ // case. Listen to this notification if you need to refresh SSL-related UI
+ // elements.
//
// The source will be the navigation controller associated with the load.
- // There are no details. The entry changed will be the active entry of the
+ // There are no details. The entry changed will be the active entry of the
// controller.
- SSL_STATE_CHANGED,
+ SSL_VISIBLE_STATE_CHANGED,
+
+ // The SSL state of the browser has changed in some internal way. For
+ // example, the user might have explicitly allowed some broken certificate
+ // or a secure origin might have included some insecure content. Listen to
+ // this notifiation if you need to keep track of our internal SSL state.
+ //
+ // The source will be the navigation controller associated with the state
+ // change. There are no details.
+ SSL_INTERNAL_STATE_CHANGED,
// Download start and stop notifications. Stop notifications can occur on
// both normal completion or via a cancel operation.