KDStateMachineEditor API Documentation  1.2.50
editcontroller.h
1 /*
2  This file is part of the KDAB State Machine Editor Library.
3 
4  SPDX-FileCopyrightText: 2014-2021 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
5  Author: Kevin Funk <kevin.funk@kdab.com>
6 
7  SPDX-License-Identifier: LGPL-2.1-only OR LicenseRef-KDAB-KDStateMachineEditor
8 
9  Licensees holding valid commercial KDAB State Machine Editor Library
10  licenses may use this file in accordance with the KDAB State Machine Editor
11  Library License Agreement provided with the Software.
12 
13  Contact info@kdab.com if any conditions of this licensing are not clear to you.
14 */
15 
16 #ifndef KDSME_EDITCONTROLLER_H
17 #define KDSME_EDITCONTROLLER_H
18 
19 #include "kdsme_view_export.h"
20 
21 #include "abstractcontroller.h"
22 
23 namespace KDSME {
24 
25 class Element;
26 
27 class KDSME_VIEW_EXPORT EditController : public AbstractController
28 {
29  Q_OBJECT
30  Q_PROPERTY(bool editModeEnabled READ editModeEnabled WRITE setEditModeEnabled NOTIFY editModeEnabledChanged)
31 
32 public:
33  explicit EditController(StateMachineView* parent = nullptr);
34  ~EditController();
35 
36  bool editModeEnabled() const;
37  void setEditModeEnabled(bool editModeEnabled);
38 
39 public Q_SLOTS:
40  bool sendDragEnterEvent(KDSME::Element* sender, KDSME::Element* target, const QPoint& pos, const QList<QUrl>& urls);
41  bool sendDropEvent(KDSME::Element* sender, KDSME::Element* target, const QPoint& pos, const QList<QUrl>& urls);
42 
43 Q_SIGNALS:
44  void editModeEnabledChanged(bool editModeEnabled);
45 
46 private:
47  struct Private;
49 };
50 
51 }
52 
53 #endif // EDITCONTROLLER_H
Widget for displaying a KDSME::StateMachine in a Qt Quick based view.
Definition: statemachineview.h:39
Definition: abstractcontroller.h:27
Definition: element.h:34
Definition: editcontroller.h:27
Definition: mainwindow.h:21

Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
KDStateMachineEditor
Create Qt State Machine metacode using a graphical user interface
https://github.com/KDAB/KDStateMachineEditor