My program watches for IDCMP_DISKINSERTED and IDCMP_DISKREMOVED. When a floppy is inserted I first get a REMOVED then INSERTED message. When I remove the floppy I only get REMOVED.
It does not do this for CDs.
I am using OS4.1FE Classic in WinUAE. I posted it originally on EAB. http://eab.abime.net/showthread.php?t=80113 Not sure if it is OS issue or WinUAE issue.
IDCMP_DISKINSERTED
IDCMP_DISKINSERTED
Workbench Explorer - A better way to browse drawers
- tonyw
- AmigaOS Core Developer
- Posts: 1479
- Joined: Wed Mar 09, 2011 1:36 pm
- Location: Sydney, Australia
Re: IDCMP_DISKINSERTED
When you insert a disk, the first signal (REMOVED) is redundant. That shouldn't be a problem to your software, though? It's just a notification to clear any old attachments you may have had.
cheers
tony
tony
- thomasrapp
- Posts: 310
- Joined: Sat Jun 18, 2011 11:22 pm
Re: IDCMP_DISKINSERTED
It causes flicker if your program shows a list of drives which is refreshed whenever such a signal is received.
- broadblues
- AmigaOS Core Developer
- Posts: 600
- Joined: Sat Jun 18, 2011 2:40 am
- Location: Portsmouth, UK
- Contact:
Re: IDCMP_DISKINSERTED
That depends on prgram design abit though does it not?thomasrapp wrote:It causes flicker if your program shows a list of drives which is refreshed whenever such a signal is received.
Receive Notification
Clear data
Update Display
Reload data
Update Display
Will certainly flicker
Recieve notification
Verify data
Update if changed
Won't so much.
I've not used it much directly, but I've always though of it's primary purpose as being to enabled auto clearing of insert volume requesters.
- thomasrapp
- Posts: 310
- Joined: Sat Jun 18, 2011 11:22 pm
Re: IDCMP_DISKINSERTED
A program which plays sounds on system events would suffer, too.
Re: IDCMP_DISKINSERTED
I updated my code to not flash the list being updated twice. It is a little strange behavior, but I can live with it.
Thomas is right about sounds. Floppies aren't in much use anymore, but still have to have a little bit of support for them, mainly ADFs.
Thomas is right about sounds. Floppies aren't in much use anymore, but still have to have a little bit of support for them, mainly ADFs.
Workbench Explorer - A better way to browse drawers
Re: IDCMP_DISKINSERTED
If the Intuition only sends a IDCMP_DISKINSERTED message when a CD is inserted, how can you distinguish between a quick removal and reinsertion of a CD and the insertion of a floppy disk? Both actions will produce IDCMP_DISKREMOVED followed by IDCMP_DISKINSERTED.mritter0 wrote:I updated my code to not flash the list being updated twice. It is a little strange behavior, but I can live with it.
Thomas is right about sounds. Floppies aren't in much use anymore, but still have to have a little bit of support for them, mainly ADFs.
It's nice that people have offered workarounds but the problem should be fixed or at least examined. The system should act constistantly for disk removal/insertion and I think someone needs to file a bug report so the issue can be examined and potentially fixed
AmigaOne X1000 with 2GB memory - OS4.1 FE
- thomasrapp
- Posts: 310
- Joined: Sat Jun 18, 2011 11:22 pm
Re: IDCMP_DISKINSERTED
CDs work fine. They send DISKINSERTED when you insert a disk and DISKREMOVED when you remove one.
Floppies issue redundant messages. When you remove a disk, they send DISKREMOVED, that's ok. But when you insert a disk, they send both DISKREMOVED and DISKINSERTED. They shouldn't send a REMOVED message on disk insertion.
Floppies issue redundant messages. When you remove a disk, they send DISKREMOVED, that's ok. But when you insert a disk, they send both DISKREMOVED and DISKINSERTED. They shouldn't send a REMOVED message on disk insertion.
Re: IDCMP_DISKINSERTED
This could be a "feature" of WinUAE - if there is a disk (adf) in dfx: and you change the adf without manually removing the adf WinUAE has to emulate a "disk removed" and a "disk inserted" hardware event in a very short time - this could explain mritters observation.
WinUAE could even do this for every new inserted adf, even if there was no disk in drive before.
Anyone testet this on real hardware?
WinUAE could even do this for every new inserted adf, even if there was no disk in drive before.
Anyone testet this on real hardware?