From 43211582b1fa8c69136385250e7b0446cf364b5c Mon Sep 17 00:00:00 2001 From: "ananta@chromium.org" Date: Sun, 10 Jul 2011 15:52:27 +0000 Subject: Moving notification types which are chrome specific to a new header file chrome_notification_types.h. This file lives in chrome\common. The chrome specific notifications start from NOTIFICATION_CONTENT_END which defines the end of the enum used by content to define notification types. The notificaton_type.h file in content\common has been renamed to content_notification_types.h BUG=76698 Review URL: http://codereview.chromium.org/7327007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91972 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/net/gaia/token_service.cc | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'chrome/browser/net/gaia/token_service.cc') diff --git a/chrome/browser/net/gaia/token_service.cc b/chrome/browser/net/gaia/token_service.cc index 7069165..b382861 100644 --- a/chrome/browser/net/gaia/token_service.cc +++ b/chrome/browser/net/gaia/token_service.cc @@ -7,6 +7,7 @@ #include "base/command_line.h" #include "base/string_util.h" #include "chrome/browser/profiles/profile.h" +#include "chrome/common/chrome_notification_types.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/net/gaia/gaia_auth_fetcher.h" #include "chrome/common/net/gaia/gaia_constants.h" @@ -66,7 +67,7 @@ void TokenService::Initialize(const char* const source, #endif registrar_.Add(this, - NotificationType::TOKEN_UPDATED, + chrome::NOTIFICATION_TOKEN_UPDATED, NotificationService::AllSources()); } @@ -167,7 +168,7 @@ void TokenService::FireTokenAvailableNotification( TokenAvailableDetails details(service, auth_token); NotificationService::current()->Notify( - NotificationType::TOKEN_AVAILABLE, + chrome::NOTIFICATION_TOKEN_AVAILABLE, Source(this), Details(&details)); } @@ -178,7 +179,7 @@ void TokenService::FireTokenRequestFailedNotification( TokenRequestFailedDetails details(service, error); NotificationService::current()->Notify( - NotificationType::TOKEN_REQUEST_FAILED, + chrome::NOTIFICATION_TOKEN_REQUEST_FAILED, Source(this), Details(&details)); } @@ -222,7 +223,7 @@ void TokenService::OnWebDataServiceRequestDone(WebDataService::Handle h, } NotificationService::current()->Notify( - NotificationType::TOKEN_LOADING_FINISHED, + chrome::NOTIFICATION_TOKEN_LOADING_FINISHED, Source(this), NotificationService::NoDetails()); } @@ -254,10 +255,10 @@ void TokenService::LoadTokensIntoMemory( } } -void TokenService::Observe(NotificationType type, +void TokenService::Observe(int type, const NotificationSource& source, const NotificationDetails& details) { - DCHECK(type == NotificationType::TOKEN_UPDATED); + DCHECK(type == chrome::NOTIFICATION_TOKEN_UPDATED); TokenAvailableDetails* tok_details = Details(details).ptr(); OnIssueAuthTokenSuccess(tok_details->service(), tok_details->token()); -- cgit v1.1