Update use of media_dir following change in Libervia Media:

Libervia Media is now a Python package instead of files to put in a directory to specify
in settings. The discovery is now automatic, removing the need for settings and enabling
easier installation. Furthermore, it should now work even if the package is zipped.
`libervia_media` can now be specified as a dependency for frontends requiring it.
This commit is contained in:
Goffi 2026-01-13 10:57:19 +01:00
commit 919cafc68c

View file

@ -48,6 +48,7 @@ from PyQt6.QtWidgets import (
QWidget,
)
import gi
from libervia import media
from libervia.backend.core.i18n import _
from libervia.frontends.tools import aio, display_servers, webrtc
@ -204,8 +205,7 @@ class AVCallUI(QMainWindow):
@classmethod
async def run(cls, parent, call_data):
"""Run PyQt loop and show the app"""
media_dir = parent.host.settings.common.media_dir
icons_path = media_dir / "fonts/fontawesome/svgs/solid"
icons_path = media.get_path() / "fonts/fontawesome/svgs/solid"
app = QApplication([])
av_call_gui = cls(parent.host, icons_path)
av_call_gui.show()