From 6d2150b731fe00af25042b065ff7a3ffffbd6df6 Mon Sep 17 00:00:00 2001 From: DYefremov Date: Thu, 10 Oct 2019 14:19:10 -0700 Subject: [PATCH] changes to start on macos --- README.md | 67 ++++++++++++--------------------------------- app/tools/vlc.py | 7 +++-- app/ui/dialogs.py | 3 +- app/ui/uicommons.py | 3 +- 4 files changed, 26 insertions(+), 54 deletions(-) diff --git a/README.md b/README.md index 97ee0bb4..ed2d1e37 100644 --- a/README.md +++ b/README.md @@ -1,57 +1,26 @@ # DemonEditor -## Enigma2 channel and satellites list editor for GNU/Linux. +## Experimental version of Enigma2 channel and satellites list editor for MacOS. Experimental support of Neutrino-MP or others on the same basis (BPanther, etc). Focused on the convenience of working in lists from the keyboard. The mouse is also fully supported (Drag and Drop etc) -### Keyboard shortcuts: -* **Ctrl + Insert** - copies the selected channels from the main list to the the bouquet beginning - or inserts (creates) a new bouquet. -* **Ctrl + BackSpace** - copies the selected channels from the main list to the bouquet end. -* **Ctrl + X** - only in bouquet list. **Ctrl + C** - only in services list. -Clipboard is **"rubber"**. There is an accumulation before the insertion! -* **Ctrl + E** - edit. -* **Ctrl + R, F2** - rename. -* **Ctrl + S, T** in Satellites edit tool for create satellite or transponder. -* **Ctrl + L** - parental lock. -* **Ctrl + H** - hide/skip. -* **Ctrl + P** - start play IPTV or other stream in the bouquet list. -* **Ctrl + Z** - switch(**zap**) the channel(works when the HTTP API is enabled, Enigma2 only). -* **Ctrl + W** - switch to the channel and watch in the program. -* **Space** - select/deselect. -* **Left/Right** - remove selection. -* **Ctrl + Up, Down, PageUp, PageDown, Home, End** - move selected items in the list. -* **Ctrl + O** - (re)load user data from current dir. -* **Ctrl + D** - load data from receiver. -* **Ctrl + U/B** upload data/bouquets to receiver. - -### Extra: -* Import feature. -* Multiple selections in lists only with Space key (as in file managers). -* Ability to download picons and update satellites (transponders) from web. -* Ability to import into bouquet (Neutrino WEB TV) from m3u. -* Ability to export bouquets with IPTV services to m3u. -* Assignment EPG from DVB or XML for IPTV services (Enigma2 only). -* Preview (playing) IPTV or other streams directly from the bouquet list (should be installed VLC). - + +## Note +This version is only for users those who wish to try running this program on MacOS. +The functionality and performance of this version may be very different from the main version! +**Not all features are supported and tested!** + ### Minimum requirements: -Python >= 3.5.2 and GTK+ >= 3.16 with PyGObject bindings. +Python >= **3.5**, GTK+ >= **3.16**, pygobject3, adwaita-icon-theme, python3-requests. +**Installation:** +```brew install gtk+3 pygobject3 adwaita-icon-theme``` +```pip3 install requests``` -### Launching: -To start the program, in most cases it is enough to download the archive, unpack and run it by -double clicking on DemonEditor.desktop in the root directory, or launching from the console -with the command: ```./start.py``` -Extra folders can be deleted, excluding the *app* folder and root files like *DemonEditor.desktop* and *start.py*! - +### Launching +To start the program, in most cases it is enough to download the archive, +unpack and run it from the terminal with the command: ```./start.py``` + ### Note. -To create a simple **debian package**, you can use the *build-deb.sh.* - -The program is tested only with openATV image and Formuler F1 receiver in my favourite Linux distributions. -(the latest versions of Linux Mint 18.* and 19* MATE 64-bit)! - -**Terrestrial(DVB-T/T2) and cable(DVB-C) channels are only supported for Enigma2!** - -**Important:** -Main supported **lamedb** format is version **4**. Versions **3** and **5** has only experimental support! -For version **3** is only read mode available. When saving, version **4** format is used instead! - +**Terrestrial(DVB-T/T2) and cable channels are supported(Enigma2 only) with limitation!** +Main supported **lamedb** format is version **4**. Versions **3** and **5** has only experimental support! +For version **3** is only read mode available. When saving, version **4** format is used instead! diff --git a/app/tools/vlc.py b/app/tools/vlc.py index 09e7262a..14ce149b 100644 --- a/app/tools/vlc.py +++ b/app/tools/vlc.py @@ -199,8 +199,11 @@ def find_lib(): break else: # hope, some [DY]LD_LIBRARY_PATH is set... # pre-load libvlccore VLC 2.2.8+ - ctypes.CDLL('libvlccore.dylib') - dll = ctypes.CDLL('libvlc.dylib') + try: + ctypes.CDLL('libvlccore.dylib') + dll = ctypes.CDLL('libvlc.dylib') + except OSError: + pass else: raise NotImplementedError('%s: %s not supported' % (sys.argv[0], sys.platform)) diff --git a/app/ui/dialogs.py b/app/ui/dialogs.py index 7e2690d1..b3cc0f26 100644 --- a/app/ui/dialogs.py +++ b/app/ui/dialogs.py @@ -163,7 +163,8 @@ def get_dialog_from_xml(dialog_type, transient, use_header=0, title=""): def get_message(message): """ returns translated message """ - return locale.dgettext(TEXT_DOMAIN, message) + # return locale.dgettext(TEXT_DOMAIN, message) + return message @lru_cache(maxsize=5) diff --git a/app/ui/uicommons.py b/app/ui/uicommons.py index 63c1f942..56ae3d52 100644 --- a/app/ui/uicommons.py +++ b/app/ui/uicommons.py @@ -1,4 +1,3 @@ -import locale import os import gi @@ -16,7 +15,7 @@ IS_GNOME_SESSION = int(bool(os.environ.get("GNOME_DESKTOP_SESSION_ID"))) TEXT_DOMAIN = "demon-editor" if UI_RESOURCES_PATH == "app/ui/": LANG_DIR = UI_RESOURCES_PATH + "lang" - locale.bindtextdomain(TEXT_DOMAIN, UI_RESOURCES_PATH + "lang") + # locale.bindtextdomain(TEXT_DOMAIN, UI_RESOURCES_PATH + "lang") theme = Gtk.IconTheme.get_default() _IMAGE_MISSING = theme.load_icon("image-missing", 16, 0) if theme.lookup_icon("image-missing", 16, 0) else None