mirror of
https://github.com/libratbag/libratbag.git
synced 2026-11-07 15:14:38 +01:00
device: export the full path to the SVG as well
Exporting just the filename requires the caller to know where that file sits. That's useful for things like e.g. icons where callers may several sets to chose from but here most callers will just use the default svg provided by libratbag. Export that, so that we don't have build-time dependencies in the callers just for that single path. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
@@ -84,6 +84,7 @@ class RatbagdDevice(_RatbagdDBus):
|
||||
self._devnode = self.dbus_property("Id")
|
||||
self._description = self.dbus_property("Description")
|
||||
self._svg = self.dbus_property("Svg")
|
||||
self._svg_path = self.dbus_property("SvgPath")
|
||||
|
||||
self._profiles = []
|
||||
self._active_profile = -1
|
||||
@@ -125,6 +126,14 @@ class RatbagdDevice(_RatbagdDBus):
|
||||
"""
|
||||
return self._svg
|
||||
|
||||
@property
|
||||
def svg_path(self):
|
||||
"""
|
||||
The absolute SVG path. This function returns the full path to the
|
||||
svg file.
|
||||
"""
|
||||
return self._svg_path
|
||||
|
||||
@property
|
||||
def id(self):
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user