diff options
Diffstat (limited to 'include/svtools/valueset.hxx')
-rw-r--r-- | include/svtools/valueset.hxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/svtools/valueset.hxx b/include/svtools/valueset.hxx index 6804a9622c90..7bd827eca220 100644 --- a/include/svtools/valueset.hxx +++ b/include/svtools/valueset.hxx @@ -421,6 +421,7 @@ private: long mnUserItemWidth; long mnUserItemHeight; sal_uInt16 mnSelItemId; + int mnSavedItemId; sal_uInt16 mnHighItemId; sal_uInt16 mnCols; sal_uInt16 mnCurCol; @@ -581,6 +582,17 @@ public: return mbEdgeBlending; } void SetEdgeBlending(bool bNew); + + void SaveValue() + { + mnSavedItemId = IsNoSelection() ? -1 : GetSelectedItemId(); + } + + bool IsValueChangedFromSaved() const + { + int nItemId = IsNoSelection() ? -1 : GetSelectedItemId(); + return mnSavedItemId != nItemId; + } }; |