mirror of
https://github.com/arsenetar/dupeguru.git
synced 2025-05-09 02:09:49 +00:00
Fixed linux-specific crashes and glitches.
This commit is contained in:
parent
6fc7e5ace1
commit
8a0d31f612
@ -6,6 +6,7 @@
|
|||||||
# which should be included with this package. The terms are also available at
|
# which should be included with this package. The terms are also available at
|
||||||
# http://www.hardcoded.net/licenses/bsd_license
|
# http://www.hardcoded.net/licenses/bsd_license
|
||||||
|
|
||||||
|
import sys
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
import os.path as op
|
import os.path as op
|
||||||
@ -97,6 +98,9 @@ class DupeGuru(DupeGuruBase, QObject):
|
|||||||
]
|
]
|
||||||
createActions(ACTIONS, self)
|
createActions(ACTIONS, self)
|
||||||
|
|
||||||
|
if sys.platform == 'linux2':
|
||||||
|
self.actionCheckForUpdate.setVisible(False) # This only works on Windows
|
||||||
|
|
||||||
def _setup_as_registered(self):
|
def _setup_as_registered(self):
|
||||||
self.prefs.registration_code = self.registration_code
|
self.prefs.registration_code = self.registration_code
|
||||||
self.prefs.registration_email = self.registration_email
|
self.prefs.registration_email = self.registration_email
|
||||||
|
@ -69,6 +69,9 @@ class ResultWindow(QMainWindow):
|
|||||||
self.actionDelta.setCheckable(True)
|
self.actionDelta.setCheckable(True)
|
||||||
self.actionPowerMarker.setCheckable(True)
|
self.actionPowerMarker.setCheckable(True)
|
||||||
|
|
||||||
|
if sys.platform not in {'darwin', 'linux2'}:
|
||||||
|
self.actionHardlinkMarked.setVisible(False)
|
||||||
|
|
||||||
def _setupMenu(self):
|
def _setupMenu(self):
|
||||||
self.menubar = QMenuBar(self)
|
self.menubar = QMenuBar(self)
|
||||||
self.menubar.setGeometry(QRect(0, 0, 630, 22))
|
self.menubar.setGeometry(QRect(0, 0, 630, 22))
|
||||||
@ -192,12 +195,6 @@ class ResultWindow(QMainWindow):
|
|||||||
if self.app.prefs.resultWindowRect is not None and not self.app.prefs.resultWindowIsMaximized:
|
if self.app.prefs.resultWindowRect is not None and not self.app.prefs.resultWindowIsMaximized:
|
||||||
self.setGeometry(self.app.prefs.resultWindowRect)
|
self.setGeometry(self.app.prefs.resultWindowRect)
|
||||||
|
|
||||||
# Platform-specific setup
|
|
||||||
if sys.platform == 'linux2':
|
|
||||||
self.actionCheckForUpdate.setVisible(False) # This only works on Windows
|
|
||||||
if sys.platform not in {'darwin', 'linux2'}:
|
|
||||||
self.actionHardlinkMarked.setVisible(False)
|
|
||||||
|
|
||||||
#--- Private
|
#--- Private
|
||||||
def _load_columns(self):
|
def _load_columns(self):
|
||||||
h = self.resultsView.horizontalHeader()
|
h = self.resultsView.horizontalHeader()
|
||||||
|
@ -85,7 +85,7 @@ class PreferencesDialog(PreferencesDialogBase):
|
|||||||
if sys.platform == 'linux2':
|
if sys.platform == 'linux2':
|
||||||
# Under linux, whether it's a Qt layout bug or something else, the size threshold text edit
|
# Under linux, whether it's a Qt layout bug or something else, the size threshold text edit
|
||||||
# doesn't have enough space, so we make the pref pane higher to compensate.
|
# doesn't have enough space, so we make the pref pane higher to compensate.
|
||||||
self.resize(self.width(), 400)
|
self.resize(self.width(), 480)
|
||||||
|
|
||||||
def _load(self, prefs, setchecked):
|
def _load(self, prefs, setchecked):
|
||||||
scan_type_index = SCAN_TYPE_ORDER.index(prefs.scan_type)
|
scan_type_index = SCAN_TYPE_ORDER.index(prefs.scan_type)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user