1
0
mirror of https://github.com/arsenetar/dupeguru.git synced 2024-12-21 10:59:03 +00:00

Finish moving all qtlib py files to qt

This commit is contained in:
Andrew Senetar 2022-05-08 19:22:08 -05:00
parent 18359c3ea6
commit 36280b01e6
Signed by: arsenetar
GPG Key ID: C63300DCE48AB2F1
36 changed files with 40 additions and 50 deletions

View File

@ -44,7 +44,7 @@ def special_folder_path(special_folder, appname=None, portable=False):
try:
from PyQt5.QtCore import QUrl, QStandardPaths
from PyQt5.QtGui import QDesktopServices
from qtlib.util import get_appdata
from qt.util import get_appdata
from core.util import executable_folder
from hscommon.plat import ISWINDOWS, ISOSX
import subprocess

View File

Before

Width:  |  Height:  |  Size: 398 B

After

Width:  |  Height:  |  Size: 398 B

View File

@ -11,10 +11,10 @@ from PyQt5.QtGui import QPixmap, QFont
from PyQt5.QtWidgets import QDialog, QDialogButtonBox, QSizePolicy, QHBoxLayout, QVBoxLayout, QLabel
from core.util import check_for_update
from qtlib.util import move_to_screen_center
from qt.util import move_to_screen_center
from hscommon.trans import trget
tr = trget("qtlib")
tr = trget("qtlib") # TODO change to ui
class AboutBox(QDialog):

View File

@ -14,10 +14,10 @@ from PyQt5.QtWidgets import QApplication, QFileDialog, QDialog, QMessageBox, QSt
from hscommon.trans import trget
from hscommon import desktop, plat
from qtlib.about_box import AboutBox
from qtlib.recent import Recent
from qtlib.util import create_actions
from qtlib.progress_window import ProgressWindow
from qt.about_box import AboutBox
from qt.recent import Recent
from qt.util import create_actions
from qt.progress_window import ProgressWindow
from core.app import AppMode, DupeGuru as DupeGuruModel
import core.pe.photo

View File

@ -10,7 +10,7 @@ from PyQt5.QtCore import Qt
from PyQt5.QtWidgets import QDialog, QVBoxLayout, QLabel, QCheckBox, QDialogButtonBox
from hscommon.trans import trget
from qtlib.radio_box import RadioBox
from qt.radio_box import RadioBox
tr = trget("ui")

View File

@ -9,7 +9,7 @@
from PyQt5.QtCore import Qt
from PyQt5.QtWidgets import QDockWidget, QWidget
from qtlib.util import move_to_screen_center
from qt.util import move_to_screen_center
from .details_table import DetailsModel
from hscommon.plat import ISLINUX

View File

@ -4,7 +4,7 @@
<file alias="logo_se_big">../images/dgse_logo_128.png</file>
<file alias="plus">../images/plus_8.png</file>
<file alias="minus">../images/minus_8.png</file>
<file alias="search_clear_13">../qtlib/images/search_clear_13.png</file>
<file alias="search_clear_13">../images/search_clear_13.png</file>
<file alias="exchange">../images/exchange_purple_upscaled.png</file>
<file alias="zoom_in">../images/old_zoom_in.png</file>
<file alias="zoom_out">../images/old_zoom_out.png</file>

View File

@ -27,9 +27,9 @@ from PyQt5.QtGui import QPixmap, QIcon
from hscommon.trans import trget
from core.app import AppMode
from qtlib.radio_box import RadioBox
from qtlib.recent import Recent
from qtlib.util import move_to_screen_center, create_actions
from qt.radio_box import RadioBox
from qt.recent import Recent
from qt.util import move_to_screen_center, create_actions
from . import platform
from .directories_model import DirectoriesModel, DirectoriesDelegate

View File

@ -18,7 +18,7 @@ from PyQt5.QtWidgets import (
from PyQt5.QtGui import QBrush
from hscommon.trans import trget
from qtlib.tree_model import RefNode, TreeModel
from qt.tree_model import RefNode, TreeModel
tr = trget("ui")

View File

@ -23,9 +23,9 @@ from PyQt5.QtWidgets import (
from hscommon.trans import trget
from hscommon.desktop import open_url
from .util import horizontal_spacer
from qt.util import horizontal_spacer
tr = trget("qtlib")
tr = trget("qtlib") # TODO change to ui
class ErrorReportDialog(QDialog):

View File

@ -5,8 +5,8 @@
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QFont, QFontMetrics, QIcon, QColor
from qtlib.column import Column
from qtlib.table import Table
from qt.column import Column
from qt.table import Table
from hscommon.trans import trget
tr = trget("ui")

View File

@ -16,7 +16,7 @@ from PyQt5.QtWidgets import (
)
from hscommon.trans import trget
from qtlib.util import horizontal_wrap
from qt.util import horizontal_wrap
from .ignore_list_table import IgnoreListTable
tr = trget("ui")

View File

@ -5,8 +5,8 @@
# which should be included with this package. The terms are also available at
# http://www.gnu.org/licenses/gpl-3.0.html
from qtlib.column import Column
from qtlib.table import Table
from qt.column import Column
from qt.table import Table
class IgnoreListTable(Table):

View File

@ -4,7 +4,7 @@
# which should be included with this package. The terms are also available at
# http://www.gnu.org/licenses/gpl-3.0.html
from qtlib.column import Column
from qt.column import Column
from ..results_model import ResultsModel as ResultsModelBase

View File

@ -8,7 +8,7 @@ from PyQt5.QtWidgets import QFormLayout
from PyQt5.QtCore import Qt
from hscommon.trans import trget
from hscommon.plat import ISLINUX
from qtlib.radio_box import RadioBox
from qt.radio_box import RadioBox
from core.scanner import ScanType
from core.app import AppMode

View File

@ -4,7 +4,7 @@
# which should be included with this package. The terms are also available at
# http://www.gnu.org/licenses/gpl-3.0.html
from qtlib.column import Column
from qt.column import Column
from ..results_model import ResultsModel as ResultsModelBase

View File

@ -33,7 +33,7 @@ from hscommon import desktop, plat
from hscommon.trans import trget
from hscommon.plat import ISLINUX
from qtlib.util import horizontal_wrap, move_to_screen_center
from qt.util import horizontal_wrap, move_to_screen_center
from qt.preferences import get_langnames
from enum import Flag, auto

View File

@ -24,8 +24,8 @@ from PyQt5.QtWidgets import (
)
from hscommon.trans import trget
from qtlib.selectable_list import ComboboxModel, ListviewModel
from qtlib.util import vertical_spacer
from qt.selectable_list import ComboboxModel, ListviewModel
from qt.util import vertical_spacer
from core.gui.prioritize_dialog import PrioritizeDialog as PrioritizeDialogModel
tr = trget("ui")

View File

@ -19,7 +19,7 @@ from PyQt5.QtWidgets import (
QAbstractItemView,
)
from qtlib.util import move_to_screen_center
from qt.util import move_to_screen_center
from hscommon.trans import trget
from .problem_table import ProblemTable

View File

@ -6,8 +6,8 @@
# which should be included with this package. The terms are also available at
# http://www.gnu.org/licenses/gpl-3.0.html
from qtlib.column import Column
from qtlib.table import Table
from qt.column import Column
from qt.table import Table
class ProblemTable(Table):

View File

@ -8,7 +8,7 @@
from PyQt5.QtCore import pyqtSignal
from PyQt5.QtWidgets import QWidget, QHBoxLayout, QRadioButton
from .util import horizontal_spacer
from qt.util import horizontal_spacer
class RadioBox(QWidget):

View File

@ -14,7 +14,7 @@ from PyQt5.QtWidgets import QAction
from hscommon.trans import trget
from hscommon.util import dedupe
tr = trget("qtlib")
tr = trget("qtlib") # TODO move to ui
MenuEntry = namedtuple("MenuEntry", "menu fixedItemCount")

View File

@ -24,8 +24,8 @@ from PyQt5.QtWidgets import (
)
from hscommon.trans import trget
from qtlib.util import move_to_screen_center, horizontal_wrap, create_actions
from qtlib.search_edit import SearchEdit
from qt.util import move_to_screen_center, horizontal_wrap, create_actions
from qt.search_edit import SearchEdit
from core.app import AppMode
from .results_model import ResultsView

View File

@ -10,7 +10,7 @@ from PyQt5.QtCore import Qt, pyqtSignal, QModelIndex
from PyQt5.QtGui import QBrush, QFont, QFontMetrics
from PyQt5.QtWidgets import QTableView
from qtlib.table import Table
from qt.table import Table
class ResultsModel(Table):

View File

@ -4,7 +4,7 @@
# which should be included with this package. The terms are also available at
# http://www.gnu.org/licenses/gpl-3.0.html
from qtlib.column import Column
from qt.column import Column
from ..results_model import ResultsModel as ResultsModelBase

View File

@ -12,7 +12,7 @@ from PyQt5.QtWidgets import QToolButton, QLineEdit, QStyle, QStyleOptionFrame
from hscommon.trans import trget
tr = trget("qtlib")
tr = trget("qtlib") # TODO change to ui
# IMPORTANT: For this widget to work propertly, you have to add "search_clear_13" from the
# "images" folder in your resources.

View File

@ -14,7 +14,7 @@ from PyQt5.QtWidgets import (
QStackedWidget,
)
from hscommon.trans import trget
from qtlib.util import move_to_screen_center, create_actions
from qt.util import move_to_screen_center, create_actions
from .directories_dialog import DirectoriesDialog
from .result_window import ResultWindow
from .ignore_list_dialog import IgnoreListDialog

View File

@ -1,10 +0,0 @@
Copyright 2014, Hardcoded Software Inc., http://www.hardcoded.net
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
* Neither the name of Hardcoded Software Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View File

4
run.py
View File

@ -14,8 +14,8 @@ from PyQt5.QtGui import QIcon, QPixmap
from PyQt5.QtWidgets import QApplication
from hscommon.trans import install_gettext_trans_under_qt
from qtlib.error_report_dialog import install_excepthook
from qtlib.util import setup_qt_logging
from qt.error_report_dialog import install_excepthook
from qt.util import setup_qt_logging
from qt.preferences import create_qsettings
from qt import dg_rc # noqa: F401
from qt.platform import BASE_PATH