Bug 912889 - Add tooltips and help to App Manager. r=paul.rouget

This commit is contained in:
J. Ryan Stinnett 2013-09-13 11:43:49 -05:00
Родитель 2b4d7fe04f
Коммит 4e20722c70
5 изменённых файлов: 55 добавлений и 25 удалений

Просмотреть файл

@ -25,7 +25,7 @@
<div id="status" class="banner-box">
<div class="banner-content">
<span template='{"type":"localizedContent","property":"connection.connectedToDevice","paths":["device.description.name"]}'></span>
<button class="action-cancel" onclick="UI.disconnect()">&connection.disconnect;</button>
<button class="action-cancel" onclick="UI.disconnect()" title="&connection.disconnectTooltip;">&connection.disconnect;</button>
</div>
</div>
</div>
@ -36,11 +36,11 @@
<div class="banner-box">
<div class="banner-content">
<span>&connection.notConnected;</span>
<button class="action-primary left" onclick="UI.connect()" id="connect-button" template='{"type":"localizedContent","property":"connection.connectTo","paths":["connection.host","connection.port"]}'></button>
<button class="right" onclick="UI.editConnectionParameters()">&connection.changeHostAndPort;</button>
<button class="action-primary left" onclick="UI.connect()" id="connect-button" template='{"type":"localizedContent","property":"connection.connectTo","paths":["connection.host","connection.port"]}' title="&connection.connectTooltip;"></button>
<button class="right" onclick="UI.editConnectionParameters()" title="&connection.changeHostAndPortTooltip;">&connection.changeHostAndPort;</button>
<div id="start-simulator-box">
<span>&connection.or;</span>
<button id="start-simulator-button" class="action-primary" onclick="UI.showSimulatorList()">&connection.startSimulator;</button>
<button id="start-simulator-button" class="action-primary" onclick="UI.showSimulatorList()" title="&connection.startSimulatorTooltip;">&connection.startSimulator;</button>
</div>
</div>
</div>
@ -52,7 +52,7 @@
<div id="status" class="banner-box">
<div class="banner-content">
<span>&connection.connecting;</span>
<button class="action-cancel" onclick="UI.disconnect()">&connection.cancel;</button>
<button class="action-cancel" onclick="UI.disconnect()" title="&connection.cancelConnectTooltip;">&connection.cancel;</button>
</div>
</div>
</div>
@ -75,7 +75,7 @@
<form onsubmit="UI.saveConnectionInfo()">
<input class="host" template='{"type":"attribute","path":"connection.host","name":"value"}'></input>
<input class="port" pattern="\d+" template='{"type":"attribute","path":"connection.port","name":"value"}' type="number"></input>
<button type="submit">&connection.saveConnectionInfo;</button>
<button type="submit" title="&connection.saveConnectionInfoTooltip;">&connection.saveConnectionInfo;</button>
</form>
</div>
</div>
@ -88,13 +88,13 @@
<div class="banner-content">
<div class="no-simulator">
<span>&connection.noSimulatorInstalled;</span>
<button class="action-primary" onclick="UI.installSimulator()">&connection.installFirstSimulator;</button>
<button class="action-primary" onclick="UI.installSimulator()" title="&connection.installOneSimulatorTooltip;">&connection.installOneSimulator;</button>
</div>
<div class="found-simulator">
<span template-loop='{"arrayPath":"simulators.versions","childSelector":"#simulator-item-template"}'></span>
<button class="action-primary" onclick="UI.installSimulator()">&connection.installAnotherSimulator;</button>
<button class="action-primary" onclick="UI.installSimulator()" title="&connection.installAnotherSimulatorTooltip;">&connection.installAnotherSimulator;</button>
</div>
<button class="action-cancel" onclick="UI.cancelShowSimulatorList()">&connection.cancel;</button>
<button class="action-cancel" onclick="UI.cancelShowSimulatorList()" title="&connection.cancelShowSimulatorTooltip;">&connection.cancel;</button>
</div>
</div>
</div>
@ -113,7 +113,7 @@
<template id="simulator-item-template">
<span>
<button class="simulator-item" onclick="UI.startSimulator(this.dataset.version)" template='{"type":"attribute","path":"version","name":"data-version"}'>
<button class="simulator-item" onclick="UI.startSimulator(this.dataset.version)" template='{"type":"attribute","path":"version","name":"data-version"}' title="&connection.startSimulatorTooltip;">
<span template='{"type":"textContent", "path":"version"}'></span>
</button>
</span>

Просмотреть файл

@ -36,10 +36,15 @@
</h3>
<p template='{"type":"localizedContent","property":"device.deviceSize", "paths":["device.description.width","device.description.height","device.description.dpi"]}'></p>
</header>
<button onclick="UI.screenshot()">&device.screenshot;</button>
<button onclick="UI.screenshot()" title="&device.screenshotTooltip;">&device.screenshot;</button>
<div id="tabs-headers">
<div onclick="UI.setTab('apps')" class="tab sidebar-item apps">&device.installedApps;</div>
<div onclick="UI.setTab('permissions')" class="tab sidebar-item permissions">&device.permissions;</div>
<div onclick="UI.setTab('apps')" class="tab sidebar-item apps" title="&device.installedAppsTooltip;">&device.installedApps;</div>
<div onclick="UI.setTab('permissions')" class="tab sidebar-item permissions" title="&device.permissionsTooltip;">
&device.permissions;
<a target="_blank" href="&device.permissionsHelpLink;">
<button class="help">&device.help;</button>
</a>
</div>
</div>
</div>
</aside>
@ -59,9 +64,9 @@
<section template-loop='{"arrayPath":"device.permissions","childSelector":"#permission-template"}'></section>
</div>
<div class="permission-table-footer">
<div class="allow-label">&device.allow;</div>
<div class="prompt-label">&device.prompt;</div>
<div class="deny-label">&device.deny;</div>
<div class="allow-label" title="&device.allowTooltip;">&device.allow;</div>
<div class="prompt-label" title="&device.promptTooltip;">&device.prompt;</div>
<div class="deny-label" title="&device.denyTooltip;">&device.deny;</div>
</div>
</div>
</div>
@ -84,9 +89,9 @@
<img class="app-icon" template='{"type":"attribute","path":"iconURL","name":"src"}'></img>
<span class="app-name" template='{"type":"textContent","path":"name"}'></span>
<div class="app-buttons">
<button class="button-debug" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.openToolbox(this.dataset.manifest)">&device.debugApp;</button>
<button class="button-start" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.startApp(this.dataset.manifest)">&device.startApp;</button>
<button class="button-stop" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.stopApp(this.dataset.manifest)">&device.stopApp;</button>
<button class="button-debug" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.openToolbox(this.dataset.manifest)" title="&device.debugAppTooltip;">&device.debugApp;</button>
<button class="button-start" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.startApp(this.dataset.manifest)" title="&device.startAppTooltip;">&device.startApp;</button>
<button class="button-stop" template='{"type":"attribute","path":"manifestURL","name":"data-manifest"}' onclick="UI.stopApp(this.dataset.manifest)" title="&device.stopAppTooltip;">&device.stopApp;</button>
</div>
</div>
</template>

Просмотреть файл

@ -22,11 +22,11 @@
<div template-loop='{"arrayPath":"projects","childSelector":"#project-item-template"}'></div>
<div id="no-project">&projects.noProjects;</div>
</div>
<div id="new-packaged-project" onclick="UI.addPackaged()">&projects.addPackaged;</div>
<div id="new-packaged-project" onclick="UI.addPackaged()" title="&projects.addPackagedTooltip;">&projects.addPackaged;</div>
<div id="new-hosted-project">&projects.addHosted;
<form onsubmit="UI.addHosted(); return false;" id="new-hosted-project-wrapper">
<input value="" id="url-input" type="url" pattern="https?://.+" placeholder="&projects.hostedManifestPlaceHolder2;" size="50" />
<div onclick="UI.addHosted()" id="new-hosted-project-click"></div>
<div onclick="UI.addHosted()" id="new-hosted-project-click" title="&projects.addHostedTooltip;"></div>
<input type="submit" hidden="true"></input>
</form>
</div>
@ -39,7 +39,7 @@
<div class="project-item-status" template='{"type":"attribute","path":"validationStatus","name":"status"}'></div>
<img class="project-item-icon" template='{"type":"attribute","path":"icon","name":"src"}' />
<div class="project-item-meta">
<div class="button-remove" onclick="UI.remove(this.dataset.location)" template='{"type":"attribute","path":"location","name":"data-location"}' title="&projects.removeApp;"></div>
<div class="button-remove" onclick="UI.remove(this.dataset.location)" template='{"type":"attribute","path":"location","name":"data-location"}' title="&projects.removeAppFromList;"></div>
<strong template='{"type":"textContent","path":"name"}'></strong>
<span class="project-item-type" template='{"type":"textContent","path":"type"}'></span>
<p class="project-item-description" template='{"type":"textContent","path":"manifest.description"}'></p>

Просмотреть файл

@ -7,42 +7,64 @@
<!ENTITY index.device2 "Device">
<!ENTITY device.screenshot "Screenshot">
<!ENTITY device.screenshotTooltip "Open a screenshot of the current state of the device in a new tab.">
<!ENTITY device.title "Device Control Center">
<!ENTITY device.notConnected "Not connected. Please connect your device below.">
<!ENTITY device.startApp "Start">
<!ENTITY device.startAppTooltip "Start this app on the device.">
<!ENTITY device.stopApp "Stop">
<!ENTITY device.stopAppTooltip "Stop this app on the device.">
<!ENTITY device.debugApp "Debug">
<!ENTITY device.debugAppTooltip "Open the Developer Tools connected to this app on the device.">
<!ENTITY device.name "Name">
<!ENTITY device.app "App">
<!ENTITY device.privileged "Privileged">
<!ENTITY device.certified "Certified">
<!ENTITY device.allow "Allow">
<!ENTITY device.allowTooltip "This permission is allowed for apps of this type.">
<!ENTITY device.prompt "Prompt">
<!ENTITY device.promptTooltip "This permission requires a user prompt for apps of this type.">
<!ENTITY device.deny "Deny">
<!ENTITY device.denyTooltip "This permission is denied for apps of this type.">
<!ENTITY device.installedApps "Installed Apps">
<!ENTITY device.installedAppsTooltip "View a list of apps installed on the device. Some apps, such as certified apps, may be excluded from this view.">
<!ENTITY device.permissions "Permissions">
<!ENTITY device.permissionsTooltip "View a table of the permissions accessible to the different types of apps.">
<!ENTITY device.permissionsHelpLink "https://developer.mozilla.org/docs/Web/Apps/App_permissions">
<!ENTITY device.help "Help">
<!ENTITY connection.connectTooltip "Connect to the device.">
<!ENTITY connection.disconnect "Disconnect">
<!ENTITY connection.disconnectTooltip "Disconnect from the current device or simulator.">
<!ENTITY connection.showDeviceCtrlCenter "Click for More Details">
<!ENTITY connection.notConnected "Not Connected">
<!ENTITY connection.changeHostAndPort "Change">
<!ENTITY connection.changeHostAndPortTooltip "Change the host and port used to connect to the device. (Defaults to localhost:6000)">
<!ENTITY connection.startSimulator "Start Simulator">
<!ENTITY connection.startSimulatorTooltip "Start an instance of the Simulator and connect to it.">
<!ENTITY connection.saveConnectionInfo "Save">
<!ENTITY connection.saveConnectionInfoTooltip "Save the host and port.">
<!ENTITY connection.connecting "Connecting…">
<!ENTITY connection.disconnecting "Disconnecting…">
<!ENTITY connection.cancel "Cancel">
<!ENTITY connection.cancelConnectTooltip "Cancel the connection in progress.">
<!ENTITY connection.cancelShowSimulatorTooltip "Exit the Simulator connection mode and return to the initial prompt.">
<!ENTITY connection.or "or">
<!ENTITY connection.noSimulatorInstalled "No simulator installed.">
<!ENTITY connection.installFirstSimulator "Install simulator.">
<!ENTITY connection.installOneSimulator "Install Simulator">
<!ENTITY connection.installOneSimulatorTooltip "Install a version of the Simulator by downloading the relevant add-on.">
<!ENTITY connection.installAnotherSimulator "Add">
<!ENTITY connection.installAnotherSimulatorTooltip "Install an additional version of the Simulator by downloading the relevant add-on.">
<!ENTITY projects.localApps "Local Apps">
<!ENTITY projects.addApp "Add">
<!ENTITY projects.addPackaged "Add Packaged App">
<!ENTITY projects.addPackagedTooltip "Add a new packaged app (a directory) from your computer.">
<!ENTITY projects.addHosted "Add Hosted App">
<!ENTITY projects.addHostedTooltip "Add a new hosted app (link to a manifest.webapp file) from a remote website.">
<!ENTITY projects.title "Local Apps">
<!ENTITY projects.appDetails "App Details">
<!ENTITY projects.removeApp "Remove">
<!ENTITY projects.removeAppFromList "Remove this app from the list of apps you are working on. This will not remove it from a device or a simulator.">
<!ENTITY projects.reloadFiles "Refresh">
<!ENTITY projects.installApp "Install">
<!ENTITY projects.startApp "Start">

Просмотреть файл

@ -273,7 +273,10 @@ button {
color: #FFF;
}
.help {
float: right;
padding: 0 5px;
}
/***************** HEADER *****************/