Windows: Drive insertion/removal event isn't fired for a card reader
Closed, ResolvedPublic

Description

WM_DEVICECHANGE does notify about devices which were inserted or removed from main connection ports, e.g. USB, card readers with direct connection to the bus (like one in laptops) or optical disks, but isn't fired for USB card readers. Evaluate if SHChangeNotifyRegister gives better results.

References:
http://www.codeproject.com/Articles/3226/Using-the-shell-to-receive-notification-of-removab
https://msdn.microsoft.com/de-de/library/windows/desktop/bb762120%28v=vs.85%29.aspx

Details

Commits
Restricted Diffusion Commit
BAndiT1983 updated the task description. (Show Details)
BAndiT1983 raised the priority of this task from to Normal.
BAndiT1983 claimed this task.
BAndiT1983 added a project: Open Cine.
BAndiT1983 moved this task to Pending tasks on the Open Cine board.
BAndiT1983 added a subscriber: BAndiT1983.
BAndiT1983 updated the task description. (Show Details)Aug 30 2015, 11:27 PM

Implemented and tested it successfully. Next step, before commit, is to retrieve only mounted drives as Windows provides all card reader drives (mounted or not).

Used (maybe misused a little bit) GetVolumeInformation() to get only mounted removable drives. Seems to work for now. Doing some tests before uploading the current source code.

BAndiT1983 added a commit: Restricted Diffusion Commit.Sep 3 2015, 7:51 AM
BAndiT1983 closed this task as Resolved.

Tested and committed a bug fix.