Merge branch 'main' into dialogue_highlight
This commit is contained in:
@@ -30,7 +30,7 @@ from novelwriter import CONFIG, SHARED
|
||||
from novelwriter.core.toqdoc import ToQTextDocument
|
||||
from novelwriter.enum import nwDocAction
|
||||
from novelwriter.gui.docviewer import GuiDocViewer
|
||||
from novelwriter.types import QtModeNone, QtMouseLeft
|
||||
from novelwriter.types import QtModNone, QtMouseLeft
|
||||
|
||||
from tests.mocked import causeException
|
||||
|
||||
@@ -61,7 +61,7 @@ def testGuiViewer_Main(qtbot, monkeypatch, nwGUI, prjLipsum):
|
||||
|
||||
# Re-select via header click
|
||||
button = QtMouseLeft
|
||||
modifier = QtModeNone
|
||||
modifier = QtModNone
|
||||
event = QMouseEvent(QEvent.Type.MouseButtonPress, QPoint(), button, button, modifier)
|
||||
docViewer.docHeader.mousePressEvent(event)
|
||||
assert nwGUI.projView.projTree.getSelectedHandle() == "88243afbe5ed8"
|
||||
|
||||
@@ -400,7 +400,7 @@ def testGuiMainMenu_Insert(qtbot, monkeypatch, nwGUI, fncPath, projPath, mockRnd
|
||||
nwGUI.docEditor.clear()
|
||||
|
||||
nwGUI.mainMenu.aInsMSApos.activate(QAction.Trigger)
|
||||
assert nwGUI.docEditor.getText() == nwUnicode.U_MAPOSS
|
||||
assert nwGUI.docEditor.getText() == nwUnicode.U_MAPOS
|
||||
nwGUI.docEditor.clear()
|
||||
|
||||
nwGUI.mainMenu.aInsEllipsis.activate(QAction.Trigger)
|
||||
|
||||
@@ -37,7 +37,7 @@ from novelwriter.dialogs.editlabel import GuiEditLabel
|
||||
from novelwriter.enum import nwItemClass, nwItemLayout, nwItemType, nwWidget
|
||||
from novelwriter.gui.projtree import GuiProjectTree, GuiProjectView, _TreeContextMenu
|
||||
from novelwriter.guimain import GuiMain
|
||||
from novelwriter.types import QtAccepted, QtModeNone, QtMouseLeft, QtMouseMiddle, QtRejected
|
||||
from novelwriter.types import QtAccepted, QtModNone, QtMouseLeft, QtMouseMiddle, QtRejected
|
||||
|
||||
from tests.mocked import causeOSError
|
||||
from tests.tools import C, buildTestProject
|
||||
@@ -807,7 +807,7 @@ def testGuiProjTree_AutoScroll(qtbot, monkeypatch, nwGUI: GuiMain, projPath, moc
|
||||
action = Qt.DropAction.MoveAction
|
||||
mime = QMimeData()
|
||||
mouse = QtMouseLeft
|
||||
modifier = QtModeNone
|
||||
modifier = QtModNone
|
||||
|
||||
# Scroll Down
|
||||
h = projTree.height()
|
||||
@@ -864,7 +864,7 @@ def testGuiProjTree_DragAndDrop(qtbot, monkeypatch, caplog, nwGUI: GuiMain, proj
|
||||
action = Qt.DropAction.MoveAction
|
||||
mime = QMimeData()
|
||||
mouse = QtMouseLeft
|
||||
modifier = QtModeNone
|
||||
modifier = QtModNone
|
||||
|
||||
projTree.saveTreeOrder()
|
||||
treeOrder = SHARED.project.tree._order
|
||||
@@ -1064,7 +1064,7 @@ def testGuiProjTree_Other(qtbot, monkeypatch, nwGUI: GuiMain, projPath, mockRnd)
|
||||
eType = QEvent.Type.MouseButtonPress
|
||||
pos = projTree.visualItemRect(projTree._getTreeItem(C.hChapterDoc)).center()
|
||||
button = QtMouseMiddle
|
||||
modifier = QtModeNone
|
||||
modifier = QtModNone
|
||||
|
||||
# Trigger the viewer
|
||||
event = QMouseEvent(eType, pos, button, button, modifier)
|
||||
|
||||
Reference in New Issue
Block a user