mkiol / GNotifier

Thunderbird add-on that replaces built-in notifications with the OS native notifications
https://addons.mozilla.org/thunderbird/addon/gnotifier/
GNU General Public License v3.0
164 stars 25 forks source link

Thunderbird support in Windows 8+ #55

Closed kabili207 closed 9 years ago

kabili207 commented 9 years ago

The Windows 8 helper DLLs were incorrectly reading the firefox registry entry in order to determine the app ID windows needs to display notifications. I've modified this to get the ID using the standard windows APIs instead.

I have run into a problem, however. In thunderbird.js the title and text are being html encoded (I assume because libnotify doesn't like it otherwise), but windows doesn't like this. I tried to add a check if the system platform is winnt, however seems to halt execution of anything after var system = require('sdk/system');. Do you have any idea why thunderbird fails whenever I try to add a require for the system object? Since neither OSX nor Windows need the title/text to be html encoded, why don't we just do the encoding in linux.js?

screenshot 2

Issue #9

mkiol commented 9 years ago

Great job. It works super well!

why don't we just do the encoding in linux.js?

I did just as you suggested (4deb67bfe133d3761fca2252977dc12bb37b2119). From now on, HTML markups escaping is done in linux.js. It requires some tuning because libnotify allows some markups. I'll take care of this later on.