Skip to content

Commit

Permalink
Fixed missing icons in AppImage
Browse files Browse the repository at this point in the history
  • Loading branch information
kozec committed Feb 18, 2018
1 parent ad741f4 commit 88d4747
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions scripts/syncthing-gtk
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,13 @@ if __name__ == "__main__":
init_locale(localedir)
init_logging()

if "APPDIR" in os.environ:
# Running as AppImage
from gi.repository import Gtk
icons = os.path.abspath(os.path.join(os.environ["APPDIR"], "icons"))
Gtk.IconTheme.get_default().prepend_search_path(os.environ["APPDIR"])
Gtk.IconTheme.get_default().prepend_search_path(os.environ["APPDIR"] + "/32x32/apps")
Gtk.IconTheme.get_default().prepend_search_path(os.environ["APPDIR"] + "/32x32/status")

from syncthing_gtk.app import App
App(path, os.path.join(path, "icons")).run(sys.argv)

0 comments on commit 88d4747

Please sign in to comment.