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

Side by Side Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 1274383002: Remove deprecated CONTENT_SETTINGS_TYPE_METRO_SWITCH_TO_DESKTOP content setting (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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
OLDNEW
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/ui/webui/options/content_settings_handler.h" 5 #include "chrome/browser/ui/webui/options/content_settings_handler.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 748 matching lines...) Expand 10 before | Expand all | Expand 10 after
759 // The RPH settings are retrieved separately. 759 // The RPH settings are retrieved separately.
760 break; 760 break;
761 case CONTENT_SETTINGS_TYPE_MIDI_SYSEX: 761 case CONTENT_SETTINGS_TYPE_MIDI_SYSEX:
762 UpdateMIDISysExExceptionsView(); 762 UpdateMIDISysExExceptionsView();
763 break; 763 break;
764 case CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS: 764 case CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS:
765 // The content settings type CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS is 765 // The content settings type CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS is
766 // supposed to be set by flags and field trials only, thus there is no 766 // supposed to be set by flags and field trials only, thus there is no
767 // user facing UI for this content type and we skip it here. 767 // user facing UI for this content type and we skip it here.
768 break; 768 break;
769 #if defined(OS_WIN)
770 case CONTENT_SETTINGS_TYPE_METRO_SWITCH_TO_DESKTOP:
771 break;
772 #endif
773 case CONTENT_SETTINGS_TYPE_APP_BANNER: 769 case CONTENT_SETTINGS_TYPE_APP_BANNER:
774 // The content settings type CONTENT_SETTINGS_TYPE_APP_BANNER is used to 770 // The content settings type CONTENT_SETTINGS_TYPE_APP_BANNER is used to
775 // track whether app banners should be shown or not, and is not a user 771 // track whether app banners should be shown or not, and is not a user
776 // visible content setting. 772 // visible content setting.
777 break; 773 break;
778 case CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT: 774 case CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT:
779 // The content settings type CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT is used 775 // The content settings type CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT is used
780 // to track engagement with various origins, and is not a user visible 776 // to track engagement with various origins, and is not a user visible
781 // content setting. 777 // content setting.
782 break; 778 break;
783 case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE: 779 case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE:
784 // Durable storage is not yet user visible. TODO(dgrogan): Make it so. 780 // Durable storage is not yet user visible. TODO(dgrogan): Make it so.
785 // https://crbug.com/482814 781 // https://crbug.com/482814
786 break; 782 break;
787 default: 783 default:
788 UpdateExceptionsViewFromHostContentSettingsMap(type); 784 UpdateExceptionsViewFromHostContentSettingsMap(type);
789 break; 785 break;
790 } 786 }
791 } 787 }
792 788
793 void ContentSettingsHandler::UpdateOTRExceptionsViewFromModel( 789 void ContentSettingsHandler::UpdateOTRExceptionsViewFromModel(
794 ContentSettingsType type) { 790 ContentSettingsType type) {
795 switch (type) { 791 switch (type) {
796 case CONTENT_SETTINGS_TYPE_GEOLOCATION: 792 case CONTENT_SETTINGS_TYPE_GEOLOCATION:
797 case CONTENT_SETTINGS_TYPE_NOTIFICATIONS: 793 case CONTENT_SETTINGS_TYPE_NOTIFICATIONS:
798 case CONTENT_SETTINGS_TYPE_AUTO_SELECT_CERTIFICATE: 794 case CONTENT_SETTINGS_TYPE_AUTO_SELECT_CERTIFICATE:
799 case CONTENT_SETTINGS_TYPE_MIXEDSCRIPT: 795 case CONTENT_SETTINGS_TYPE_MIXEDSCRIPT:
800 #if defined(OS_WIN)
801 case CONTENT_SETTINGS_TYPE_METRO_SWITCH_TO_DESKTOP:
802 #endif
803 case CONTENT_SETTINGS_TYPE_MEDIASTREAM: 796 case CONTENT_SETTINGS_TYPE_MEDIASTREAM:
804 case CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC: 797 case CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC:
805 case CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA: 798 case CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA:
806 case CONTENT_SETTINGS_TYPE_AUTOMATIC_DOWNLOADS: 799 case CONTENT_SETTINGS_TYPE_AUTOMATIC_DOWNLOADS:
807 case CONTENT_SETTINGS_TYPE_MIDI_SYSEX: 800 case CONTENT_SETTINGS_TYPE_MIDI_SYSEX:
808 case CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS: 801 case CONTENT_SETTINGS_TYPE_SSL_CERT_DECISIONS:
809 case CONTENT_SETTINGS_TYPE_APP_BANNER: 802 case CONTENT_SETTINGS_TYPE_APP_BANNER:
810 case CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT: 803 case CONTENT_SETTINGS_TYPE_SITE_ENGAGEMENT:
811 case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE: 804 case CONTENT_SETTINGS_TYPE_DURABLE_STORAGE:
812 break; 805 break;
(...skipping 811 matching lines...) Expand 10 before | Expand all | Expand 10 after
1624 1617
1625 // Exceptions apply only when the feature is enabled. 1618 // Exceptions apply only when the feature is enabled.
1626 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui())); 1619 PrefService* prefs = user_prefs::UserPrefs::Get(GetBrowserContext(web_ui()));
1627 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM); 1620 bool enable_exceptions = prefs->GetBoolean(prefs::kEnableDRM);
1628 web_ui()->CallJavascriptFunction( 1621 web_ui()->CallJavascriptFunction(
1629 "ContentSettings.enableProtectedContentExceptions", 1622 "ContentSettings.enableProtectedContentExceptions",
1630 base::FundamentalValue(enable_exceptions)); 1623 base::FundamentalValue(enable_exceptions));
1631 } 1624 }
1632 1625
1633 } // namespace options 1626 } // namespace options
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698