зеркало из https://github.com/mozilla/gecko-dev.git
Adding in pref for snooze time.
This commit is contained in:
Родитель
621ae10832
Коммит
fe48b0bd1d
|
@ -134,6 +134,8 @@ function createAlarmBox( Event )
|
|||
|
||||
OuterBox.getElementsByAttribute( "name", "SnoozeButton" )[0].setAttribute( "onclick", "snoozeAlarm( this.event );removeAlarmBox( this.event );" );
|
||||
|
||||
OuterBox.getElementsByAttribute( "name", "alarm-length-field" )[0].value = opener.gCalendarWindow.calendarPreferences.getPref( "defaultsnoozelength" );
|
||||
|
||||
kungFooDeathGripOnEventBoxes.push( OuterBox.getElementsByAttribute( "name", "SnoozeButton" )[0] );
|
||||
|
||||
/*
|
||||
|
|
|
@ -78,7 +78,7 @@
|
|||
*/
|
||||
|
||||
//the next line needs XX-DATE-XY but last X instead of Y
|
||||
var gDateMade = XX-DATE-XX;
|
||||
var gDateMade = 20020411;
|
||||
|
||||
// turn on debuging
|
||||
|
||||
|
|
|
@ -134,6 +134,8 @@ function createAlarmBox( Event )
|
|||
|
||||
OuterBox.getElementsByAttribute( "name", "SnoozeButton" )[0].setAttribute( "onclick", "snoozeAlarm( this.event );removeAlarmBox( this.event );" );
|
||||
|
||||
OuterBox.getElementsByAttribute( "name", "alarm-length-field" )[0].value = opener.gCalendarWindow.calendarPreferences.getPref( "defaultsnoozelength" );
|
||||
|
||||
kungFooDeathGripOnEventBoxes.push( OuterBox.getElementsByAttribute( "name", "SnoozeButton" )[0] );
|
||||
|
||||
/*
|
||||
|
|
|
@ -53,7 +53,7 @@
|
|||
<script type="application/x-javascript">
|
||||
<![CDATA[
|
||||
var _elementIDs = [
|
||||
"alarmshow", "alarmplaysound", "dateformat", "weekstarts", "defaultlength"
|
||||
"alarmshow", "alarmplaysound", "dateformat", "weekstarts", "defaultlength", "defaultsnoozelength"
|
||||
];
|
||||
]]>
|
||||
</script>
|
||||
|
@ -91,9 +91,16 @@
|
|||
</menupopup>
|
||||
</menulist>
|
||||
</vbox>
|
||||
|
||||
<hbox align="center">
|
||||
<description>Default Event Length: </description>
|
||||
<textbox id="defaultlength" preftype="int" prefstring="calendar.event.defaultlength" value="90" maxlength="3" size="3"/>
|
||||
<textbox id="defaultlength" preftype="int" prefstring="calendar.event.defaultlength" maxlength="3" size="3"/>
|
||||
<label value="Minutes"/>
|
||||
</hbox>
|
||||
|
||||
<hbox align="center">
|
||||
<description>Default Snooze Length: </description>
|
||||
<textbox id="defaultsnoozelength" preftype="int" prefstring="calendar.alarms.defaultsnoozelength" maxlength="3" size="3"/>
|
||||
<label value="Minutes"/>
|
||||
</hbox>
|
||||
</groupbox>
|
||||
|
|
|
@ -70,6 +70,7 @@ function calendarPreferences( CalendarWindow )
|
|||
this.calendarPref.setIntPref( "date.format", 0 );
|
||||
this.calendarPref.setIntPref( "week.start", 0 );
|
||||
this.calendarPref.setIntPref( "event.defaultlength", 60 );
|
||||
this.calendarPref.setIntPref( "alarms.defaultsnoozelength", 10 );
|
||||
this.loadPreferences();
|
||||
}
|
||||
|
||||
|
@ -87,6 +88,8 @@ calendarPreferences.prototype.loadPreferences = function()
|
|||
this.arrayOfPrefs.weekstart = this.calendarPref.getIntPref( "week.start" );
|
||||
|
||||
this.arrayOfPrefs.defaulteventlength = this.calendarPref.getIntPref( "event.defaultlength" );
|
||||
|
||||
this.arrayOfPrefs.defaultsnoozelength = this.calendarPref.getIntPref( "alarms.defaultsnoozelength" );
|
||||
}
|
||||
|
||||
calendarPreferences.prototype.getPref = function( Preference )
|
||||
|
|
Загрузка…
Ссылка в новой задаче