summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Ivan <alexnivan@yahoo.com>2013-07-12 14:29:10 +0300
committerAlex Ivan <alexnivan@yahoo.com>2013-07-12 14:29:10 +0300
commitf05f7f6723dafb90637907c427343478c390158c (patch)
tree599858fc32f53ca018eca3b51280d13502dd1ab7
parent3190a43ec77fc818f7c426743aed443ec08a9ce5 (diff)
Minor fixes
Add const GetTableStyle function to SwTableAutoFmt. Initialize line pointer in Get/SetBoxFmt functions. Change-Id: Ia70fd9e60ced7aaeaacd8be37cec9c65d6ea5594
-rw-r--r--sw/inc/tblafmt.hxx3
-rw-r--r--sw/source/core/doc/swtblfmt.cxx4
2 files changed, 4 insertions, 3 deletions
diff --git a/sw/inc/tblafmt.hxx b/sw/inc/tblafmt.hxx
index a1e59b3a9791..af7b0d61084e 100644
--- a/sw/inc/tblafmt.hxx
+++ b/sw/inc/tblafmt.hxx
@@ -128,7 +128,8 @@ public:
SwTableAutoFmt& operator=( const SwTableAutoFmt& rNew );
- SwTableFmt* GetTableStyle() { return m_pTableStyle; }
+ SwTableFmt* GetTableStyle() const { return m_pTableStyle; }
+ SwTableFmt* GetTableStyle() { return m_pTableStyle; }
void SetBoxFmt( const SwTableBoxFmt& rNew, sal_uInt8 nPos );
SwTableBoxFmt* GetBoxFmt( sal_uInt8 nPos ) const;
diff --git a/sw/source/core/doc/swtblfmt.cxx b/sw/source/core/doc/swtblfmt.cxx
index 5e348e791ecd..67bc68c0fc0a 100644
--- a/sw/source/core/doc/swtblfmt.cxx
+++ b/sw/source/core/doc/swtblfmt.cxx
@@ -110,7 +110,7 @@ void SwTableFmt::SetBoxFmt( const SwTableBoxFmt& rNew, sal_uInt8 nPos )
sal_uInt8 nLine = nPos / 4;
sal_uInt8 nBox = nPos % 4;
- SwTableLineFmt* pLine;
+ SwTableLineFmt* pLine = 0;
switch( nLine )
{
@@ -145,7 +145,7 @@ SwTableBoxFmt* SwTableFmt::GetBoxFmt( sal_uInt8 nPos ) const
sal_uInt8 nLine = nPos / 4;
sal_uInt8 nBox = nPos % 4;
- SwTableLineFmt* pLine;
+ SwTableLineFmt* pLine = 0;
SwTableBoxFmt* pRet;
switch( nLine )