fuzzer: Also serialize the AddDockWidget operation
This commit is contained in:
@@ -25,12 +25,15 @@
|
||||
#define KDDOCKWIDGETS_TESTING_H
|
||||
|
||||
#include "KDDockWidgets.h"
|
||||
#include "MainWindowBase.h"
|
||||
#include "DockWidgetBase.h"
|
||||
|
||||
#include <QSize>
|
||||
#include <QRect>
|
||||
#include <QVector>
|
||||
#include <QEvent>
|
||||
#include <QWidget>
|
||||
#include <QVariant>
|
||||
|
||||
/**
|
||||
* @file
|
||||
@@ -38,6 +41,8 @@
|
||||
*/
|
||||
|
||||
namespace KDDockWidgets {
|
||||
|
||||
|
||||
namespace Testing {
|
||||
|
||||
class WarningObserver
|
||||
@@ -46,6 +51,30 @@ namespace Testing {
|
||||
virtual void onFatal() = 0;
|
||||
};
|
||||
|
||||
struct AddDockWidgetParams {
|
||||
MainWindowBase *mainWindow;
|
||||
DockWidgetBase *dockWidget;
|
||||
DockWidgetBase *relativeTo;
|
||||
KDDockWidgets::Location location;
|
||||
KDDockWidgets::AddingOption addingOption;
|
||||
|
||||
QVariantMap toVariantMap() const
|
||||
{
|
||||
QVariantMap map;
|
||||
map["mainWindowName"] = mainWindow->uniqueName();
|
||||
map["dockWidgetName"] = dockWidget->uniqueName();
|
||||
|
||||
if (relativeTo)
|
||||
map["relativeToName"] = relativeTo->uniqueName();
|
||||
|
||||
map["location"] = location;
|
||||
map["addingOption"] = addingOption;
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
void setWarningObserver(WarningObserver *);
|
||||
|
||||
void installFatalMessageHandler();
|
||||
|
||||
Reference in New Issue
Block a user