[Pkg-mozext-commits] [SCM] timeline extension for Icedove with iceowl branch, master, updated. debian/0.4.2-2-3-g2d59aa6

Matthias Schmitz matthias at sigxcpu.org
Fri Apr 19 22:17:11 UTC 2013


The following commit has been merged in the master branch:
commit 3f48e01eb835ac7f01980467cefc6e81ad22bef9
Author: Matthias Schmitz <matthias at sigxcpu.org>
Date:   Fri Apr 19 23:44:34 2013 +0200

    Add patch to fix #705394 (missing checkboxes in context menu)

diff --git a/debian/patches/0003-Set-initial-state-of-context-menu-checkboxes.patch b/debian/patches/0003-Set-initial-state-of-context-menu-checkboxes.patch
new file mode 100644
index 0000000..a4fdd26
--- /dev/null
+++ b/debian/patches/0003-Set-initial-state-of-context-menu-checkboxes.patch
@@ -0,0 +1,60 @@
+From: Matthias Schmitz <matthias at sigxcpu.org>
+Date: Fri, 19 Apr 2013 22:31:01 +0200
+Subject: Set initial state of context menu checkboxes
+
+---
+ chrome/content/timeline.js  |   16 ++++++++++++++++
+ chrome/content/timeline.xul |   11 +++++++----
+ 2 files changed, 23 insertions(+), 4 deletions(-)
+
+diff --git a/chrome/content/timeline.js b/chrome/content/timeline.js
+index 1f408d0..0f62154 100755
+--- a/chrome/content/timeline.js
++++ b/chrome/content/timeline.js
+@@ -365,4 +365,20 @@ calendarTimeline.zoom = function zoom(delta) {
+     this.draw();
+ }
+ 
++// Set initial state of checkboxes
++calendarTimeline.timelineContextInit = function timelineContextInit() {
++
++    function setInitialCheckboxState(type, calendarTimeline) {
++        var menuItem = document.getElementById("timelineContext" + type);
++        if (prefs.getBoolPref("extensions.timeline.show" + type)) {
++            menuItem.setAttribute("checked", true);
++        } else {
++            menuItem.setAttribute("checked", false);
++        }
++   }
++
++    ["Events", "AllDay", "Tasks"].forEach(setInitialCheckboxState);
++    this.draw();
++}
++
+ timer.initWithCallback(callback, 28125, Components.interfaces.nsITimer.TYPE_REPEATING_SLACK);
+diff --git a/chrome/content/timeline.xul b/chrome/content/timeline.xul
+index ca54d6a..cf3224e 100755
+--- a/chrome/content/timeline.xul
++++ b/chrome/content/timeline.xul
+@@ -18,14 +18,17 @@
+         <stack id="eventsDiv"/>
+     </stack>
+         
+-    <menupopup id="timelineContext">
+-        <menuitem   id="timelineContextEvents" 
++    <menupopup id="timelineContext" onpopupshowing="calendarTimeline.timelineContextInit();">
++        <menuitem   type="checkbox"
++                    id="timelineContextEvents"
+                     label="Toggle Events" 
+                     oncommand="calendarTimeline.toggleTimelineContents('Events');"/>
+-        <menuitem   id="timelineContextAllDay"
++        <menuitem   type="checkbox"
++                    id="timelineContextAllDay"
+                     label="Toggle All Day Events" 
+                     oncommand="calendarTimeline.toggleTimelineContents('AllDay');"/>
+-        <menuitem   id="timelineContextTasks"
++        <menuitem   type="checkbox"
++                    id="timelineContextTasks"
+                     label="Toggle Tasks" 
+                     oncommand="calendarTimeline.toggleTimelineContents('Tasks');"/>
+         <menuseparator/>
diff --git a/debian/patches/series b/debian/patches/series
index 8af02e4..6527e69 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
 0001-Add-iceowl-to-install.rdf.patch
 0002-Remove-not-longer-supported-moz-css-tag.patch
+0003-Set-initial-state-of-context-menu-checkboxes.patch

-- 
timeline extension for Icedove with iceowl



More information about the Pkg-mozext-commits mailing list