Closed Bug 36025 Opened 24 years ago Closed 24 years ago

Need to support play sound when message arrives preference

Categories

(SeaMonkey :: MailNews: Message Display, defect, P1)

x86
Windows NT
defect

Tracking

(Not tracked)

VERIFIED FIXED
mozilla0.8

People

(Reporter: scottputterman, Assigned: sspitzer)

References

(Blocks 1 open bug)

Details

(Whiteboard: [nsbeta1+])

Attachments

(3 files)

We need to have the ability to play a sound when biff goes off.
Blocks: biff
QA Contact: lchiang → fenella
Status: NEW → ASSIGNED
marking future.
Target Milestone: --- → Future
nominating for beta3 and marking it P1. This is very similar to biff 
notification in status bar. And should be doable in nsbeta3 framework.
Keywords: correctness, nsbeta3
Priority: P3 → P1
Sorry this comment was for the wrong bug. Though this bug I would also nominate 
for beta3, as it needs to be in place to make enabling sound notification work.

This is related to bug 36751.
*** Bug 36751 has been marked as a duplicate of this bug. ***
Removing nsbeta3 keyword and making this nsbeta3-. Realized 36751 was a feature 
that did not make it into nsbeta2 and that is a dup of this bug.
Keywords: correctness, nsbeta3
nominating for mail3
Keywords: mail3
marking nsbeta1+ and reassigning to racham.
Assignee: gayatrib → racham
Status: ASSIGNED → NEW
Keywords: nsbeta1
Whiteboard: [nsbeta1+]
moving to mozilla0.8 milestone.
Target Milestone: Future → mozilla0.8
*** Bug 58682 has been marked as a duplicate of this bug. ***
Status: NEW → ASSIGNED
this would be a very useful feature, since most people will have their mail app
behind the prog their actually working in, or it will be minimized. A sound
would be an excellent que the mail has arrived.

This would be in parallel to having a windows taskbar icon (next to clock) that
would give visual and audio alert of new mail (bug#?). Thank You.
> This would be in parallel to having a windows taskbar icon (next to clock) 
> that would give visual and audio alert of new mail (bug#?). 

If I understand you, that is what we refer to as NSNotify. #11056

adding ryan to the cc list.  he's going to take a crack at this.


I think that's 
taking from racham.  ryan is working on the front end, and he and I already have
the back end working.
Assignee: racham → sspitzer
Status: ASSIGNED → NEW
adding racham back to the cc list.

ryan, do you want to attach a screen shot of what you've got so far?
Status: NEW → ASSIGNED
patch for the back end coming...
here's a patch for back end and simple front end ui.

ryan is working on the more complicated pref ui, but it isn't ready yet.

this patch will allow you to enable and disable the sound when you get new mail.

the other prefs still work, you just don't have UI for them yet.
this would be way cool.  I just want to make sure that this doesn't play a sound
on every biff that finds new mail - I think it should only play a noise if the
biff flag has changed to new mail. In other words, if I'm sitting near my
computer but not reading mail, it shouldn't go off every time new mail comes in.
It should only play a sound if I've done something with mail since the last time
I got new mail. Does this make sense? Does the code attached do that?
your comment makes sense.

PerformStatusBarBiff() is called from OnItemPropertyFlagChanged() and only when
the new value != the old value.

put simply, once you are in the "new mail" state, additional new mail will not
keep playing the sound.
excellent, then, sr=bienvenu
fix checked in.

I'll go open a new bug on the extended UI that ryan is currently working on.
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Does this really belong in nsStatusBarBiffManager::PerformStatusBarBiff?
where do you think it belongs?
I don't know.  Something just seems wrong when we're playing a sound in 
PerformStatusBarBiff().
blake, see my comment on "2001-01-05 18:36"

perhaps that will help you understand why I did what I did.
I know. and I know this is the right place to do it.  But we're still playing a 
sound in PerformStatusBarBiff() of class nsStatusBarBiffManager, and sounds 
have nothing to do with the statusbar.

Whatever.
actually, the idea behind that design was that there could be different biff
services that could register themselves and be notified when biff went off. So
the hope was to have a statusbar one (really the taskbar), a play sound one, and
then a notification area one.  3 different classes for 3 different things.  I
don't know if that design would hold up, but that was the idea.
ah, so you are saying we'd have another folder listener, similar to
nsStatusBarBiffManager, say nsSoundBiffManager, that would also check on
OnItemPropertyFlagChanged() if the biff state changed to new mail?

I don't think we should have more listeners.  We should have just one listener,
and have it call all the biff handlers.

We should have one folder listener for biff, say nsBiffManager.  We'll create a
nsIBiffHandler interface that has a single doBiff() method.

nsBiffManager would be based on nsStatusBarBiffManager.cpp, but the code to
update the UI would be moved out into nsStatusBarBiffHandler.

nsPlaySoundBiffHandler, nsStatusBarBiffHandler, (etc) would implement the
nsIBiffHandler interface and register themselves as members of the
"biff-handler" category.

on new mail, nsBiffManager would enumerate through all the services that
register themselves as members of a "biff-handler" category, QI them to
nsIBiffHandler, and call DoBiff().

to add future biff handlers, like a notification one, someone would just have to
drop in a component that had a service that implemented the nsIBiffHandler
interface that registered with the "biff-handler" interface.

comments?
that would be great. The main point being that all of the possible things that
would want to do something when the global biff state has changed wouldn't all
be in one class.
Yeah, sounds good to me.  cc me if you file this separately.
see bug #64947 that tracks that the way we should do this.
The feature works - woohoo

Unfortunately, the default Mozilla Mail sound (under WinNT) is really cheesy. I
checked in the control panel - sound settings, but could not find where this
sound is being set (it's not in the control panel settings).

Where is the setting that decides which sound is played?

Maby the answer should be written is the prefs setting in Mozilla.
Qa assigned to Sheela
QA Contact: fenella → sheelar
Verified 
using buildid:2001021406 on mac and linux
buildid:2001021506 on windows
Status: RESOLVED → VERIFIED
Blocks: 74644
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: