diff options
author | Eike Rathke <erack@redhat.com> | 2015-09-04 20:07:16 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2015-09-04 21:14:43 +0200 |
commit | 0d5645f4fa069677b404899f126bd57e3035fd9b (patch) | |
tree | 79fb572763c2c6d39aa145c5939553fa0d08d961 /sc | |
parent | 757996aa2879a2ea850055bafa60edb66548dffd (diff) |
TableRef: add an initial dirty range for newly inserted ScDBData
... so table column names get updated in the next run.
Change-Id: I998d610a3df14fb80b6222fd1a5b61847810a722
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/tool/dbdata.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sc/source/core/tool/dbdata.cxx b/sc/source/core/tool/dbdata.cxx index 1b98b0050884..252f5c571177 100644 --- a/sc/source/core/tool/dbdata.cxx +++ b/sc/source/core/tool/dbdata.cxx @@ -1042,6 +1042,13 @@ ScDBCollection::NamedDBs::NamedDBs(const NamedDBs& r) { p->SetContainer( this); p->StartTableColumnNamesListener(); // needs the container be set already + if (p->AreTableColumnNamesDirty()) + { + // Refresh table column names in next round. + ScRange aHeader( p->GetHeaderArea()); + if (aHeader.IsValid()) + maDirtyTableColumnNames.Join( aHeader); + } } } } @@ -1102,6 +1109,13 @@ bool ScDBCollection::NamedDBs::insert(ScDBData* p) { p->SetContainer( this); p->StartTableColumnNamesListener(); // needs the container be set already + if (p->AreTableColumnNamesDirty()) + { + // Refresh table column names in next round. + ScRange aHeader( p->GetHeaderArea()); + if (aHeader.IsValid()) + maDirtyTableColumnNames.Join( aHeader); + } /* TODO: shouldn't the import refresh not be setup for * clipboard/undo documents? It was already like this before.. */ |