diff -ruN etc/defaults/openwebmail.conf etc/defaults/openwebmail.conf
--- etc/defaults/openwebmail.conf	Wed Mar 16 21:38:59 2005
+++ etc/defaults/openwebmail.conf	Thu Mar 17 09:08:09 2005
@@ -334,6 +334,7 @@
 default_categorizedfolders_fs	-
 default_refreshinterval		20
 min_refreshinterval		3
+default_unreadmsgintitlebar	yes
 default_newmailsound		YouGotMail.English.wav
 default_newmailwindowtime	7
 default_mailsentwindowtime	5
diff -ruN etc/openwebmail.conf.help etc/openwebmail.conf.help
--- etc/openwebmail.conf.help	Wed Mar  9 10:33:56 2005
+++ etc/openwebmail.conf.help	Thu Mar 17 09:10:03 2005
@@ -2054,6 +2054,15 @@
 small refreshinterval setting
 
 
+default_unreadmsgintitlebar
+-----------------------------------------------------------------------
+If this option is enabled, the number of unread messages will show in the
+titlebar of the browser. This allows users to check to see if they have
+unread messages without maximizing their browser window. Currently, the
+titlebar will only be changed for unread messages in the inbox only.
+This is intended as a silent new message notification.
+
+
 default_newmailsound
 -----------------------------------------------------------------------
 this is the sound file played if new mail is found.
diff -ruN etc/templates/ar.CP1256/prefs.template etc/templates/ar.CP1256/prefs.template
--- etc/templates/ar.CP1256/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ar.CP1256/prefs.template	Thu Mar 17 09:14:19 2005
@@ -528,6 +528,11 @@
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( ÇáÝÇÕá Èíä ÇáÕäÝ æ ÇáãÌáÏ @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
 <tr><td align="left" bgcolor=@@@WINDOW_DARK@@@>
 <B>ÕæÊ ÇáÅÎØÇÑ ááÈÑíÏ ÇáÌÏíÏ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
diff -ruN etc/templates/ar.ISO8859-6/prefs.template etc/templates/ar.ISO8859-6/prefs.template
--- etc/templates/ar.ISO8859-6/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ar.ISO8859-6/prefs.template	Thu Mar 17 09:14:19 2005
@@ -528,6 +528,11 @@
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( ÇäáÇÕä Èêæ ÇäÕæá è ÇäåÌäÏ @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
 <tr><td align="left" bgcolor=@@@WINDOW_DARK@@@>
 <B>ÕèÊ ÇäÅÎ×ÇÑ ääÈÑêÏ ÇäÌÏêÏ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
diff -ruN etc/templates/bg/prefs.template etc/templates/bg/prefs.template
--- etc/templates/bg/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/bg/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Ðàçäåëèòåë íà êàòåãîðèÿòà ïàïêà @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Ñèãíàë ïðè íîâî ñúîáùåíèå:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ca/prefs.template etc/templates/ca/prefs.template
--- etc/templates/ca/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ca/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Separador de carpetes per categories @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notificació sonora de missatges nous:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/cs/prefs.template etc/templates/cs/prefs.template
--- etc/templates/cs/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/cs/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;(Oddìlovaè kategorií slo¾ek: @@@CATEGORIZEDFOLDERS_FS@@@)
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Zvukové upozornìní na novou po¹tu:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/da/prefs.template etc/templates/da/prefs.template
--- etc/templates/da/prefs.template	Thu Mar 10 15:25:41 2005
+++ etc/templates/da/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Adskillelse af kategorimapper @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Afspil f&oslash;lgende lyd n&aring;r der kommer en ny besked:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/de/prefs.template etc/templates/de/prefs.template
--- etc/templates/de/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/de/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Trennzeichen f&uuml;r Kategorie-Ordner @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Akkustische Benachrichtigung:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/el/prefs.template etc/templates/el/prefs.template
--- etc/templates/el/prefs.template	Mon Mar  7 23:12:32 2005
+++ etc/templates/el/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>NewMail sound notification:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/en/prefs.template etc/templates/en/prefs.template
--- etc/templates/en/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/en/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>NewMail sound notification:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/en.utf8/prefs.template etc/templates/en.utf8/prefs.template
--- etc/templates/en.utf8/prefs.template	Tue Mar  8 01:47:49 2005
+++ etc/templates/en.utf8/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>NewMail sound notification:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/es/prefs.template etc/templates/es/prefs.template
--- etc/templates/es/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/es/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;(Separador de categorías @@@CATEGORIZEDFOLDERS_FS@@@)
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notificación sonora de nuevos mensajes:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/fi/prefs.template etc/templates/fi/prefs.template
--- etc/templates/fi/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/fi/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Ilmoitus saapuneesta postista äänellä:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/fr/prefs.template etc/templates/fr/prefs.template
--- etc/templates/fr/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/fr/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Séparateur de Catégorie @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notification sonore de nouveau(x) message(s) :</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/he.CP1255/prefs.template etc/templates/he.CP1255/prefs.template
--- etc/templates/he.CP1255/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/he.CP1255/prefs.template	Thu Mar 17 09:14:19 2005
@@ -528,6 +528,11 @@
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
 <tr><td align="left" bgcolor=@@@WINDOW_DARK@@@>
 <B>öìéì äåãòú ãåàø:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
diff -ruN etc/templates/he.ISO8859-8/prefs.template etc/templates/he.ISO8859-8/prefs.template
--- etc/templates/he.ISO8859-8/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/he.ISO8859-8/prefs.template	Thu Mar 17 09:14:19 2005
@@ -528,6 +528,11 @@
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
 <tr><td align="left" bgcolor=@@@WINDOW_DARK@@@>
 <B>øàåã úòãåä ìéìö:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
diff -ruN etc/templates/hr/prefs.template etc/templates/hr/prefs.template
--- etc/templates/hr/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/hr/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Zvuk za obavje¹tavanje novopristigle po¹te:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/hu/prefs.template etc/templates/hu/prefs.template
--- etc/templates/hu/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/hu/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Hangjelzés új levél esetén:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/id/prefs.template etc/templates/id/prefs.template
--- etc/templates/id/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/id/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Pemisah kategori folder @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Suara untuk Pemberitahuan Email Baru: </B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/it/prefs.template etc/templates/it/prefs.template
--- etc/templates/it/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/it/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notifica sonora nuovo mail:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ja_JP.Shift_JIS/prefs.template etc/templates/ja_JP.Shift_JIS/prefs.template
--- etc/templates/ja_JP.Shift_JIS/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/ja_JP.Shift_JIS/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>�V’…ƒ��[ƒ‹‚¨’m‚ç‚¹ƒTƒEƒ“ƒh:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ja_JP.eucJP/prefs.template etc/templates/ja_JP.eucJP/prefs.template
--- etc/templates/ja_JP.eucJP/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ja_JP.eucJP/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>¿·Ãå¥á¡¼¥ë¤ªÃÎ¤é¤»¥µ¥¦¥ó¥É:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ja_JP.utf8/prefs.template etc/templates/ja_JP.utf8/prefs.template
--- etc/templates/ja_JP.utf8/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/ja_JP.utf8/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>æ–°ç�€ãƒ¡ãƒ¼ãƒ«ã�ŠçŸ¥ã‚‰ã�›ã‚µã‚¦ãƒ³ãƒ‰:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ko/prefs.template etc/templates/ko/prefs.template
--- etc/templates/ko/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ko/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>»õ·Î¿Â ¸ÞÀÏ ¾Ë¸² »ç¿îµå:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/lt/prefs.template etc/templates/lt/prefs.template
--- etc/templates/lt/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/lt/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Naujo laiðko gavimo ágarsinimas:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/nl/prefs.template etc/templates/nl/prefs.template
--- etc/templates/nl/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/nl/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Geluid bij nieuw ontvangen bericht:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/no/prefs.template etc/templates/no/prefs.template
--- etc/templates/no/prefs.template	Mon Mar  7 23:12:38 2005
+++ etc/templates/no/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Varsellyd for innkommende melding:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/pl/prefs.template etc/templates/pl/prefs.template
--- etc/templates/pl/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/pl/prefs.template	Thu Mar 17 09:14:19 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;(separator kategorii @@@CATEGORIZEDFOLDERS_FS@@@)
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Powiadomianie d¼wiêkowe o nowej poczcie:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/pt/prefs.template etc/templates/pt/prefs.template
--- etc/templates/pt/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/pt/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Som para notificação de novo correio:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/pt_BR/prefs.template etc/templates/pt_BR/prefs.template
--- etc/templates/pt_BR/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/pt_BR/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Separador Categoria-Pasta @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Som para notificação de nova mensagem:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ro/prefs.template etc/templates/ro/prefs.template
--- etc/templates/ro/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ro/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Separator categorii @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notificare sonora la mesaje noi:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ro.utf8/prefs.template etc/templates/ro.utf8/prefs.template
--- etc/templates/ro.utf8/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ro.utf8/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Separator categorii @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Notificare sonorÄƒ la mesaje noi:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ru/prefs.template etc/templates/ru/prefs.template
--- etc/templates/ru/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ru/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>ú×ÕËÏ×ÏÅ ÏÐÏ×ÅÝÅÎÉÅ Ï ÎÏ×ÏÍ ÐÉÓØÍÅ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/sk/prefs.template etc/templates/sk/prefs.template
--- etc/templates/sk/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/sk/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Upozornenie na novú správu zvukom:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/sl/prefs.template etc/templates/sl/prefs.template
--- etc/templates/sl/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/sl/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Loèilni znak med kategorijami map @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Zvok za obvešèanje o novoprispelem sporoèilu:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/sr/prefs.template etc/templates/sr/prefs.template
--- etc/templates/sr/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/sr/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Zvuk za obave¹tavanje novopristigle po¹te:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/sv/prefs.template etc/templates/sv/prefs.template
--- etc/templates/sv/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/sv/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>Ljudmeddelande vid ny post:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/th/prefs.template etc/templates/th/prefs.template
--- etc/templates/th/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/th/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>àÊÕÂ§àµ×Í¹àÁ×èÍÁÕ¨´ËÁÒÂãËÁè:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/tr/prefs.template etc/templates/tr/prefs.template
--- etc/templates/tr/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/tr/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>YeniÝleti Sesli Bildirim:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/uk/prefs.template etc/templates/uk/prefs.template
--- etc/templates/uk/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/uk/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>ðÏ×¦ÄÏÍÌÑÔÉ Ú×ÕËÏÍ ÐÒÏ ÎÏ×Õ ÐÏÛÔÕ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/ur/prefs.template etc/templates/ur/prefs.template
--- etc/templates/ur/prefs.template	Mon Mar  7 23:12:37 2005
+++ etc/templates/ur/prefs.template	Thu Mar 17 09:14:20 2005
@@ -528,6 +528,11 @@
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Category-Folder Separator @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
 <tr><td align="left" bgcolor=@@@WINDOW_DARK@@@>
 <B>ï»§ï®± ï­˜ï»´ï»�ïºŽï»¡ ï»›ï»° ïº�ï®”ïºŽï®¨ï»° ï»›ï»° ïº�ï»­ïº�ïº¯ :</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
diff -ruN etc/templates/zh_CN.GB2312/prefs.template etc/templates/zh_CN.GB2312/prefs.template
--- etc/templates/zh_CN.GB2312/prefs.template	Mon Mar  7 23:14:07 2005
+++ etc/templates/zh_CN.GB2312/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Àà±ð·Ö¸ô×Ö´® @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>ÐÂÓÊ¼þÍ¨ÖªÒôÐ§:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/zh_CN.GB2312.utf8/prefs.template etc/templates/zh_CN.GB2312.utf8/prefs.template
--- etc/templates/zh_CN.GB2312.utf8/prefs.template	Tue Mar  8 01:47:02 2005
+++ etc/templates/zh_CN.GB2312.utf8/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( ç±»åˆ«åˆ†éš”å­—ä¸² @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>æ–°é‚®ä»¶é€šçŸ¥éŸ³æ•ˆ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/zh_TW.Big5/prefs.template etc/templates/zh_TW.Big5/prefs.template
--- etc/templates/zh_TW.Big5/prefs.template	Mon Mar  7 23:13:48 2005
+++ etc/templates/zh_TW.Big5/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( Ãþ§O¤À¹j¦r¦ê @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>·s«H³qª¾­µ®Ä:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN etc/templates/zh_TW.Big5.utf8/prefs.template etc/templates/zh_TW.Big5.utf8/prefs.template
--- etc/templates/zh_TW.Big5.utf8/prefs.template	Tue Mar  8 01:46:52 2005
+++ etc/templates/zh_TW.Big5.utf8/prefs.template	Thu Mar 17 09:14:20 2005
@@ -529,6 +529,11 @@
 @@@CATEGORIZEDFOLDERS@@@ &nbsp;( é¡žåˆ¥åˆ†éš”å­—ä¸² @@@CATEGORIZEDFOLDERS_FS@@@ )
 </td></tr>
 <tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
+<B>Show inbox unread count in titlebar:</B>
+</td><td bgcolor=@@@WINDOW_DARK@@@>
+@@@UNREADMSGINTITLEBAR@@@
+</td></tr>
+<tr><td align="right" bgcolor=@@@WINDOW_DARK@@@>
 <B>æ–°ä¿¡é€šçŸ¥éŸ³æ•ˆ:</B>
 </td><td bgcolor=@@@WINDOW_DARK@@@>
 @@@NEWMAILSOUNDMENU@@@
diff -ruN openwebmail-main.pl openwebmail-main.pl
--- openwebmail-main.pl	Wed Mar 16 22:27:01 2005
+++ openwebmail-main.pl	Thu Mar 17 09:07:30 2005
@@ -1002,9 +1002,16 @@
                     qq|//-->\n</script>\n|;
       }
    }
-
    $html.=readtemplate('showmsg.js').$temphtml if ($temphtml);
 
+   # show unread inbox messages count in titlebar
+   my $unread_messages_msg;
+   if ($prefs{'unreadmsgintitlebar'}) {
+      if ($now_inbox_newmessages>0) {
+         $unread_messages_msg = "$lang_folders{INBOX}: $now_inbox_newmessages $lang_text{'messages'} $lang_text{'unread'}";
+      }
+   }
+
    # since $headershtml may be large, we put it into $html as late as possible
    $html =~ s/\@\@\@HEADERS\@\@\@/$headershtml/; undef($headershtml);
 
@@ -1015,12 +1022,13 @@
    $relative_url=~s!/.*/!!g;
 
    httpprint([-Refresh=>"$refreshinterval;URL=$relative_url?sessionid=$thissession&sort=$sort&keyword=$escapedkeyword&searchtype=$searchtype&folder=INBOX&action=listmessages&page=1&session_noupdate=1"],
-             [htmlheader(),
+             [htmlheader($unread_messages_msg),
               htmlplugin($config{'header_pluginfile'}, $config{'header_pluginfile_charset'}, $prefs{'charset'}),
               $html,
               htmlplugin($config{'footer_pluginfile'}, $config{'footer_pluginfile_charset'}, $prefs{'charset'}),
               htmlfooter(2)] );
 }
+
 
 # reminder for events within 7 days
 sub eventreminder_html {
diff -ruN openwebmail-prefs.pl openwebmail-prefs.pl
--- openwebmail-prefs.pl	Wed Mar 16 22:27:01 2005
+++ openwebmail-prefs.pl	Thu Mar 17 09:17:53 2005
@@ -1521,6 +1521,14 @@
                                defined($config_raw{'DEFAULT_categorizedfolders_fs'})?('-disabled'=>'1'):());
          $html =~ s/\@\@\@CATEGORIZEDFOLDERS_FS\@\@\@/$temphtml/;
 
+         $temphtml = checkbox(-name=>'unreadmsgintitlebar',
+                              -value=>'1',
+                              -checked=>$prefs{'unreadmsgintitlebar'},
+                              -label=>'',
+                              -override=>'1',
+                              defined($config_raw{'DEFAULT_unreadmsgintitlebar'})?('-disabled'=>'1'):());
+         $html =~ s/\@\@\@UNREADMSGINTITLEBAR\@\@\@/$temphtml/;
+
          # Get a list of new mail sound
          my @sounds;
          opendir(SOUNDDIR, "$config{'ow_htmldir'}/sounds") or
diff -ruN shares/ow-shared.pl shares/ow-shared.pl
--- shares/ow-shared.pl	Tue Mar  8 01:20:19 2005
+++ shares/ow-shared.pl	Thu Mar 17 09:10:37 2005
@@ -66,6 +66,7 @@
    default_calendar_showemptyhours default_calendar_reminderforglobal
    default_webdisk_confirmmovecopy default_webdisk_confirmdel default_webdisk_confirmcompress
    default_uselightbar default_regexmatch default_hideinternal default_categorizedfolders
+   default_unreadmsgintitlebar
 )) { $is_config_option{'yesno'}{$_}=1}
 
 # none type config options
@@ -154,7 +155,7 @@
    webdisk_dirnumitems webdisk_confirmmovecopy webdisk_confirmdel
    webdisk_confirmcompress webdisk_fileeditcolumns  webdisk_fileeditrows
    fscharset uselightbar regexmatch hideinternal
-   categorizedfolders categorizedfolders_fs
+   categorizedfolders categorizedfolders_fs unreadmsgintitlebar
    refreshinterval newmailsound newmailwindowtime mailsentwindowtime
    dictionary trashreserveddays spamvirusreserveddays sessiontimeout
 );
@@ -1191,6 +1192,8 @@
 }
 
 sub htmlheader {
+   my $extra_info = $_[0]; # any message in titlebar
+
    my $html = applystyle(readtemplate("header.template"));
    $html =~ s/\@\@\@DIRECTIVE\@\@\@/$_[0]/g;	# $_[0] is optional html directive
 
@@ -1204,9 +1207,9 @@
    $html =~ s/\@\@\@BG_URL\@\@\@/$prefs{'bgurl'}/g;
    $html =~ s/\@\@\@CHARSET\@\@\@/$prefs{'charset'}/g;
 
-   my $info;
+   my $info = $extra_info?"$extra_info - ":"";
    if ($user ne '') {
-      $info=qq|$prefs{'email'} -|;
+      $info.=qq|$prefs{'email'} -|;
       if ($config{'quota_module'} ne "none") {
          $info.=qq| |.lenstr($quotausage*1024,1);
          $info.=qq| (|.(int($quotausage*1000/$quotalimit)/10).qq|%)| if ($quotalimit);
