Bug 102731 - Fix media players appearing as phones in gvfs
Summary: Fix media players appearing as phones in gvfs
Status: RESOLVED FIXED
Alias: None
Product: media-player-info
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Martin Pitt
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-09-14 15:00 UTC by Bastien Nocera
Modified: 2017-09-15 12:28 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
mpi2hwdb.py: Export the icon through hwdb to udev (1022 bytes, patch)
2017-09-14 15:01 UTC, Bastien Nocera
Details | Splinter Review
mpi2hwdb.py: Force default icon to be multimedia-player (1.19 KB, patch)
2017-09-14 15:01 UTC, Bastien Nocera
Details | Splinter Review

Description Bastien Nocera 2017-09-14 15:00:21 UTC
See patches.
Comment 1 Bastien Nocera 2017-09-14 15:01:02 UTC
Created attachment 134224 [details] [review]
mpi2hwdb.py: Export the icon through hwdb to udev

So that it can be consumed by user-space, such as gvfs' gphoto2
and mtp device monitors.
Comment 2 Bastien Nocera 2017-09-14 15:01:06 UTC
Created attachment 134225 [details] [review]
mpi2hwdb.py: Force default icon to be multimedia-player

Though most MTP devices available nowadays are phones, all those listed
in this repository are media-players, unless an icon is assigned to
them.

To avoid gvfs from assigning a phone icon to a media player, add an icon
to the udev definition of those devices.

See https://bugzilla.gnome.org/show_bug.cgi?id=759042
Comment 3 Martin Pitt 2017-09-15 12:28:06 UTC
Hello Bastien,

Thanks for the patches, makes sense!

I fixed the "Export icon.." patch to use `block +=` instead of the `print` statement (which isn't valid Python 3, and wouldn't change the actual file output). Applied: https://cgit.freedesktop.org/media-player-info/commit/?id=6a5e0be3

I fixed the second patch "Force default icon" to actually set `ID_MEDIA_PLAYER_ICON_NAME` (not `ID_MEDIA_PLAYER`), and applied: https://cgit.freedesktop.org/media-player-info/commit/?id=1a969ea

I'll release version 23 now, so that this can get out to the world.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.