summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorDaniel Bankston <daniel.e.bankston@gmail.com>2012-06-25 01:21:26 -0500
committerKohei Yoshida <kohei.yoshida@gmail.com>2012-07-11 20:37:39 -0400
commitcd2f8a1cabbfb924c62d7af2aac3ac09288c2d4c (patch)
tree2c2e303d4d92a6c3dd4ea1787cc730a19ebbdf65 /sc
parent40732062925db3dff78e8c2d1612e403cb8463f6 (diff)
Stop calculating row heights and instead use imported row heights only
Change-Id: I1a5e33c292fb915e61511efbdb9ce4a0cfd7265f
Diffstat (limited to 'sc')
-rw-r--r--sc/source/filter/xml/xmlimprt.cxx3
-rw-r--r--sc/source/filter/xml/xmlsubti.cxx42
-rw-r--r--sc/source/filter/xml/xmlsubti.hxx1
3 files changed, 1 insertions, 45 deletions
diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx
index 01e1d1cbbe82..4ab81b80ee62 100644
--- a/sc/source/filter/xml/xmlimprt.cxx
+++ b/sc/source/filter/xml/xmlimprt.cxx
@@ -2808,6 +2808,7 @@ throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::R
uno::Reference<document::XActionLockable> xActionLockable(xDoc, uno::UNO_QUERY);
if (xActionLockable.is())
xActionLockable->addActionLock();
+ pDoc->EnableAdjustHeight(false);
}
// XServiceInfo
@@ -3101,8 +3102,6 @@ throw( ::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeE
if (!pSheetData->IsSheetBlocked( nTab ))
pDoc->SetStreamValid( nTab, true );
}
-
- aTables.UpdateRowHeights();
aTables.FixupOLEs();
}
if (GetModel().is())
diff --git a/sc/source/filter/xml/xmlsubti.cxx b/sc/source/filter/xml/xmlsubti.cxx
index 662f278f16f0..7825bbf6ef2b 100644
--- a/sc/source/filter/xml/xmlsubti.cxx
+++ b/sc/source/filter/xml/xmlsubti.cxx
@@ -200,48 +200,6 @@ void ScMyTables::AddColumn(bool bIsCovered)
rImport.GetStylesImportHelper()->InsertCol(maCurrentCellPos.Col(), maCurrentCellPos.Tab(), rImport.GetDocument());
}
-void ScMyTables::UpdateRowHeights()
-{
- if (rImport.GetModel().is())
- {
- ScXMLImport::MutexGuard aGuard(rImport);
-
- // update automatic row heights
-
- // For sheets with any kind of shapes (including notes),
- // update row heights immediately (before setting the positions).
- // For sheets without shapes, set "pending" flag
- // and update row heights when a sheet is shown.
- // The current sheet (from view settings) is always updated immediately.
-
- ScDocument* pDoc = ScXMLConverter::GetScDocument(rImport.GetModel());
- if (pDoc)
- {
- SCTAB nCount = pDoc->GetTableCount();
- ScDrawLayer* pDrawLayer = pDoc->GetDrawLayer();
-
- SCTAB nVisible = rImport.GetVisibleSheet();
-
- ScMarkData aUpdateSheets;
- for (SCTAB nTab=0; nTab<nCount; ++nTab)
- {
- const SdrPage* pPage = pDrawLayer ? pDrawLayer->GetPage(nTab) : NULL;
- if ( nTab == nVisible || ( pPage && pPage->GetObjCount() != 0 ) )
- aUpdateSheets.SelectTable( nTab, true );
- else
- pDoc->SetPendingRowHeights( nTab, true );
- }
-
- if (aUpdateSheets.GetSelectCount())
- {
- pDoc->LockStreamValid( true ); // ignore draw page size (but not formula results)
- ScModelObj::getImplementation(rImport.GetModel())->UpdateAllRowHeights(&aUpdateSheets);
- pDoc->LockStreamValid( false );
- }
- }
- }
-}
-
void ScMyTables::DeleteTable()
{
ScXMLImport::MutexGuard aGuard(rImport);
diff --git a/sc/source/filter/xml/xmlsubti.hxx b/sc/source/filter/xml/xmlsubti.hxx
index 971cb69c598d..3f98af9d95f2 100644
--- a/sc/source/filter/xml/xmlsubti.hxx
+++ b/sc/source/filter/xml/xmlsubti.hxx
@@ -107,7 +107,6 @@ public:
void AddRow();
void SetRowStyle(const rtl::OUString& rCellStyleName);
void AddColumn(bool bIsCovered);
- void UpdateRowHeights();
void FixupOLEs() { aFixupOLEs.FixupOLEs(); }
bool IsOLE(com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& rShape) const
{ return ScMyOLEFixer::IsOLE(rShape); }