summaryrefslogtreecommitdiff
path: root/src/libs/qmlpuppetcommunication/commands/changepreviewimagesizecommand.h
blob: 68437efff8a5c18fb60aa991ecead36f5dc0b46a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// Copyright (C) 2020 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#pragma once

#include <QMetaType>
#include <QSize>

namespace QmlDesigner {

class ChangePreviewImageSizeCommand
{
public:
    ChangePreviewImageSizeCommand() = default;
    ChangePreviewImageSizeCommand(const QSize &size)
        : size(size)
    {}

    friend QDataStream &operator<<(QDataStream &out, const ChangePreviewImageSizeCommand &command);
    friend QDataStream &operator>>(QDataStream &in, ChangePreviewImageSizeCommand &command);
    friend QDebug operator<<(QDebug debug, const ChangePreviewImageSizeCommand &command);

public:
    QSize size;
};

} // namespace QmlDesigner

Q_DECLARE_METATYPE(QmlDesigner::ChangePreviewImageSizeCommand)