Skip to content

Commit

Permalink
Setter for Modified attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
yorikvanhavre authored and wwmayer committed Apr 2, 2024
1 parent 57eeb02 commit 988e867
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Gui/DocumentPy.xml
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ obj : Gui.ViewProvider</UserDocu>
</Documentation>
<Parameter Name="Transacting" Type="Boolean" />
</Attribute>
<Attribute Name="Modified" ReadOnly="true">
<Attribute Name="Modified">
<Documentation>
<UserDocu>Returns True if the document is marked as modified, and False otherwise.</UserDocu>
</Documentation>
Expand Down
5 changes: 5 additions & 0 deletions src/Gui/DocumentPyImp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -504,6 +504,11 @@ Py::Boolean DocumentPy::getModified() const
return {getDocumentPtr()->isModified()};
}

void DocumentPy::setModified(Py::Boolean arg)
{
getDocumentPtr()->setModified(arg);
}

PyObject *DocumentPy::getCustomAttributes(const char* attr) const
{
// Note: Here we want to return only a document object if its
Expand Down

0 comments on commit 988e867

Please sign in to comment.