[TD]fix update suppression logic
This commit is contained in:
committed by
WandererFan
parent
e7df102e22
commit
aa4ba37a6c
@@ -321,12 +321,7 @@ void DrawPage::requestPaint(void)
|
||||
//this doesn't work right because there is no guaranteed of the restoration order
|
||||
void DrawPage::onDocumentRestored()
|
||||
{
|
||||
if (GlobalUpdateDrawings() &&
|
||||
KeepUpdated.getValue()) {
|
||||
updateAllViews();
|
||||
} else if (!GlobalUpdateDrawings() &&
|
||||
AllowPageOverride() &&
|
||||
KeepUpdated.getValue()) {
|
||||
if (canUpdate()) {
|
||||
updateAllViews();
|
||||
}
|
||||
|
||||
@@ -469,6 +464,20 @@ void DrawPage::handleChangedPropertyType(
|
||||
}
|
||||
}
|
||||
|
||||
bool DrawPage::canUpdate() const
|
||||
{
|
||||
bool result = false;
|
||||
if (GlobalUpdateDrawings() &&
|
||||
KeepUpdated.getValue()) {
|
||||
result = true;
|
||||
} else if (!GlobalUpdateDrawings() &&
|
||||
AllowPageOverride() &&
|
||||
KeepUpdated.getValue()) {
|
||||
result = true;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
//allow/prevent drawing updates for all Pages
|
||||
bool DrawPage::GlobalUpdateDrawings(void)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user