Added preferences dialog. Moved the Protocols menu to the context menu of the toolbar button.

Disabled by default mms:
This commit is contained in:
amla70
2010-08-02 18:40:13 +00:00
parent aad53b3035
commit cded508494
16 changed files with 88 additions and 24 deletions

View File

@@ -14,7 +14,16 @@
<menuitem label="&sendtophoneContextLogout.label;"
accesskey="&sendtophoneContextLogout.accesskey;"
oncommand="sendtophone.logout()" id="sendtophoneContextMenuLogout"/>
<menu label="&sendtophoneProtocols.label;">
<menupopup id="menu_Protocols" onpopupshowing="sendtophone.onOptionsShowing(this)">
<menuitem type="checkbox" id="marketcheck" label="market:" oncommand="sendtophone.onToggleOption(this)" option="market"/>
<menuitem type="checkbox" id="mmscheck" label="mms:" oncommand="sendtophone.onToggleOption(this)" option="mms"/>
<menuitem type="checkbox" id="smscheck" label="sms:" oncommand="sendtophone.onToggleOption(this)" option="sms"/>
<menuitem type="checkbox" id="telcheck" label="tel:" oncommand="sendtophone.onToggleOption(this)" option="tel"/>
</menupopup>
</menu>
</popup>
</popupset>
<popup id="contentAreaContextMenu">
@@ -36,17 +45,6 @@
oncommand="sendtophone.onMenuItemCommand(event, 'page')"/>
</popup>
<menupopup id="menu_ToolsPopup">
<menu label="SendToPhone Protocols" insertafter="devToolsSeparator" >
<menupopup id="menu_Protocols" onpopupshowing="sendtophone.onOptionsShowing(this)">
<menuitem type="checkbox" id="marketcheck" label="market://" oncommand="sendtophone.onToggleOption(this)" option="market"/>
<menuitem type="checkbox" id="smscheck" label="sms://" oncommand="sendtophone.onToggleOption(this)" option="sms"/>
<menuitem type="checkbox" id="mmscheck" label="mms://" oncommand="sendtophone.onToggleOption(this)" option="mms"/>
<menuitem type="checkbox" id="telcheck" label="tel://" oncommand="sendtophone.onToggleOption(this)" option="tel"/>
</menupopup>
</menu>
</menupopup>
<toolbarpalette id="BrowserToolbarPalette">
<toolbarbutton id="sendtophone-toolbar-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
label="&sendtophoneToolbarButton.label;" tooltiptext="&sendtophoneToolbarButton.tooltip;"

View File

@@ -0,0 +1,41 @@
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<!DOCTYPE window SYSTEM "chrome://sendtophone/locale/overlay.dtd">
<prefwindow id="sendtophone-prefs"
title="&sendtophoneOptions.title;"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<prefpane>
<preferences>
<preference id="extensions.sendtophone.protocols.market" name="extensions.sendtophone.protocols.market" type="bool"/>
<preference id="extensions.sendtophone.protocols.sms" name="extensions.sendtophone.protocols.sms" type="bool"/>
<preference id="extensions.sendtophone.protocols.smsto" name="extensions.sendtophone.protocols.smsto" type="bool"/>
<preference id="extensions.sendtophone.protocols.mms" name="extensions.sendtophone.protocols.mms" type="bool"/>
<preference id="extensions.sendtophone.protocols.mmsto" name="extensions.sendtophone.protocols.mmsto" type="bool"/>
<preference id="extensions.sendtophone.protocols.tel" name="extensions.sendtophone.protocols.tel" type="bool"/>
</preferences>
<groupbox style="padding:1em;" label="ProtocolsGroup">
<caption label="&sendtophoneProtocols.label;"/>
<checkbox preference="extensions.sendtophone.protocols.market"
label="market:" />
<checkbox preference="extensions.sendtophone.protocols.mms"
label="mms:" oncommand="var o = document.getElementById('mmsto'); o.checked=this.checked; o.doCommand();" />
<checkbox id="mmsto" preference="extensions.sendtophone.protocols.mmsto"
label="mmsto:" style="display:none" />
<checkbox id="sms" preference="extensions.sendtophone.protocols.sms"
label="sms:" oncommand="var o = document.getElementById('smsto'); o.checked=this.checked; o.doCommand();" />
<checkbox id="smsto" preference="extensions.sendtophone.protocols.smsto"
label="smsto:" style="display:none"/>
<checkbox preference="extensions.sendtophone.protocols.tel"
label="tel:" />
</groupbox>
</prefpane>
</prefwindow>

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Salir">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Opciones de Send to Phone">
<!ENTITY sendtophoneProtocols.label "Protocolos">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Afmelden">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Выйти">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,4 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logga ut">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -10,3 +10,5 @@
<!ENTITY sendtophoneContextPage.accesskey "A">
<!ENTITY sendtophoneContextLogout.label "Logout">
<!ENTITY sendtophoneContextLogout.accesskey "L">
<!ENTITY sendtophoneOptions.title "Send to Phone Preferences">
<!ENTITY sendtophoneProtocols.label "Protocols">

View File

@@ -6,7 +6,7 @@ pref("extensions.sendtophone.proxyUrl", "http://smallroomstudios.net/s2p.php?ml=
pref("extensions.sendtophone.protocols.market", true);
pref("extensions.sendtophone.protocols.sms", true);
pref("extensions.sendtophone.protocols.smsto", true);
pref("extensions.sendtophone.protocols.mms", true);
pref("extensions.sendtophone.protocols.mms", false); // conflicts with http://en.wikipedia.org/wiki/Microsoft_Media_Server
pref("extensions.sendtophone.protocols.mmsto", true);
pref("extensions.sendtophone.protocols.tel", true);

View File

@@ -10,6 +10,8 @@
<em:description>Send links to your Android 2.2 phone using the new C2DM service. Based on the ChromeToPhone extension.</em:description>
<em:aboutURL>chrome://sendtophone/content/about.xul</em:aboutURL>
<em:iconURL>chrome://sendtophone/skin/icon.png</em:iconURL>
<em:optionsURL>chrome://sendtophone/content/options.xul</em:optionsURL>
<em:targetApplication>
<Description>
<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id> <!-- Firefox -->