Commit 197cbcca authored by Halla Rempt's avatar Halla Rempt
Browse files

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

BUG:425066
parent 29cb9179
Pipeline #234427 canceled with stage
in 9 minutes and 32 seconds
......@@ -927,6 +927,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();
......
......@@ -796,6 +796,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
......
......@@ -88,6 +88,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