Move dialog source files to their own folder
This commit is contained in:
24 files changed
+1169
-1164
No files matched your search
+277
-278
File diff suppressed because it is too large.
Load diff
+277
-278
File diff suppressed because it is too large.
Load diff
+277
-278
File diff suppressed because it is too large.
Load diff
+277
-278
File diff suppressed because it is too large.
Load diff
+8
-8
@@ -3,28 +3,28 @@ SOURCES += \
|
||||
nw/core/document.py \
|
||||
nw/core/project.py \
|
||||
nw/core/tokenizer.py \
|
||||
nw/gui/about.py \
|
||||
nw/dialogs/about.py \
|
||||
nw/dialogs/docmerge.py \
|
||||
nw/dialogs/docsplit.py \
|
||||
nw/dialogs/itemeditor.py \
|
||||
nw/dialogs/preferences.py \
|
||||
nw/dialogs/projload.py \
|
||||
nw/dialogs/projsettings.py \
|
||||
nw/dialogs/wordlist.py \
|
||||
nw/gui/build.py \
|
||||
nw/gui/custom.py \
|
||||
nw/gui/doceditor.py \
|
||||
nw/gui/docmerge.py \
|
||||
nw/gui/docsplit.py \
|
||||
nw/gui/docviewer.py \
|
||||
nw/gui/itemdetails.py \
|
||||
nw/gui/itemeditor.py \
|
||||
nw/gui/mainmenu.py \
|
||||
nw/gui/noveltree.py \
|
||||
nw/gui/outline.py \
|
||||
nw/gui/outlinedetails.py \
|
||||
nw/gui/preferences.py \
|
||||
nw/gui/projdetails.py \
|
||||
nw/gui/projload.py \
|
||||
nw/gui/projsettings.py \
|
||||
nw/gui/projtree.py \
|
||||
nw/gui/projwizard.py \
|
||||
nw/gui/statusbar.py \
|
||||
nw/gui/theme.py \
|
||||
nw/gui/wordlist.py \
|
||||
nw/gui/writingstats.py \
|
||||
nw/common.py \
|
||||
nw/constants.py \
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from nw.dialogs.about import GuiAbout
|
||||
from nw.dialogs.docmerge import GuiDocMerge
|
||||
from nw.dialogs.docsplit import GuiDocSplit
|
||||
from nw.dialogs.itemeditor import GuiItemEditor
|
||||
from nw.dialogs.preferences import GuiPreferences
|
||||
from nw.dialogs.projload import GuiProjectLoad
|
||||
from nw.dialogs.projsettings import GuiProjectSettings
|
||||
from nw.dialogs.wordlist import GuiWordList
|
||||
|
||||
__all__ = [
|
||||
"GuiAbout",
|
||||
"GuiDocMerge",
|
||||
"GuiDocSplit",
|
||||
"GuiItemEditor",
|
||||
"GuiPreferences",
|
||||
"GuiProjectLoad",
|
||||
"GuiProjectSettings",
|
||||
"GuiWordList",
|
||||
]
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
+1
-17
@@ -1,50 +1,34 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from nw.gui.about import GuiAbout
|
||||
from nw.gui.build import GuiBuildNovel
|
||||
from nw.gui.doceditor import GuiDocEditor
|
||||
from nw.gui.docmerge import GuiDocMerge
|
||||
from nw.gui.docsplit import GuiDocSplit
|
||||
from nw.gui.docviewer import GuiDocViewer, GuiDocViewDetails
|
||||
from nw.gui.itemdetails import GuiItemDetails
|
||||
from nw.gui.itemeditor import GuiItemEditor
|
||||
from nw.gui.mainmenu import GuiMainMenu
|
||||
from nw.gui.noveltree import GuiNovelTree
|
||||
from nw.gui.outline import GuiOutline
|
||||
from nw.gui.outlinedetails import GuiOutlineDetails
|
||||
from nw.gui.preferences import GuiPreferences
|
||||
from nw.gui.projdetails import GuiProjectDetails
|
||||
from nw.gui.projload import GuiProjectLoad
|
||||
from nw.gui.projsettings import GuiProjectSettings
|
||||
from nw.gui.projtree import GuiProjectTree
|
||||
from nw.gui.projwizard import GuiProjectWizard
|
||||
from nw.gui.statusbar import GuiMainStatus
|
||||
from nw.gui.theme import GuiTheme
|
||||
from nw.gui.wordlist import GuiWordList
|
||||
from nw.gui.writingstats import GuiWritingStats
|
||||
|
||||
__all__ = [
|
||||
"GuiAbout",
|
||||
"GuiBuildNovel",
|
||||
"GuiDocEditor",
|
||||
"GuiDocMerge",
|
||||
"GuiDocSplit",
|
||||
"GuiDocViewDetails",
|
||||
"GuiDocViewer",
|
||||
"GuiItemDetails",
|
||||
"GuiItemEditor",
|
||||
"GuiMainMenu",
|
||||
"GuiNovelTree",
|
||||
"GuiMainStatus",
|
||||
"GuiNovelTree",
|
||||
"GuiOutline",
|
||||
"GuiOutlineDetails",
|
||||
"GuiPreferences",
|
||||
"GuiProjectDetails",
|
||||
"GuiProjectLoad",
|
||||
"GuiProjectSettings",
|
||||
"GuiProjectTree",
|
||||
"GuiProjectWizard",
|
||||
"GuiTheme",
|
||||
"GuiWordList",
|
||||
"GuiWritingStats",
|
||||
]
|
||||
+8
-5
@@ -39,11 +39,14 @@ from PyQt5.QtWidgets import (
|
||||
)
|
||||
|
||||
from nw.gui import (
|
||||
GuiAbout, GuiBuildNovel, GuiDocEditor, GuiDocMerge, GuiDocSplit,
|
||||
GuiDocViewDetails, GuiDocViewer, GuiItemDetails, GuiItemEditor,
|
||||
GuiMainMenu, GuiMainStatus, GuiNovelTree, GuiOutline, GuiOutlineDetails,
|
||||
GuiPreferences, GuiProjectDetails, GuiProjectLoad, GuiProjectSettings,
|
||||
GuiProjectTree, GuiProjectWizard, GuiTheme, GuiWordList, GuiWritingStats
|
||||
GuiBuildNovel, GuiDocEditor, GuiDocViewDetails, GuiDocViewer,
|
||||
GuiItemDetails, GuiMainMenu, GuiMainStatus, GuiNovelTree, GuiOutline,
|
||||
GuiOutlineDetails, GuiProjectDetails, GuiProjectTree, GuiProjectWizard,
|
||||
GuiTheme, GuiWritingStats
|
||||
)
|
||||
from nw.dialogs import (
|
||||
GuiAbout, GuiDocMerge, GuiDocSplit, GuiItemEditor, GuiPreferences,
|
||||
GuiProjectLoad, GuiProjectSettings, GuiWordList
|
||||
)
|
||||
from nw.core import NWProject, NWDoc, NWIndex
|
||||
from nw.enum import nwItemType, nwItemClass, nwAlert, nwWidget
|
||||
|
||||
@@ -26,14 +26,14 @@ from tools import getGuiItem
|
||||
|
||||
from PyQt5.QtWidgets import QAction, QMessageBox
|
||||
|
||||
from nw.gui import GuiAbout
|
||||
from nw.dialogs import GuiAbout
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiAbout_Dialog(qtbot, monkeypatch, nwGUI):
|
||||
def testDlgAbout_Dialog(qtbot, monkeypatch, nwGUI):
|
||||
"""Test the full about dialogs.
|
||||
"""
|
||||
# NW About
|
||||
@@ -67,4 +67,4 @@ def testGuiAbout_Dialog(qtbot, monkeypatch, nwGUI):
|
||||
# qtbot.stopForInteraction()
|
||||
msgAbout._doClose()
|
||||
|
||||
# END Test testGuiAbout_Dialog
|
||||
# END Test testDlgAbout_Dialog
|
||||
@@ -28,15 +28,16 @@ from tools import cmpFiles, getGuiItem
|
||||
|
||||
from PyQt5.QtWidgets import QAction, QMessageBox
|
||||
|
||||
from nw.gui import GuiItemEditor, GuiProjectTree
|
||||
from nw.gui import GuiProjectTree
|
||||
from nw.enum import nwItemLayout
|
||||
from nw.dialogs import GuiItemEditor
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiItemEditor_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, refDir, outDir):
|
||||
def testDlgItemEditor_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, refDir, outDir):
|
||||
"""Test the full item editor dialog.
|
||||
"""
|
||||
projFile = os.path.join(fncProj, "nwProject.nwx")
|
||||
@@ -108,4 +109,4 @@ def testGuiItemEditor_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, refDir,
|
||||
|
||||
# qtbot.stopForInteraction()
|
||||
|
||||
# END Test testGuiItemEditor_Dialog
|
||||
# END Test testDlgItemEditor_Dialog
|
||||
@@ -28,14 +28,14 @@ from tools import cmpFiles, getGuiItem
|
||||
|
||||
from PyQt5.QtWidgets import QAction, QMessageBox
|
||||
|
||||
from nw.gui import GuiDocMerge, GuiDocSplit
|
||||
from nw.dialogs import GuiDocMerge, GuiDocSplit
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiMergeSplit_Tools(qtbot, monkeypatch, nwGUI, nwLipsum, refDir, outDir):
|
||||
def testDlgMergeSplit_Tools(qtbot, monkeypatch, nwGUI, nwLipsum, refDir, outDir):
|
||||
"""Test the full merge and split tools.
|
||||
"""
|
||||
# Block message box
|
||||
@@ -182,4 +182,4 @@ def testGuiMergeSplit_Tools(qtbot, monkeypatch, nwGUI, nwLipsum, refDir, outDir)
|
||||
|
||||
# qtbot.stopForInteraction()
|
||||
|
||||
# END Test testGuiMergeSplit_Tools
|
||||
# END Test testDlgMergeSplit_Tools
|
||||
@@ -32,9 +32,9 @@ from PyQt5.QtWidgets import (
|
||||
QDialogButtonBox, QDialog, QAction, QFileDialog, QFontDialog, QMessageBox
|
||||
)
|
||||
|
||||
from nw.gui import GuiPreferences
|
||||
from nw.config import Config
|
||||
from nw.gui.custom import QuotesDialog
|
||||
from nw.dialogs import GuiPreferences
|
||||
from nw.constants import nwConst
|
||||
|
||||
keyDelay = 2
|
||||
@@ -42,7 +42,7 @@ typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiPreferences_Main(qtbot, monkeypatch, fncDir, outDir, refDir):
|
||||
def testDlgPreferences_Main(qtbot, monkeypatch, fncDir, outDir, refDir):
|
||||
"""Test the load project wizard.
|
||||
"""
|
||||
# Block message box
|
||||
@@ -259,4 +259,4 @@ def testGuiPreferences_Main(qtbot, monkeypatch, fncDir, outDir, refDir):
|
||||
|
||||
# qtbot.stopForInteraction()
|
||||
|
||||
# END Test testGuiPreferences_Main
|
||||
# END Test testDlgPreferences_Main
|
||||
@@ -31,14 +31,14 @@ from PyQt5.QtWidgets import (
|
||||
QMessageBox
|
||||
)
|
||||
|
||||
from nw.gui import GuiProjectLoad
|
||||
from nw.dialogs import GuiProjectLoad
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiLoadProject_Main(qtbot, monkeypatch, nwGUI, nwMinimal):
|
||||
def testDlgLoadProject_Main(qtbot, monkeypatch, nwGUI, nwMinimal):
|
||||
"""Test the load project wizard.
|
||||
"""
|
||||
# Block message box
|
||||
@@ -114,4 +114,4 @@ def testGuiLoadProject_Main(qtbot, monkeypatch, nwGUI, nwMinimal):
|
||||
nwLoad.close()
|
||||
# qtbot.stopForInteraction()
|
||||
|
||||
# END Test testGuiLoadProject_Main
|
||||
# END Test testDlgLoadProject_Main
|
||||
+3
-3
@@ -32,14 +32,14 @@ from PyQt5.QtWidgets import (
|
||||
QDialog, QAction, QMessageBox, QColorDialog, QTreeWidgetItem
|
||||
)
|
||||
|
||||
from nw.gui import GuiProjectSettings
|
||||
from nw.dialogs import GuiProjectSettings
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
@pytest.mark.gui
|
||||
def testGuiProjSettings_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, outDir, refDir):
|
||||
def testDlgProjSettings_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, outDir, refDir):
|
||||
"""Test the full project settings dialog.
|
||||
"""
|
||||
projFile = os.path.join(fncProj, "nwProject.nwx")
|
||||
@@ -243,4 +243,4 @@ def testGuiProjSettings_Dialog(qtbot, monkeypatch, nwGUI, fncDir, fncProj, outDi
|
||||
|
||||
# qtbot.stopForInteraction()
|
||||
|
||||
# END Test testGuiProjSettings_Dialog
|
||||
# END Test testDlgProjSettings_Dialog
|
||||
@@ -28,14 +28,14 @@ from PyQt5.QtWidgets import QDialog, QMessageBox, QAction
|
||||
from tools import writeFile, readFile, getGuiItem
|
||||
from dummy import causeOSError
|
||||
|
||||
from nw.gui.wordlist import GuiWordList
|
||||
from nw.dialogs import GuiWordList
|
||||
from nw.constants import nwFiles
|
||||
|
||||
keyDelay = 2
|
||||
typeDelay = 1
|
||||
stepDelay = 20
|
||||
|
||||
def testGuiWordList_Dialog(qtbot, monkeypatch, nwGUI, nwMinimal, tmpDir):
|
||||
def testDlgWordList_Dialog(qtbot, monkeypatch, nwGUI, nwMinimal, tmpDir):
|
||||
"""test the word list editor.
|
||||
"""
|
||||
monkeypatch.setattr(QMessageBox, "question", lambda *args: QMessageBox.Yes)
|
||||
@@ -130,4 +130,4 @@ def testGuiWordList_Dialog(qtbot, monkeypatch, nwGUI, nwMinimal, tmpDir):
|
||||
# qtbot.stopForInteraction()
|
||||
wList._doClose()
|
||||
|
||||
# END Test testGuiWordList_Dialog
|
||||
# END Test testDlgWordList_Dialog
|
||||
@@ -30,7 +30,7 @@ from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QTextCursor
|
||||
from PyQt5.QtWidgets import QAction, QMessageBox, QDialog
|
||||
|
||||
from nw.gui.itemeditor import GuiItemEditor
|
||||
from nw.dialogs.itemeditor import GuiItemEditor
|
||||
from nw.gui.doceditor import GuiDocEditor
|
||||
from nw.gui.projtree import GuiProjectTree
|
||||
from nw.enum import nwItemType, nwDocAction, nwWidget
|
||||
|
||||
Reference in new issue
Block a user