fune/browser/components/preferences/sanitize.xul
Paolo Amadini 42c8938dfc Bug 1493844 - Part 2 - Remove the "caption" and "groupbox" bindings. r=bgrins,dao,jaws,johannh,surkov
Proper native "groupbox" styling depends on the structure of the XBL binding. By restyling the Page Info dialog, the native styling is now unused except for the Print Page Setup dialog on Windows. The native apperance is thus not applied by default anymore, and the "groupbox" element can just be used semantically for accessibility. The Print Page Setup dialog applies the native styling on its own in a way that still works on Windows.

The only other consumers of "groupbox" are the in-content Preferences pages and dialogs. These are updated to use simpler styles that don't depend on the binding structure.

Differential Revision: https://phabricator.services.mozilla.com/D8752

--HG--
extra : rebase_source : af36d911980517f9b53036f4cd4f800c5e20ad22
2018-10-23 10:14:06 +01:00

93 lines
3.5 KiB
XML

<?xml version="1.0"?>
<!-- -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- -->
<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<?xml-stylesheet href="chrome://global/skin/"?>
<?xml-stylesheet href="chrome://browser/skin/preferences/preferences.css"?>
<!DOCTYPE dialog [
<!ENTITY % preferencesDTD SYSTEM "chrome://global/locale/preferences.dtd">
%preferencesDTD;
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
%brandDTD;
<!ENTITY % sanitizeDTD SYSTEM "chrome://browser/locale/sanitize.dtd">
%sanitizeDTD;
]>
<dialog id="SanitizeDialog" type="child"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttons="accept,cancel,help"
persist="lastSelected screenX screenY"
role="dialog"
ondialoghelp="openPrefsHelp()"
style="width: &sanitizePrefs2.modal.width;"
title="&sanitizePrefs2.title;"
helpTopic="prefs-clear-private-data"
onload="gSanitizeDialog.init();">
<script type="application/javascript" src="chrome://browser/content/utilityOverlay.js"/>
<script type="application/javascript" src="chrome://global/content/preferencesBindings.js"/>
<keyset>
<key key="&windowClose.key;" modifiers="accel" oncommand="Preferences.close(event)"/>
</keyset>
<script type="application/javascript" src="chrome://browser/content/preferences/sanitize.js"/>
<description>&clearDataSettings4.label;</description>
<groupbox>
<caption><label>&historySection.label;</label></caption>
<grid flex="1">
<columns>
<column style="width: &sanitizePrefs2.column.width;"/>
<column flex="1"/>
</columns>
<rows>
<row>
<checkbox label="&itemHistoryAndDownloads.label;"
accesskey="&itemHistoryAndDownloads.accesskey;"
preference="privacy.clearOnShutdown.history"/>
<checkbox label="&itemCookies.label;"
accesskey="&itemCookies.accesskey;"
preference="privacy.clearOnShutdown.cookies"/>
</row>
<row>
<checkbox label="&itemActiveLogins.label;"
accesskey="&itemActiveLogins.accesskey;"
preference="privacy.clearOnShutdown.sessions"/>
<checkbox label="&itemCache.label;"
accesskey="&itemCache.accesskey;"
preference="privacy.clearOnShutdown.cache"/>
</row>
<row>
<checkbox label="&itemFormSearchHistory.label;"
accesskey="&itemFormSearchHistory.accesskey;"
preference="privacy.clearOnShutdown.formdata"/>
</row>
</rows>
</grid>
</groupbox>
<groupbox>
<caption><label>&dataSection.label;</label></caption>
<grid flex="1">
<columns>
<column style="width: &sanitizePrefs2.column.width;"/>
<column flex="1"/>
</columns>
<rows>
<row>
<checkbox label="&itemSitePreferences.label;"
accesskey="&itemSitePreferences.accesskey;"
preference="privacy.clearOnShutdown.siteSettings"/>
<checkbox label="&itemOfflineApps.label;"
accesskey="&itemOfflineApps.accesskey;"
preference="privacy.clearOnShutdown.offlineApps"/>
</row>
</rows>
</grid>
</groupbox>
</dialog>