チェンジセット 73 : branches

差分発生行の前後
無視リスト:
更新日時:
2009/08/23 19:55:14 (3 年 前)
更新者:
h
ログメッセージ:

refs #4 #33
全部On/Offボタン追加。常に全配色のオプションを追加。

パス:
branches/release-1.0/chrome/content
ファイル:
2 変更

凡例:

変更なし
追加
削除
  • branches/release-1.0/chrome/content/config.js

    r68 r73  
    55const SPLASH_SCREEN = "splash_screen"; 
    66const SPLASH_VOICE = "splash_voice"; 
     7const USE_ALLPARET = "use_allparet"; 
    78const TOOL_STARTUP = "tool_onstartup"; 
    89 
     
    1415const SPLASH_PROPERTY_SCREEN = "extensions.vocalofx.skin_splash.screen"; 
    1516const SPLASH_PROPERTY_VOICE = "extensions.vocalofx.skin_splash.voice"; 
     17const SKIN_PROPERTY_USE_ALLPARET = "extensions.vocalofx.skin_use_allparet"; 
    1618 
    1719var icons_default =  
     
    6769        tool_onstartup.addEventListener("command", observe, true); 
    6870        tool_onstartup.checked = !prefBrc2.getBoolPref(TOOL_PROPERTY_STARTUP); 
     71 
     72        var use_allparet = document.getElementById(USE_ALLPARET); 
     73        use_allparet.addEventListener("command", observe, true); 
     74        use_allparet.checked = prefBrc2.getBoolPref(SKIN_PROPERTY_USE_ALLPARET); 
    6975} 
    7076 
     
    96102                prefBrc2.setBoolPref(TOOL_PROPERTY_STARTUP, !target.checked); 
    97103        } 
     104        else if(target.id == USE_ALLPARET){ 
     105                prefBrc2.setBoolPref(SKIN_PROPERTY_USE_ALLPARET, target.checked); 
     106        } 
     107} 
     108 
     109function setCheckboxes(clazz, onoff){ 
     110        var checks = document.getElementsByClassName(clazz); 
     111        for(var i = 0; i < checks.length; i++){ 
     112                checks[i].checked = onoff; 
     113                var aSubject = {target:checks[i]}; 
     114                observe(aSubject, null, null); 
     115        } 
    98116} 
    99117 
  • branches/release-1.0/chrome/content/config.xul

    r71 r73  
    2828        <groupbox> 
    2929                <caption label="&vocalofx.config.icons.label;"/> 
     30                <hbox><button label="On" oncommand="setCheckboxes('icons', true);"/><button label="Off" oncommand="setCheckboxes('icons', false);"/></hbox> 
    3031                <checkbox class="icons" id="back-forward-button" label="&vocalofx.config.icons.back-forward-button.label;"/> 
    3132                <checkbox class="icons" id="home-button" label="&vocalofx.config.icons.home-button.label;"/> 
     
    3839        <groupbox> 
    3940                <caption label="&vocalofx.config.addon.label;"/> 
     41                <hbox><button label="On" oncommand="setCheckboxes('addon', true);"/><button label="Off" oncommand="setCheckboxes('addon', false);"/></hbox> 
    4042                <checkbox class="addon" id="{972ce4c6-7e08-4474-a285-3208198ce6fd}" label="&vocalofx.config.addon.defaulttheme.label;"/> 
    4143                <checkbox class="addon" id="personas@christopher.beard" label="&vocalofx.config.addon.personas.label;"/> 
     
    5658                <checkbox id="splash_voice" label="&vocalofx.config.other.splash_voice.label;"/> 
    5759                <checkbox id="tool_onstartup" label="&vocalofx.config.other.tool_onstartup.label;"/> 
    58 <!-- 
    5960                <checkbox id="use_allparet" label="&vocalofx.config.other.use_allparet.label;"/> 
    60 --> 
    6161                <hbox><label id="piapro_gm.label" style="padding-top:0.5em;" value="&vocalofx.config.other.piapro_gm.label;"/><button label="&vocalofx.config.other.piapro_gm.button;" oncommand="openPiaprogmDialog();"/></hbox> 
    6262        </groupbox>