| Index: chrome/browser/ui/webui/options/content_settings_handler.cc
|
| diff --git a/chrome/browser/ui/webui/options/content_settings_handler.cc b/chrome/browser/ui/webui/options/content_settings_handler.cc
|
| index 83e99e915d649078e2340feff2fbc43f8afd7cff..48865b87f76380e62c5a33669d3cd4353796d002 100644
|
| --- a/chrome/browser/ui/webui/options/content_settings_handler.cc
|
| +++ b/chrome/browser/ui/webui/options/content_settings_handler.cc
|
| @@ -527,16 +527,21 @@ void ContentSettingsHandler::Observe(
|
| const content::NotificationDetails& details) {
|
| switch (type) {
|
| case chrome::NOTIFICATION_PROFILE_DESTROYED: {
|
| - if (content::Source<Profile>(source).ptr()->IsOffTheRecord()) {
|
| + Profile* profile = content::Source<Profile>(source).ptr();
|
| + if (profile->IsOffTheRecord()) {
|
| web_ui()->CallJavascriptFunction(
|
| "ContentSettingsExceptionsArea.OTRProfileDestroyed");
|
| + observer_.Remove(profile->GetHostContentSettingsMap());
|
| }
|
| break;
|
| }
|
|
|
| case chrome::NOTIFICATION_PROFILE_CREATED: {
|
| - if (content::Source<Profile>(source).ptr()->IsOffTheRecord())
|
| + Profile* profile = content::Source<Profile>(source).ptr();
|
| + if (profile->IsOffTheRecord()) {
|
| UpdateAllOTRExceptionsViewsFromModel();
|
| + observer_.Add(profile->GetHostContentSettingsMap());
|
| + }
|
| break;
|
| }
|
|
|
|
|