diff --git a/hscommon/desktop.py b/hscommon/desktop.py index c468ccaa..01b2b7c0 100644 --- a/hscommon/desktop.py +++ b/hscommon/desktop.py @@ -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 diff --git a/qtlib/images/search_clear_13.png b/images/search_clear_13.png similarity index 100% rename from qtlib/images/search_clear_13.png rename to images/search_clear_13.png diff --git a/qtlib/about_box.py b/qt/about_box.py similarity index 97% rename from qtlib/about_box.py rename to qt/about_box.py index 1725f5e1..2103d299 100644 --- a/qtlib/about_box.py +++ b/qt/about_box.py @@ -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): diff --git a/qt/app.py b/qt/app.py index e5aaaf99..8cc22133 100644 --- a/qt/app.py +++ b/qt/app.py @@ -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 diff --git a/qtlib/column.py b/qt/column.py similarity index 100% rename from qtlib/column.py rename to qt/column.py diff --git a/qt/deletion_options.py b/qt/deletion_options.py index ab879adb..2f4ef1b6 100644 --- a/qt/deletion_options.py +++ b/qt/deletion_options.py @@ -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") diff --git a/qt/details_dialog.py b/qt/details_dialog.py index 28f5ab21..a4d467bc 100644 --- a/qt/details_dialog.py +++ b/qt/details_dialog.py @@ -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 diff --git a/qt/dg.qrc b/qt/dg.qrc index 7b2846bf..d432eb44 100644 --- a/qt/dg.qrc +++ b/qt/dg.qrc @@ -4,7 +4,7 @@ ../images/dgse_logo_128.png ../images/plus_8.png ../images/minus_8.png - ../qtlib/images/search_clear_13.png + ../images/search_clear_13.png ../images/exchange_purple_upscaled.png ../images/old_zoom_in.png ../images/old_zoom_out.png diff --git a/qt/directories_dialog.py b/qt/directories_dialog.py index 82b3f1f2..f802c63e 100644 --- a/qt/directories_dialog.py +++ b/qt/directories_dialog.py @@ -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 diff --git a/qt/directories_model.py b/qt/directories_model.py index adb6d79f..29ca8cc7 100644 --- a/qt/directories_model.py +++ b/qt/directories_model.py @@ -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") diff --git a/qtlib/error_report_dialog.py b/qt/error_report_dialog.py similarity index 98% rename from qtlib/error_report_dialog.py rename to qt/error_report_dialog.py index 927a65b7..55b5bd19 100644 --- a/qtlib/error_report_dialog.py +++ b/qt/error_report_dialog.py @@ -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): diff --git a/qt/exclude_list_table.py b/qt/exclude_list_table.py index bcbf13bc..f07d8cf0 100644 --- a/qt/exclude_list_table.py +++ b/qt/exclude_list_table.py @@ -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") diff --git a/qt/ignore_list_dialog.py b/qt/ignore_list_dialog.py index 62fc2137..94abe1d0 100644 --- a/qt/ignore_list_dialog.py +++ b/qt/ignore_list_dialog.py @@ -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") diff --git a/qt/ignore_list_table.py b/qt/ignore_list_table.py index 92665371..908d93a6 100644 --- a/qt/ignore_list_table.py +++ b/qt/ignore_list_table.py @@ -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): diff --git a/qt/me/results_model.py b/qt/me/results_model.py index 7c9c979d..085195d9 100644 --- a/qt/me/results_model.py +++ b/qt/me/results_model.py @@ -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 diff --git a/qt/pe/preferences_dialog.py b/qt/pe/preferences_dialog.py index 1a246637..79dc0120 100644 --- a/qt/pe/preferences_dialog.py +++ b/qt/pe/preferences_dialog.py @@ -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 diff --git a/qt/pe/results_model.py b/qt/pe/results_model.py index 836cd4b9..40e8e61c 100644 --- a/qt/pe/results_model.py +++ b/qt/pe/results_model.py @@ -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 diff --git a/qt/preferences_dialog.py b/qt/preferences_dialog.py index 60760caf..6e2999ae 100644 --- a/qt/preferences_dialog.py +++ b/qt/preferences_dialog.py @@ -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 diff --git a/qt/prioritize_dialog.py b/qt/prioritize_dialog.py index 8c6a19bc..d63778fb 100644 --- a/qt/prioritize_dialog.py +++ b/qt/prioritize_dialog.py @@ -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") diff --git a/qt/problem_dialog.py b/qt/problem_dialog.py index 8cbe155d..522c76aa 100644 --- a/qt/problem_dialog.py +++ b/qt/problem_dialog.py @@ -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 diff --git a/qt/problem_table.py b/qt/problem_table.py index 72648d9e..9e8a3515 100644 --- a/qt/problem_table.py +++ b/qt/problem_table.py @@ -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): diff --git a/qtlib/progress_window.py b/qt/progress_window.py similarity index 100% rename from qtlib/progress_window.py rename to qt/progress_window.py diff --git a/qtlib/radio_box.py b/qt/radio_box.py similarity index 98% rename from qtlib/radio_box.py rename to qt/radio_box.py index 752bb07c..f59ba7e9 100644 --- a/qtlib/radio_box.py +++ b/qt/radio_box.py @@ -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): diff --git a/qtlib/recent.py b/qt/recent.py similarity index 98% rename from qtlib/recent.py rename to qt/recent.py index 33f95fd7..1364f30d 100644 --- a/qtlib/recent.py +++ b/qt/recent.py @@ -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") diff --git a/qt/result_window.py b/qt/result_window.py index 0fc47eb3..266c63e2 100644 --- a/qt/result_window.py +++ b/qt/result_window.py @@ -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 diff --git a/qt/results_model.py b/qt/results_model.py index 2d5055bd..54fb9c1f 100644 --- a/qt/results_model.py +++ b/qt/results_model.py @@ -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): diff --git a/qt/se/results_model.py b/qt/se/results_model.py index c88de9eb..ce580ad4 100644 --- a/qt/se/results_model.py +++ b/qt/se/results_model.py @@ -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 diff --git a/qtlib/search_edit.py b/qt/search_edit.py similarity index 99% rename from qtlib/search_edit.py rename to qt/search_edit.py index e7ecb6c2..16d7d637 100644 --- a/qtlib/search_edit.py +++ b/qt/search_edit.py @@ -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. diff --git a/qtlib/selectable_list.py b/qt/selectable_list.py similarity index 100% rename from qtlib/selectable_list.py rename to qt/selectable_list.py diff --git a/qt/tabbed_window.py b/qt/tabbed_window.py index 750a95a1..aabbaa86 100644 --- a/qt/tabbed_window.py +++ b/qt/tabbed_window.py @@ -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 diff --git a/qtlib/table.py b/qt/table.py similarity index 100% rename from qtlib/table.py rename to qt/table.py diff --git a/qtlib/tree_model.py b/qt/tree_model.py similarity index 100% rename from qtlib/tree_model.py rename to qt/tree_model.py diff --git a/qtlib/util.py b/qt/util.py similarity index 100% rename from qtlib/util.py rename to qt/util.py diff --git a/qtlib/LICENSE b/qtlib/LICENSE deleted file mode 100644 index 5a8d3ceb..00000000 --- a/qtlib/LICENSE +++ /dev/null @@ -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. \ No newline at end of file diff --git a/qtlib/__init__.py b/qtlib/__init__.py deleted file mode 100644 index e69de29b..00000000 diff --git a/run.py b/run.py index 0d7ff851..1c286235 100644 --- a/run.py +++ b/run.py @@ -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