diff --git a/qt/base/app.py b/qt/base/app.py index 279d824d..5bc86c6c 100644 --- a/qt/base/app.py +++ b/qt/base/app.py @@ -183,7 +183,8 @@ class DupeGuru(DupeGuruBase, QObject): self.directories_dialog.show() def show_help(self): - url = QUrl.fromLocalFile(op.abspath('help/intro.htm')) + base_path = platform.HELP_PATH.format(self.EDITION) + url = QUrl.fromLocalFile(op.abspath(op.join(base_path, 'intro.htm'))) QDesktopServices.openUrl(url) def show_preferences(self): diff --git a/qt/base/main_window.py b/qt/base/main_window.py index 2ada1c83..ac30c02b 100644 --- a/qt/base/main_window.py +++ b/qt/base/main_window.py @@ -6,6 +6,8 @@ # which should be included with this package. The terms are also available at # http://www.hardcoded.net/licenses/hs_license +import sys + from PyQt4.QtCore import Qt, QCoreApplication, QProcess, SIGNAL, QUrl from PyQt4.QtGui import (QMainWindow, QMenu, QPixmap, QIcon, QToolButton, QLabel, QHeaderView, QMessageBox, QInputDialog, QLineEdit, QDesktopServices) @@ -85,6 +87,10 @@ class MainWindow(QMainWindow, Ui_MainWindow): self.statusLabel = QLabel(self) self.statusbar.addPermanentWidget(self.statusLabel, 1) + + # Linux setup + if sys.platform == 'linux2': + self.actionCheckForUpdate.setVisible(False) # This only works on Windows #--- Private def _confirm(self, title, msg, default_button=QMessageBox.Yes): diff --git a/qt/base/platform_lnx.py b/qt/base/platform_lnx.py index 07dd08ef..d05fa789 100644 --- a/qt/base/platform_lnx.py +++ b/qt/base/platform_lnx.py @@ -7,4 +7,5 @@ # which should be included with this package. The terms are also available at # http://www.hardcoded.net/licenses/hs_license -INITIAL_FOLDER_IN_DIALOGS = u'/' \ No newline at end of file +INITIAL_FOLDER_IN_DIALOGS = u'/' +HELP_PATH = '/usr/local/share/dupeguru_{0}/help' diff --git a/qt/base/platform_osx.py b/qt/base/platform_osx.py index 0379656e..43c5474f 100644 --- a/qt/base/platform_osx.py +++ b/qt/base/platform_osx.py @@ -9,4 +9,5 @@ # dummy unit to allow the app to run under OSX during development -INITIAL_FOLDER_IN_DIALOGS = u'/' \ No newline at end of file +INITIAL_FOLDER_IN_DIALOGS = u'/' +HELP_PATH = '' diff --git a/qt/base/platform_win.py b/qt/base/platform_win.py index 1e2aefe3..d9c694e2 100644 --- a/qt/base/platform_win.py +++ b/qt/base/platform_win.py @@ -7,4 +7,5 @@ # which should be included with this package. The terms are also available at # http://www.hardcoded.net/licenses/hs_license -INITIAL_FOLDER_IN_DIALOGS = u'C:\\' \ No newline at end of file +INITIAL_FOLDER_IN_DIALOGS = u'C:\\' +HELP_PATH = 'help' diff --git a/qt/me/app.py b/qt/me/app.py index ea5e3065..59c910c9 100644 --- a/qt/me/app.py +++ b/qt/me/app.py @@ -14,6 +14,7 @@ from preferences import Preferences from preferences_dialog import PreferencesDialog class DupeGuru(DupeGuruBase): + EDITION = 'me' LOGO_NAME = 'logo_me' NAME = 'dupeGuru Music Edition' VERSION = '5.7.2' diff --git a/qt/pe/app.py b/qt/pe/app.py index 609c0f8e..da91e0f5 100644 --- a/qt/pe/app.py +++ b/qt/pe/app.py @@ -54,6 +54,7 @@ class File(fs.File): class DupeGuru(DupeGuruBase): + EDITION = 'pe' LOGO_NAME = 'logo_pe' NAME = 'dupeGuru Picture Edition' VERSION = '1.8.6' diff --git a/qt/se/app.py b/qt/se/app.py index 9a0ac79a..0998d12a 100644 --- a/qt/se/app.py +++ b/qt/se/app.py @@ -24,6 +24,7 @@ class Directories(DirectoriesBase): return STATE_EXCLUDED class DupeGuru(DupeGuruBase): + EDITION = 'se' LOGO_NAME = 'logo_se' NAME = 'dupeGuru' VERSION = '2.9.2'