Commit dae80193 authored by Halla Rempt's avatar Halla Rempt
Browse files

Add Document::setModified(bool) to the scripting api

BUG:425066
(cherry picked from commit 78aedaf4b49bbfdda4473b187f5026d4de43908b)
parent de6a3701
......@@ -902,6 +902,12 @@ bool Document::modified() const
return d->document->isModified();
}
void Document::setModified(bool modified)
{
if (!d->document) return;
d->document->setModified(modified);
}
QRect Document::bounds() const
{
if (!d->document) return QRect();
......
......@@ -778,6 +778,12 @@ print(root.childNodes())
*/
bool modified() const;
/**
* @brief setModified sets the modified status of the document
* @param modified if true, the document is considered modified and closing it will ask for saving.
*/
void setModified(bool modified);
/**
* @brief bounds return the bounds of the image
* @return the bounds
......
......@@ -84,6 +84,7 @@ public Q_SLOTS:
void setGuidesVisible(bool visible);
void setGuidesLocked(bool locked);
bool modified() const;
void setModified(bool modified);
QRect bounds() const;
bool importAnimation(const QList<QString> &files, int firstFrame, int step);
int framesPerSecond();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment