diff --git a/README.md b/README.md
index 2e323fdb..9c161a9c 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
-# DemonEditor
+# DemonEditor
-## Experimental version for Mac OS.
-This version is only for users those who wish to try running this program on **Mac OS**.
+## Enigma2 channel and satellites list editor for macOS (experimental).
+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!**
@@ -20,14 +20,11 @@ Install [PyInstaller](https://www.pyinstaller.org/) with the command from the te
```pip3 install pyinstaller```
and in th root dir run command:
```pyinstaller DemonEditor.spec```
-
-If you need to change the application icon, replace the icon.icns file with yours with the same name
-or edit the DemonEditor.spec file.
-
-To run the program, copy the **dist/DemonEditor.app** bundle to the **Application** directory.
-Perhaps in the security settings it will be necessary to allow the launch of this application!
+
+Users of the **64-bit version of the OS** can download a ready-made package from [here](https://github.com/DYefremov/DemonEditor/raw/experimental-mac/dist/DemonEditor.app.zip).
+Just unpack and run. Recommended copy the bundle to the **Application** directory.
+Perhaps in the security settings it will be necessary to allow the launch of this application!
-Users of the **64-bit version of the OS** can download a ready-made package from [here](https://github.com/DYefremov/DemonEditor/raw/experimental-mac/dist/DemonEditor.app.zip). Just unpack and run.
**Note. The package may not contain all the latest changes!**
diff --git a/app/ui/app_menu_bar.ui b/app/ui/app_menu_bar.ui
index 931592d6..7f9aa73f 100644
--- a/app/ui/app_menu_bar.ui
+++ b/app/ui/app_menu_bar.ui
@@ -10,7 +10,7 @@
Settings
- app.on_preferences
+ app.on_settings
diff --git a/app/ui/main_app_window.py b/app/ui/main_app_window.py
index 30856ff8..e26209e1 100644
--- a/app/ui/main_app_window.py
+++ b/app/ui/main_app_window.py
@@ -73,7 +73,8 @@ class Application(Gtk.Application):
self._handlers = {"on_close_app": self.on_close_app,
"on_resize": self.on_resize,
"on_about_app": self.on_about_app,
- "on_preferences": self.on_preferences,
+ "on_settings": self.on_settings,
+ "on_profile_changed": self.on_profile_changed,
"on_download": self.on_download,
"on_data_open": self.on_data_open,
"on_data_save": self.on_data_save,
@@ -279,7 +280,7 @@ class Application(Gtk.Application):
def do_startup(self):
Gtk.Application.do_startup(self)
# Init app menu bar handlers
- main_handlers = ("on_new_configuration", "on_data_open", "on_data_save", "on_download", "on_preferences",
+ main_handlers = ("on_new_configuration", "on_data_open", "on_data_save", "on_download", "on_settings",
"on_close_app", "on_import_bouquet", "on_import_bouquets", "on_satellite_editor_show",
"on_picons_loader_show", "on_backup_tool_show", "on_about_app")
iptv_handlers = ("on_iptv", "on_import_yt_list", "on_import_m3u", "on_export_to_m3u",
@@ -1616,7 +1617,7 @@ class Application(Gtk.Application):
# ***************** Backup ********************#
- def on_backup_tool_show(self, item):
+ def on_backup_tool_show(self, action, value=None):
""" Shows backup tool dialog """
BackupDialog(self._main_window, self._settings, self.open_data).show()
@@ -2234,9 +2235,8 @@ class Application(Gtk.Application):
profile_name = self._profile_combo_box.get_active_text()
self._profile_combo_box.set_tooltip_text("{}: {}".format(label, self._settings.host))
msg = get_message("Profile:")
-
if self._s_type is SettingsType.ENIGMA_2:
- self._main_window.set_title.set_subtitle("DemonEditor [{} {} Enigma2 v.{}]".format(msg, profile_name, self.get_format_version()))
+ self._main_window.set_title("DemonEditor [{} {} Enigma2 v.{}]".format(msg, profile_name, self.get_format_version()))
elif self._s_type is SettingsType.NEUTRINO_MP:
self._main_window.set_title("DemonEditor [{} {} Neutrino-MP]".format(msg, profile_name))
diff --git a/app/ui/settings_dialog.py b/app/ui/settings_dialog.py
index 00a02485..96a35555 100644
--- a/app/ui/settings_dialog.py
+++ b/app/ui/settings_dialog.py
@@ -118,6 +118,7 @@ class SettingsDialog:
self._profile_remove_button = builder.get_object("profile_remove_button")
self._apply_profile_button = builder.get_object("apply_profile_button")
self._apply_profile_button.bind_property("visible", builder.get_object("header_separator"), "visible")
+ self._apply_profile_button.bind_property("visible", builder.get_object("reset_button"), "visible")
# Language
self._lang_combo_box = builder.get_object("lang_combo_box")
# Settings
diff --git a/app/ui/uicommons.py b/app/ui/uicommons.py
index ef977f17..667484fc 100644
--- a/app/ui/uicommons.py
+++ b/app/ui/uicommons.py
@@ -1,29 +1,18 @@
-import gettext
-import locale
import os
import sys
-
-import gi
from enum import Enum, IntEnum
+from app.settings import Settings, SettingsException
import gi
-from app.settings import Settings, SettingsException
-
gi.require_version('Gtk', '3.0')
from gi.repository import Gtk, Gdk
-GTK_PATH = os.environ.get("GTK_PATH", None)
-# For launching from the bundle.
-if os.getcwd() == "/" and GTK_PATH:
- os.chdir(GTK_PATH)
-
# path to *.glade files
UI_RESOURCES_PATH = "app/ui/" if os.path.exists("app/ui/") else "ui/"
IS_GNOME_SESSION = int(bool(os.environ.get("GNOME_DESKTOP_SESSION_ID")))
# translation
-os.environ["LANG"] = "{}.{}".format(*locale.getlocale())
TEXT_DOMAIN = "demon-editor"
try:
settings = Settings.get_instance()
@@ -31,11 +20,22 @@ except SettingsException:
pass
else:
os.environ["LANGUAGE"] = settings.language
- if UI_RESOURCES_PATH == "app/ui/":
- locale.bindtextdomain(TEXT_DOMAIN, UI_RESOURCES_PATH + "lang")
-LANG_PATH = GTK_PATH + "/share/locale" if GTK_PATH else UI_RESOURCES_PATH + "lang"
-gettext.bindtextdomain(TEXT_DOMAIN, LANG_PATH)
-if sys.platform != "darwin":
+
+LANG_PATH = UI_RESOURCES_PATH + "lang"
+
+if sys.platform == "darwin":
+ import gettext
+
+ GTK_PATH = os.environ.get("GTK_PATH", None)
+ if GTK_PATH:
+ LANG_PATH = GTK_PATH + "/share/locale"
+ gettext.bindtextdomain(TEXT_DOMAIN, LANG_PATH)
+ # For launching from the bundle.
+ if os.getcwd() == "/" and GTK_PATH:
+ os.chdir(GTK_PATH)
+else:
+ import locale
+
locale.bindtextdomain(TEXT_DOMAIN, LANG_PATH)
theme = Gtk.IconTheme.get_default()
diff --git a/deb/usr/share/demoneditor/start.py b/deb/usr/share/demoneditor/start.py
deleted file mode 100755
index cefbe196..00000000
--- a/deb/usr/share/demoneditor/start.py
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/usr/bin/env python3
-from app.ui.main_app_window import start_app
-
-start_app()
diff --git a/deb/usr/share/icons/hicolor/96x96/apps/demon-editor.png b/deb/usr/share/icons/hicolor/96x96/apps/demon-editor.png
deleted file mode 100644
index 0c560a60..00000000
Binary files a/deb/usr/share/icons/hicolor/96x96/apps/demon-editor.png and /dev/null differ
diff --git a/deb/usr/share/icons/hicolor/scalable/apps/demon-editor.svg b/deb/usr/share/icons/hicolor/scalable/apps/demon-editor.svg
deleted file mode 100644
index 451891b4..00000000
--- a/deb/usr/share/icons/hicolor/scalable/apps/demon-editor.svg
+++ /dev/null
@@ -1,634 +0,0 @@
-
-
diff --git a/icon.icns b/icon.icns
index 8c6a900d..b9d9967c 100644
Binary files a/icon.icns and b/icon.icns differ