File indexing completed on 2024-05-12 15:56:41

0001 /* This file is part of the KDE project
0002    SPDX-FileCopyrightText: 2009 Thorsten Zachmann <zachmann@kde.org>
0003 
0004    SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #ifndef KOLOADINGSHAPEUPDATER_H
0008 #define KOLOADINGSHAPEUPDATER_H
0009 
0010 #include "kritaflake_export.h"
0011 
0012 class KoShape;
0013 
0014 /**
0015  * Reimplement this class when you depend on a shape during loading that is
0016  * not yet loaded.
0017  *
0018  * As soon as the shape you depend on is loaded the method update is called.
0019  * Then you can setup the data you need.
0020  *
0021  * @see KoConnectionShape
0022  * @see KoShapeLoadingContext::updateShape
0023  */
0024 class KRITAFLAKE_EXPORT KoLoadingShapeUpdater
0025 {
0026 public:
0027     KoLoadingShapeUpdater();
0028     virtual ~KoLoadingShapeUpdater();
0029 
0030     /**
0031      * This function is called as soon as shape is loaded.
0032      *
0033      * @param shape The shape that just got loaded.
0034      */
0035     virtual void update(KoShape *shape) = 0;
0036 };
0037 
0038 #endif /* KOLOADINGSHAPEUPDATER_H */