diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-03-28 12:30:11 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-03-28 13:08:59 +0100 |
commit | 38814653ba6b76a6d6b4603c037cb52e0be300e8 (patch) | |
tree | 474d8e7e432a0428737bac9647347c126ff53fe5 /svx | |
parent | when run under memcheck allow SIGUSR2 to dump current memory allocations (diff) | |
download | core-38814653ba6b76a6d6b4603c037cb52e0be300e8.tar.gz core-38814653ba6b76a6d6b4603c037cb52e0be300e8.zip |
remove static OUStrings from static_initialization_and_destruction chain
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/fmcomp/gridcell.cxx | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx index 66c51c313dd9..f807cccdfedd 100644 --- a/svx/source/fmcomp/gridcell.cxx +++ b/svx/source/fmcomp/gridcell.cxx @@ -92,9 +92,8 @@ using namespace ::com::sun::star::form; using ::com::sun::star::util::XNumberFormatter; namespace MouseWheelBehavior = ::com::sun::star::awt::MouseWheelBehavior; -String INVALIDTEXT = String::CreateFromAscii("###"); -String OBJECTTEXT = String::CreateFromAscii("<OBJECT>"); - // TODO: resource +const char INVALIDTEXT[] = "###"; +const char OBJECTTEXT[] = "<OBJECT>"; //================================================================== //= helper @@ -423,7 +422,7 @@ String DbGridColumn::GetCellText(const DbGridRow* pRow, const Reference< XNumber return aText; if (!pRow || !pRow->IsValid()) - aText = INVALIDTEXT; + aText = rtl::OUString(INVALIDTEXT); else if (pRow->HasField(m_nFieldPos)) { aText = GetCellText( pRow->GetField( m_nFieldPos ).getColumn(), xFormatter ); @@ -441,7 +440,7 @@ String DbGridColumn::GetCellText(const Reference< ::com::sun::star::sdb::XColumn if (pTextCell) aText = pTextCell->GetText(xField, xFormatter); else if (m_bObject) - aText = OBJECTTEXT; + aText = rtl::OUString(OBJECTTEXT); } return aText; } @@ -476,7 +475,7 @@ void DbGridColumn::Paint(OutputDevice& rDev, if ( !bEnabled ) nStyle |= TEXT_DRAW_DISABLE; - rDev.DrawText(rRect, INVALIDTEXT, nStyle); + rDev.DrawText(rRect, rtl::OUString(INVALIDTEXT), nStyle); } else if (m_bAutoValue && pRow->IsNew()) { @@ -512,14 +511,14 @@ void DbGridColumn::Paint(OutputDevice& rDev, if ( !bEnabled ) nStyle |= TEXT_DRAW_DISABLE; - rDev.DrawText(rRect, INVALIDTEXT, nStyle); + rDev.DrawText(rRect, rtl::OUString(INVALIDTEXT), nStyle); } else if (pRow->HasField(m_nFieldPos) && m_bObject) { sal_uInt16 nStyle = TEXT_DRAW_CLIP | TEXT_DRAW_CENTER; if ( !bEnabled ) nStyle |= TEXT_DRAW_DISABLE; - rDev.DrawText(rRect, OBJECTTEXT, nStyle); + rDev.DrawText(rRect, rtl::OUString(OBJECTTEXT), nStyle); } } else if ( m_pCell->ISA( FmXFilterCell ) ) |