Home Forums Wiki Doc Install Extras Screenshots Source Code Projects Blog Users Groups Register
Glx-Dock / Cairo-Dock List of forums Applets | Applets Thunderbird Unread Count Add-On broken
The latest stable release is the *3.4.0* : How to install it here.
Note: We just switched from BZR to Git on Github! (only to host the code and your future pull requests)
Applets | Applets

Subjects Author Language Messages Last message
[Locked] Thunderbird Unread Count Add-On broken
Page : 1 2
Guest 25 exscape [Read]
17 December 2014 à 08:41

Guest, Wednesday 09 October 2013 à 22:41

Thunderbird addon:
https://addons.mozilla.org/en-us/thunderbird/addon/cairo-dock-unread-messages/
to me it appears to not be getting the unread messages number from my imap gmail and assuming it is 0
tested on xubuntu 13.10 and 13.04, clean thunderbird profiles
thunderbird version 24
~$ cairo-dock
OpenGL Warning: glFlushVertexArrayRangeNV not found in mesa table
OpenGL Warning: glVertexArrayRangeNV not found in mesa table
OpenGL Warning: glCombinerInputNV not found in mesa table
OpenGL Warning: glCombinerOutputNV not found in mesa table
OpenGL Warning: glCombinerParameterfNV not found in mesa table
OpenGL Warning: glCombinerParameterfvNV not found in mesa table
OpenGL Warning: glCombinerParameteriNV not found in mesa table
OpenGL Warning: glCombinerParameterivNV not found in mesa table
OpenGL Warning: glFinalCombinerInputNV not found in mesa table
OpenGL Warning: glGetCombinerInputParameterfvNV not found in mesa table
OpenGL Warning: glGetCombinerInputParameterivNV not found in mesa table
OpenGL Warning: glGetCombinerOutputParameterfvNV not found in mesa table
OpenGL Warning: glGetCombinerOutputParameterivNV not found in mesa table
OpenGL Warning: glGetFinalCombinerInputParameterfvNV not found in mesa table
OpenGL Warning: glGetFinalCombinerInputParameterivNV not found in mesa table
OpenGL Warning: glDeleteFencesNV not found in mesa table
OpenGL Warning: glFinishFenceNV not found in mesa table
OpenGL Warning: glGenFencesNV not found in mesa table
OpenGL Warning: glGetFenceivNV not found in mesa table
OpenGL Warning: glIsFenceNV not found in mesa table
OpenGL Warning: glSetFenceNV not found in mesa table
OpenGL Warning: glTestFenceNV not found in mesa table
warning : (/build/buildd/cairo-dock-3.3.1/src/implementations/cairo-dock-glx.c:_initialize_opengl_backend:179)
couldn't find an appropriate visual, trying to get one without Stencil buffer
(it may cause some little deterioration in the rendering) ...

============================================================================
    Cairo-Dock version : 3.3.1
    Compiled date : Oct 8 2013 17:00:11
    Built with GTK : 3.8
    Running with OpenGL: 0
============================================================================

Theme parsing error: gtk-widgets.css:2597:41: Expected a valid selector
Launcher-API-Daemon: registered as Unity: <dbus.service.BusName com.canonical.Unity on <dbus._dbus.SessionBus (session) at 0xc342f0> at 0xc1c690>
connect...
-> connected to cairo-dock
('new owner:', dbus.UTF8String(':1.77'))
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count'): dbus.Int64(0L, variant_level=1), dbus.String(u'urgent'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress'): dbus.Double(0.0, variant_level=1)}, signature=dbus.Signature('sv'))
Launcher-API-Daemon: set_count (0)
Launcher-API-Daemon: set_progress (0.00)
Launcher-API-Daemon: set_urgent (0)
Launcher-API-Daemon: set_count_visible (0)
Launcher-API-Daemon: set_progress_visible (0)
Launcher-API-Daemon: launcher bus name changed: :1.63
Launcher-API-Daemon: launcher bus name changed:
Launcher-API-Daemon: -> the launcher :1.63 is no longer connected to its app.

(process:2093): GLib-CRITICAL **: g_slice_set_config: assertion 'sys_page_size == 0' failed
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count'): dbus.Int64(0L, variant_level=1), dbus.String(u'urgent'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress'): dbus.Double(0.0, variant_level=1)}, signature=dbus.Signature('sv'))
Launcher-API-Daemon: set_count (0)
Launcher-API-Daemon: set_progress (0.00)
Launcher-API-Daemon: set_urgent (0)
Launcher-API-Daemon: set_count_visible (0)
Launcher-API-Daemon: set_progress_visible (0)
Launcher-API-Daemon: launcher bus name changed: :1.84
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1)}, signature=dbus.Signature('sv'))
Launcher-API-Daemon: set_count_visible (0)
connect...
-> connected to cairo-dock
connect...
-> connected to cairo-dock
connect...
-> connected to cairo-dock
connect...
-> connected to cairo-dock
Launcher-API-Daemon: launcher bus name changed:
Launcher-API-Daemon: -> the launcher :1.84 is no longer connected to its app.

(process:2177): GLib-CRITICAL **: g_slice_set_config: assertion 'sys_page_size == 0' failed
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count'): dbus.Int64(0L, variant_level=1), dbus.String(u'urgent'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1), dbus.String(u'progress'): dbus.Double(0.0, variant_level=1)}, signature=dbus.Signature('sv'))
Launcher-API-Daemon: set_count (0)
Launcher-API-Daemon: set_progress (0.00)
Launcher-API-Daemon: set_urgent (0)
Launcher-API-Daemon: set_count_visible (0)
Launcher-API-Daemon: set_progress_visible (0)
Launcher-API-Daemon: launcher bus name changed: :1.91
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1)}, signature=dbus.Signature('sv'))
Launcher-API-Daemon: set_count_visible (0)

fabounet, Thursday 10 October 2013 à 16:13


Subscription date : 30 November 2007
Messages : 17118
did you try to use your gmail account with POP3 in Thunderbird ?

Guest, Friday 11 October 2013 à 19:14

no, but it was working a couple weeks ago
i was having the issue only on my laptop not on my desktop till the other day when i rebooted my desktop for the 1st time in 14-17 days

fabounet, Friday 11 October 2013 à 19:38


Subscription date : 30 November 2007
Messages : 17118
it seems that Thunderbird is trying to set a progressbar to 0, using the Unity-launcher API
set_progress (0.00)
set_count (0)


this overwrites the quick-info that is written from our plug-in

maybe another plug-in in Thunderbird is active (probably made by the Unity guys)
I think you should disable one of the 2.

Guest, Friday 11 October 2013 à 21:10

no effect
have those disabled on 13.04 as i don't use unity i use xfce

fabounet, Monday 14 October 2013 à 18:16


Subscription date : 30 November 2007
Messages : 17118
I think the plug-in is in Thunderbird
even if you don't use Unity, Cairo-Dock can use the information that Thunderbird sends to Unity (Unity doesn't need to be running)

Guest, Monday 14 October 2013 à 20:33

it is not working regardless of what addons are enabled in Thunderbird
maybe this will be helpful
http://www.zimagez.com/miniature/screenshot-10142013-023153pm.php

fabounet, Tuesday 15 October 2013 à 17:04


Subscription date : 30 November 2007
Messages : 17118
hmm, I don't know if this warning is a serious one

but still, we have this message:
Launcher-API-Daemon: Update application://thunderbird.desktop with dbus.Dictionary({dbus.String(u'count-visible'): dbus.Boolean(False, variant_level=1)}, signature=dbus.Signature('sv'))

which does mean that someone is hiding the count on Thunderbird
so if it's not a Thunderbird's plug-in, maybe it's another process (or maybe it's hard-coded in this version of Thunderbird)

I suggest to try killing the process cairo-dock-launcher-API-daemon.py, so that the dock ignores these commands, and then restart Thunderbird, and see if it works better

Guest, Thursday 17 October 2013 à 23:08

eigher i did that wrong or it had no effect
i have verified that it is setting the value to the dock as "", i changed the "" to "0" for the value when the count is 0 and that worked
where does the dump function send the messages to? it is not the console or the error console, unless the JS is not executing

Guest, Thursday 17 October 2013 à 23:20

figured out the dump function, had to set browser.dom.window.dump.enabled to true, now maybe i can debug this

Guest, Thursday 17 October 2013 à 23:33

ok the issue is the account object is not what i used to be
accounts.Count()
throws a error
also
TypeError: accounts.QueryElementAt is not a function

i bypassed the 1st error using this:
var ct=0;
for(var i in accounts) ct++;

then replaced accounts.Count() with ct

Guest, Thursday 17 October 2013 à 23:53

ok i got a patch:
--- Desktop/cairounread_OLD.js    2013-02-19 17:06:08.000000000 -0500
+++ .thunderbird/ugjumrdx.default/extensions/cairo-dock-unread-messages@glxdock.org/chrome/content/cairounread.js    2013-10-17 17:51:45.508855607 -0400
@@ -103,16 +103,18 @@
    
    performUnreadCount: function(that) {
        dump("Counting unread messages...\n");
-        var acctMgr = Components.classes["@mozilla.org/messenger/account-manager;1"].getService(Components.interfaces.nsIMsgAccountManager);
-        var accounts = acctMgr.accounts;
-        var totalCount = 0;
-        dump("Found " + accounts.Count() + " accounts\n");
-        for (var i = 0; i < accounts.Count(); i++) {
-            var account = accounts.QueryElementAt(i, Components.interfaces.nsIMsgAccount);
-            var rootFolder = account.incomingServer.rootFolder; // nsIMsgFolder
-                if (rootFolder.hasSubFolders) {
-                    totalCount += that.getTotalCount(rootFolder);
-                }
+        var acctMgr = Components.classes["@mozilla.org/messenger/account-manager;1"].getService(Components.interfaces.nsIMsgAccountManager),
+            accounts = acctMgr.accounts,
+            totalCount = 0,
+            count = 0 ;
+        for(var i in accounts) count++;
+        dump("Found " + ct + " accounts\n");
+        for (var i = 0; i < count; i++) {
+            var account = accounts.queryElementAt(i, Components.interfaces.nsIMsgAccount),
+                rootFolder = account.incomingServer.rootFolder; // nsIMsgFolder
+            if (rootFolder.hasSubFolders) {
+                totalCount += that.getTotalCount(rootFolder);
+            }
        }
        dump("Found total : " + totalCount + "\n");
        that.updateUnreadCount(totalCount, false);
@@ -210,7 +212,6 @@
    notifyFlags: '',
    timeoutId: -1
};
-
window.addEventListener("load", function(e) { cairounread.onLoad(e); }, false);
window.addEventListener("close", function(e) { cairounread.onClose(e); }, false);
window.addEventListener("unload", function(e) { cairounread.onClose(e); }, false);

Guest, Thursday 17 October 2013 à 23:57

made a typo, fixed it below
--- Desktop/cairounread_OLD.js    2013-02-19 17:06:08.000000000 -0500
+++ .thunderbird/ugjumrdx.default/extensions/cairo-dock-unread-messages@glxdock.org/chrome/content/cairounread.js    2013-10-17 17:51:45.508855607 -0400
@@ -103,16 +103,18 @@
    
    performUnreadCount: function(that) {
        dump("Counting unread messages...\n");
-        var acctMgr = Components.classes["@mozilla.org/messenger/account-manager;1"].getService(Components.interfaces.nsIMsgAccountManager);
-        var accounts = acctMgr.accounts;
-        var totalCount = 0;
-        dump("Found " + accounts.Count() + " accounts\n");
-        for (var i = 0; i < accounts.Count(); i++) {
-            var account = accounts.QueryElementAt(i, Components.interfaces.nsIMsgAccount);
-            var rootFolder = account.incomingServer.rootFolder; // nsIMsgFolder
-                if (rootFolder.hasSubFolders) {
-                    totalCount += that.getTotalCount(rootFolder);
-                }
+        var acctMgr = Components.classes["@mozilla.org/messenger/account-manager;1"].getService(Components.interfaces.nsIMsgAccountManager),
+            accounts = acctMgr.accounts,
+            totalCount = 0,
+            count = 0 ;
+        for(var i in accounts) count++;
+        dump("Found " + count + " accounts\n");
+        for (var i = 0; i < count; i++) {
+            var account = accounts.queryElementAt(i, Components.interfaces.nsIMsgAccount),
+                rootFolder = account.incomingServer.rootFolder; // nsIMsgFolder
+            if (rootFolder.hasSubFolders) {
+                totalCount += that.getTotalCount(rootFolder);
+            }
        }
        dump("Found total : " + totalCount + "\n");
        that.updateUnreadCount(totalCount, false);
@@ -210,7 +212,6 @@
    notifyFlags: '',
    timeoutId: -1
};
-
window.addEventListener("load", function(e) { cairounread.onLoad(e); }, false);
window.addEventListener("close", function(e) { cairounread.onClose(e); }, false);
window.addEventListener("unload", function(e) { cairounread.onClose(e); }, false);

Guest, Friday 18 October 2013 à 01:15

here is a updated XPI file
http://www.filedropper.com/cairodockunreadmessages-106-tb-linux
upped version # to 1.0.6 and set the min version to 24 and the max to 50

fabounet, Friday 18 October 2013 à 16:40


Subscription date : 30 November 2007
Messages : 17118
thanks you very much for this patch
do you mean that from Thunderbird 24, accounts.Count() doesn't work any more ?

Guest, Friday 18 October 2013 à 17:12

.Count and .QueryElementAt are what broke the addon
if you change .Count() to .length and .QueryElementAt to .queryElementAt that should be the minimal change to make it work

in the last patch replace this:
+ count = 0 ;
+ for(var i in accounts) count++;

with this
+ count = accounts.length ;

Guest, Friday 18 October 2013 à 17:16

also you can change this:
        if (that.lastCount < totalCount){
            that.updateUnreadAnimate(true);
        }
        else{
            that.updateUnreadAnimate(false);
        }

to a single line like this:
that.updateUnreadAnimate(that.lastCount < totalCount);

fabounet, Monday 21 October 2013 à 17:07


Subscription date : 30 November 2007
Messages : 17118
thank you for the details
I'll try to update the addon asap

Guest, Tuesday 29 October 2013 à 05:24

At following link file is missing.

Could anybody publish the new version at oficial Thunderbird plugins repository?

fabounet, Tuesday 29 October 2013 à 10:50


Subscription date : 30 November 2007
Messages : 17118
sorry, didn't have time yet (we were busy preparing the version 3.3.2)
but I didn't forget

Applets | Applets

Subjects Author Language Messages Last message
[Locked] Thunderbird Unread Count Add-On broken
Page : 1 2
Guest 25 exscape [Read]
17 December 2014 à 08:41


Glx-Dock / Cairo-Dock List of forums Applets | Applets Thunderbird Unread Count Add-On broken Top

Online users :

Powered by ElementSpeak © 2007 Adrien Pilleboue, 2009-2013 Matthieu Baerts.
Dock based on CSS Dock Menu (Ndesign) with jQuery. Icons by zgegball
Cairo-Dock is a free software under GNU-GPL3 licence. First stable version created by Fabounet.
Many thanks to TuxFamily for the web Hosting and Mav for the domain name.