Browse Source

[Navigator] Add UX consistency to sanitize, cookies, and permissions

master
Matt A. Tobin 2 years ago committed by Roy Tam
parent
commit
2430631fab
  1. 12
      navigator/comm/content/sanitize.xul
  2. 5
      navigator/comm/locale/sanitize.dtd
  3. 14
      navigator/components/permissions/content/cookies.xul
  4. 5
      navigator/components/permissions/content/permissions.js
  5. 21
      navigator/components/permissions/content/permissions.xul
  6. 3
      navigator/components/permissions/locale/cookies.dtd
  7. 3
      navigator/components/permissions/locale/permissions.dtd
  8. 2
      navigator/components/permissions/locale/permissions.properties

12
navigator/comm/content/sanitize.xul

@ -56,9 +56,16 @@
]]>
</script>
<description>&sanitizeItems.label;</description>
<dialogheader class="header-large"
id="header"
title="&sanitizeDialog.headerTitle;"
description="&sanitizeItems.label;"/>
<vbox id="sanitizePreferences" align="start" oncommand="onCommand(event);">
<vbox id="sanitizePreferences"
align="start"
flex="1"
style="margin-top: 2px; margin-left: 12px; margin-right: 12px;"
oncommand="onCommand(event);">
<checkbox label="&itemHistory.label;"
accesskey="&itemHistory.accesskey;"
name="history"/>
@ -88,4 +95,5 @@
name="sessions"/>
</vbox>
<separator class="groove"/>
</dialog>

5
navigator/comm/locale/sanitize.dtd

@ -3,7 +3,8 @@
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
<!ENTITY sanitizeDialog.title "Clear Private Data">
<!ENTITY sanitizeItems.label "Clear the following items now:">
<!ENTITY sanitizeDialog.headerTitle "&brandFullName; Private Data">
<!ENTITY sanitizeItems.label "Select Items to Clear">
<!ENTITY itemHistory.label "Browsing History">
<!ENTITY itemHistory.accesskey "B">
@ -24,4 +25,4 @@
<!ENTITY itemSessions.label "Authenticated Sessions">
<!ENTITY itemSessions.accesskey "S">
<!ENTITY sanitizeButton.label "Clear Private Data Now">
<!ENTITY sanitizeButton.label "Clear Now">

14
navigator/components/permissions/content/cookies.xul

@ -7,7 +7,12 @@
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://navigator/content/permissions/cookies.css" type="text/css"?>
<!DOCTYPE dialog SYSTEM "chrome://navigator/locale/permissions/cookies.dtd" >
<!DOCTYPE dialog [
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
%brandDTD;
<!ENTITY % cookiesDTD SYSTEM "chrome://navigator/locale/permissions/cookies.dtd">
%cookiesDTD;
]>
<window id="CookiesDialog" windowtype="permissions:cookieManager"
class="windowDialog" title="&window.title;"
@ -29,6 +34,12 @@
<key key="&focusSearch2.key;" modifiers="accel" oncommand="gCookiesWindow.focusFilterBox();"/>
</keyset>
<dialogheader class="header-large"
id="header"
style="margin-top: 0px; margin-left: 0px;"
title="&header.title;"
description="&header.description;"/>
<vbox flex="1" class="contentPane">
<hbox align="center">
<label accesskey="&filter.accesskey;" control="filter">&filter.label;</label>
@ -87,6 +98,7 @@
</rows>
</grid>
</hbox>
<separator class="groove"/>
</vbox>
<hbox align="end">
<hbox class="actionButtons" flex="1">

5
navigator/components/permissions/content/permissions.js

@ -108,7 +108,6 @@ var gPermissionManager = {
} catch(ex) {
var message = this._bundle.getString("invalidURI");
var title = this._bundle.getString("invalidURITitle");
Services.prompt.alert(window, title, message);
return;
}
@ -236,6 +235,10 @@ var gPermissionManager = {
document.title = this._bundle.getString(aParams.windowTitle);
document.documentElement.setAttribute("windowtype", aParams.windowType);
document.getElementById("header").setAttribute("description",
this._bundle.getString("manage") + " " +
this._bundle.getString(aParams.windowTitle));
document.getElementById("btnBlock").hidden = !aParams.blockVisible;
document.getElementById("btnSession").hidden = !aParams.sessionVisible;
document.getElementById("btnAllow").hidden = !aParams.allowVisible;

21
navigator/components/permissions/content/permissions.xul

@ -8,7 +8,12 @@
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://navigator/content/permissions/permissions.css" type="text/css"?>
<!DOCTYPE dialog SYSTEM "chrome://navigator/locale/permissions/permissions.dtd" >
<!DOCTYPE dialog [
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
%brandDTD;
<!ENTITY % permissionsDTD SYSTEM "chrome://navigator/locale/permissions/permissions.dtd">
%permissionsDTD;
]>
<window id="PermissionsDialog" class="windowDialog"
windowtype="permissions:manager"
@ -29,7 +34,13 @@
<keyset>
<key key="&windowClose.key;" modifiers="accel" oncommand="window.close();"/>
</keyset>
<dialogheader class="header-large"
id="header"
style="margin-top: 0px; margin-left: 0px;"
title="&header.title;"
description="&header.description;"/>
<vbox class="contentPane" flex="1">
<description id="permissionsText" control="url"/>
<separator class="thin"/>
@ -73,7 +84,9 @@
accesskey="&removeallpermissions.accesskey;"
oncommand="gPermissionManager.onAllPermissionsDeleted();"/>
</hbox>
<spacer flex="1"/>
</vbox>
<separator class="groove" style="margin-left: 8px; margin-right: 8px"/>
<hbox align="end">
<hbox class="actionButtons" align="right" flex="1">
<button oncommand="close();" icon="close"
label="&button.cancel.label;" accesskey="&button.cancel.accesskey;" />
@ -81,5 +94,5 @@
label="&button.ok.label;" accesskey="&button.ok.accesskey;"/>
</hbox>
<resizer type="window" dir="bottomend"/>
</vbox>
</hbox>
</window>

3
navigator/components/permissions/locale/cookies.dtd

@ -16,6 +16,9 @@
<!ENTITY props.expires.label "Expires:">
<!ENTITY window.title "Cookie Manager">
<!ENTITY header.title "&brandFullName; Cookie Manager">
<!ENTITY header.description "Manage Stored Cookies">
<!ENTITY windowClose.key "w">
<!ENTITY focusSearch1.key "f">
<!ENTITY focusSearch2.key "k">

3
navigator/components/permissions/locale/permissions.dtd

@ -5,6 +5,9 @@
<!ENTITY window.title "Exceptions">
<!ENTITY window.width "45em">
<!ENTITY header.title "&brandFullName; Permissions Manager">
<!ENTITY header.description "Manage Permissions">
<!ENTITY treehead.sitename.label "Site">
<!ENTITY treehead.status.label "Status">
<!ENTITY removepermission.label "Remove Site">

2
navigator/components/permissions/locale/permissions.properties

@ -10,6 +10,8 @@ canAccessFirstParty=Allow first party only
canSession=Allow for Session
cannot=Block
manage=Manage
cookie.title=Cookie Permissions
cookie.text=You can specify which websites are always or never allowed to use cookies or store site data. Type the exact address of the site you want to manage and then click Block, Allow for Session, or Allow.

Loading…
Cancel
Save