summaryrefslogtreecommitdiffstats
path: root/src/document.h
diff options
context:
space:
mode:
authorMenTaLguY <mental@rydia.net>2008-01-15 05:08:28 +0000
committermental <mental@users.sourceforge.net>2008-01-15 05:08:28 +0000
commite50d63f42224cdafece30d78265fb22482fd49d4 (patch)
tree2b292247e0809a34e169478ea94ad9b2947b51d8 /src/document.h
parentabstract use of sodipodi:modified (diff)
downloadinkscape-e50d63f42224cdafece30d78265fb22482fd49d4.tar.gz
inkscape-e50d63f42224cdafece30d78265fb22482fd49d4.zip
stop toggling insensitive state for modification flag updates (fixes critical bug #182401)
In order to do this, I got rid of sodipodi:modified in favor of a simple flag in SPDocument, also renaming SPDocument::{set,is}Modified to SPDocument::{set,is}ModifiedSinceSave (bzr r4491)
Diffstat (limited to 'src/document.h')
-rw-r--r--src/document.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/document.h b/src/document.h
index 6c9ea570d..8a4e65bb3 100644
--- a/src/document.h
+++ b/src/document.h
@@ -81,6 +81,7 @@ struct SPDocument : public Inkscape::GC::Managed<>,
unsigned int keepalive : 1;
unsigned int virgin : 1; ///< Has the document never been touched?
+ unsigned int modified_since_save : 1;
Inkscape::XML::Document *rdoc; ///< Our Inkscape::XML::Document
Inkscape::XML::Node *rroot; ///< Root element of Inkscape::XML::Document
@@ -140,8 +141,10 @@ sigc::connection connectCommit(CommitSignal::slot_type slot);
/// Are we currently in a transition between two "known good" states of the document?
bool isSeeking() const;
- bool isModified() const;
- void setModified(bool modified=true);
+ bool isModifiedSinceSave() const { return modified_since_save; }
+ void setModifiedSinceSave(bool modified=true) {
+ modified_since_save = modified;
+ }
private:
SPDocument(SPDocument const &); // no copy