25#include "pencilerror.h"
38 int pos()
const {
return mFrame; }
39 void setPos(
int position) { mFrame = position; }
41 int length()
const {
return mLength; }
42 void setLength(
int len) { mLength = len; }
44 void modification() { mIsModified =
true; }
45 void setModified(
bool b) { mIsModified = b; }
46 bool isModified()
const {
return mIsModified; }
48 QString fileName()
const {
return mAttachedFileName; }
49 void setFileName(
QString strFileName) { mAttachedFileName = strFileName; }
54 virtual KeyFrame* clone()
const {
return nullptr; }
64 virtual bool isLoaded()
const {
return false; }
66 virtual quint64 memoryUsage() {
return 0; }
71 bool mIsModified =
true;
74 std::vector<KeyFrameEventListener*> mEventListeners;
80 virtual void onKeyFrameDestroy(
KeyFrame*) = 0;
virtual bool isLoaded() const
A check to ensure that the keyframe holds valid data.
virtual void unloadFile()
Unloads the data from memory in order to save memory.
virtual void loadFile()
Loads the backing file into memory if it exists, otherwise it does nothing.