qtquick: Add "Close All" option in the example
This commit is contained in:
@@ -36,6 +36,13 @@ ApplicationWindow {
|
||||
}
|
||||
}
|
||||
|
||||
Action {
|
||||
text: qsTr("Close All")
|
||||
onTriggered: {
|
||||
_kddwDockRegistry.clear();
|
||||
}
|
||||
}
|
||||
|
||||
MenuSeparator { }
|
||||
Action { text: qsTr("&Quit")
|
||||
onTriggered: {
|
||||
|
||||
@@ -137,7 +137,7 @@ public:
|
||||
* This is called before restoring a layout.
|
||||
* @param affinities if specified only closes dock widgets and main windows with the specified affinities
|
||||
*/
|
||||
void clear(const QStringList &affinities = {});
|
||||
Q_INVOKABLE void clear(const QStringList &affinities = {});
|
||||
|
||||
/**
|
||||
* @brief clear Overload that only clears the specified dockWidgets and main windows.
|
||||
|
||||
Reference in New Issue
Block a user