47
47
class FLAKE_EXPORT KoEventAction
50
KoEventAction(const QString & id);
51
54
virtual ~KoEventAction();
53
const QString & id() const;
55
virtual bool loadOdf(const KoXmlElement & element, KoShapeLoadingContext &context) = 0;
56
virtual void saveOdf(KoShapeSavingContext & context) const = 0;
58
virtual void execute(KoTool * tool) = 0;
59
virtual void finish(KoTool * tool) = 0;
57
* Set The id of the action
59
* @param id this is the value that is used for storing the event action in odf.
61
void setId(const QString &id);
64
* The id of the action
66
* The id is the value that is used for storing the event action in odf.
71
* Load action from ODF.
73
* @param context the KoShapeLoadingContext used for loading
74
* @param element element which represents the shape in odf
76
* @return false if loading failed
78
virtual bool loadOdf(const KoXmlElement &element, KoShapeLoadingContext &context) = 0;
81
* Store the action as ODF.
83
* @param context The KoShapeSavingContext used for saving
85
virtual void saveOdf(KoShapeSavingContext &context) const = 0;
90
virtual void start() = 0;
94
* If the action takes some time to finish it can bs stoped with
95
* this method before its end.
97
virtual void finish() {}