[rkward] rkward/misc: Avoid shortcut conflicts with previews

Thomas Friedrichsmeier null at kde.org
Fri Sep 28 21:28:37 BST 2018


Git commit d287f995b45d85205b8922f03c578fc9fac494da by Thomas Friedrichsmeier.
Committed on 28/09/2018 at 20:16.
Pushed by tfry into branch 'master'.

Avoid shortcut conflicts with previews

M  +3    -0    rkward/misc/rkxmlguipreviewarea.cpp

https://commits.kde.org/rkward/d287f995b45d85205b8922f03c578fc9fac494da

diff --git a/rkward/misc/rkxmlguipreviewarea.cpp b/rkward/misc/rkxmlguipreviewarea.cpp
index e95d225a..9384f9a7 100644
--- a/rkward/misc/rkxmlguipreviewarea.cpp
+++ b/rkward/misc/rkxmlguipreviewarea.cpp
@@ -115,6 +115,9 @@ void RKXMLGUIPreviewArea::childEvent (QChildEvent *event) {
 			menuBar ()->hide ();
 			QList<KToolBar*> tbars = toolBars ();
 			for (int i = 0; i < tbars.size (); ++i) tbars[i]->hide ();
+			// avoid shortcut conflicts
+			QList<QAction*> acts = actions ();
+			for (int i = 0; i < acts.size (); ++i) acts[i]->setShortcutContext(Qt::WidgetWithChildrenShortcut);
 		}
 	}
 	QObject::childEvent (event);



More information about the rkward-tracker mailing list