Files
tubestation/browser/components/shell/content/setDesktopBackground.xul
Ian Moody f9cede0ea2 Bug 1547459 - Use explicit text for desktop span preview not being available. r=sfoster
When I implemented the no preview for span I did originally try using text in
the canvas, but discarded it when I realised trying to format it to display
nicely (across different languages and text lengths) was a losing proposition.
However just the prohibition symbol without context is confusing to users, and
on reflection the text can easily be included as an element stacked on top of
the canvas.

Also lighten the background of the no preview message, since the pure black was
indistinguishable from the frame sides on Windows and Linux.

Differential Revision: https://phabricator.services.mozilla.com/D29750
2019-05-06 18:55:57 +00:00

91 lines
3.1 KiB
XML

<?xml version="1.0"?> <!-- -*- Mode: HTML -*- -->
# 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/" type="text/css"?>
<?xml-stylesheet href="chrome://browser/skin/setDesktopBackground.css" type="text/css"?>
<!DOCTYPE dialog [
<!ENTITY % setDesktopBackgroundDTD SYSTEM "chrome://browser/locale/setDesktopBackground.dtd">
%setDesktopBackgroundDTD;
#ifdef XP_MACOSX
#include ../../../base/content/browser-doctype.inc
#endif
]>
<dialog xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:html="http://www.w3.org/1999/xhtml"
windowtype="Shell:SetDesktopBackground"
#ifndef XP_MACOSX
buttons="accept,cancel"
#else
buttons="accept"
#endif
buttonlabelaccept="&setDesktopBackground.title;"
onload="gSetBackground.load();"
title="&setDesktopBackground.title;"
style="width: 30em;">
#ifdef XP_MACOSX
#include ../../../base/content/macWindow.inc.xul
#endif
<stringbundle id="backgroundBundle"
src="chrome://browser/locale/shellservice.properties"/>
<script src="chrome://browser/content/utilityOverlay.js"/>
<script src="chrome://browser/content/setDesktopBackground.js"/>
<script src="chrome://global/content/contentAreaUtils.js"/>
#ifndef XP_MACOSX
<hbox align="center">
<label value="&position.label;"/>
<menulist id="menuPosition"
label="&position.label;"
oncommand="gSetBackground.updatePosition();">
<menupopup>
<menuitem label="&center.label;" value="CENTER"/>
<menuitem label="&tile.label;" value="TILE"/>
<menuitem label="&stretch.label;" value="STRETCH"/>
<menuitem label="&fill.label;" value="FILL"/>
<menuitem label="&fit.label;" value="FIT"/>
<menuitem label="&span.label;" value="SPAN" id="spanPosition"/>
</menupopup>
</menulist>
<spacer flex="1"/>
<label value="&color.label;"/>
<html:input id="desktopColor"
type="color"
onchange="gSetBackground.updateColor(this.value);"/>
</hbox>
#endif
<vbox align="center">
<!-- default to 16:9, will be adjusted to match user's actual screen -->
<stack>
<html:canvas id="screen" width="202" height="114" role="presentation"/>
<vbox pack="center">
<html:p id="preview-unavailable" hidden="">&previewUnavailable;</html:p>
</vbox>
</stack>
<image id="monitor-base"/>
</vbox>
#ifdef XP_MACOSX
<separator/>
<hbox align="right">
<button id="setDesktopBackground"
label="&setDesktopBackground.title;"
oncommand="gSetBackground.setDesktopBackground();"/>
<button id="showDesktopPreferences"
label="&openDesktopPrefs.label;"
oncommand="gSetBackground.showDesktopPrefs();"
hidden="true"/>
</hbox>
#endif
</dialog>