|
From: Daniel <da...@ii...> - 2006-12-06 14:13:05
|
> Hm. Can we store this away in the device struct somewhere and use that? (I
> vaguely remember WMP traces actually querying for the storage before
> sending the file too, perhaps that's what we should do?)
It sounds like a pretty logical step wether windows does it or not,
especially since it is part of the basic specification.
I am happy to write some stuff up along the lines of
getstorageid(Device,filesize)
-> ptp getstorageid's (if zero error)
-> for storage id's,
->get storage info
-> check storage isn't a removable storage with no media ( not &&
0x00010000)
-> find storage id with the largest amount of space
-> check space available is larger the file size (if not error).
-> return storageid.
This assumes we want to go down the path of caching the storage
information. Caching it would seem counter productive because it would
lead to inconsistent data in multi-session MTP implementations. It also
seems to be very fast (for at least my device) to get said storage
id's/info from the device.
Saying that this should all definitely wait till next version since as a
educated guess it is not breaking any large number of devices.
Let me know if anyone else is already working on this, otherwise I'll
start.
Daniel
|