| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/content_settings/tab_specific_content_settings.h" | 5 #include "chrome/browser/content_settings/tab_specific_content_settings.h" |
| 6 | 6 |
| 7 #include <list> | 7 #include <list> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
| (...skipping 508 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 void TabSpecificContentSettings::OnGeolocationPermissionSet( | 519 void TabSpecificContentSettings::OnGeolocationPermissionSet( |
| 520 const GURL& requesting_origin, | 520 const GURL& requesting_origin, |
| 521 bool allowed) { | 521 bool allowed) { |
| 522 geolocation_usages_state_.OnPermissionSet(requesting_origin, allowed); | 522 geolocation_usages_state_.OnPermissionSet(requesting_origin, allowed); |
| 523 content::NotificationService::current()->Notify( | 523 content::NotificationService::current()->Notify( |
| 524 chrome::NOTIFICATION_WEB_CONTENT_SETTINGS_CHANGED, | 524 chrome::NOTIFICATION_WEB_CONTENT_SETTINGS_CHANGED, |
| 525 content::Source<WebContents>(web_contents()), | 525 content::Source<WebContents>(web_contents()), |
| 526 content::NotificationService::NoDetails()); | 526 content::NotificationService::NoDetails()); |
| 527 } | 527 } |
| 528 | 528 |
| 529 #if defined(OS_ANDROID) | 529 #if defined(OS_ANDROID) || defined(OS_CHROMEOS) |
| 530 void TabSpecificContentSettings::OnProtectedMediaIdentifierPermissionSet( | 530 void TabSpecificContentSettings::OnProtectedMediaIdentifierPermissionSet( |
| 531 const GURL& requesting_origin, | 531 const GURL& requesting_origin, |
| 532 bool allowed) { | 532 bool allowed) { |
| 533 if (allowed) { | 533 if (allowed) { |
| 534 OnContentAllowed(CONTENT_SETTINGS_TYPE_PROTECTED_MEDIA_IDENTIFIER); | 534 OnContentAllowed(CONTENT_SETTINGS_TYPE_PROTECTED_MEDIA_IDENTIFIER); |
| 535 } else { | 535 } else { |
| 536 OnContentBlocked(CONTENT_SETTINGS_TYPE_PROTECTED_MEDIA_IDENTIFIER); | 536 OnContentBlocked(CONTENT_SETTINGS_TYPE_PROTECTED_MEDIA_IDENTIFIER); |
| 537 } | 537 } |
| 538 } | 538 } |
| 539 #endif | 539 #endif |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 813 | 813 |
| 814 void TabSpecificContentSettings::GeolocationDidNavigate( | 814 void TabSpecificContentSettings::GeolocationDidNavigate( |
| 815 const content::LoadCommittedDetails& details) { | 815 const content::LoadCommittedDetails& details) { |
| 816 geolocation_usages_state_.DidNavigate(GetCommittedDetails(details)); | 816 geolocation_usages_state_.DidNavigate(GetCommittedDetails(details)); |
| 817 } | 817 } |
| 818 | 818 |
| 819 void TabSpecificContentSettings::MidiDidNavigate( | 819 void TabSpecificContentSettings::MidiDidNavigate( |
| 820 const content::LoadCommittedDetails& details) { | 820 const content::LoadCommittedDetails& details) { |
| 821 midi_usages_state_.DidNavigate(GetCommittedDetails(details)); | 821 midi_usages_state_.DidNavigate(GetCommittedDetails(details)); |
| 822 } | 822 } |
| OLD | NEW |