diff options
author | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-03-05 11:32:59 +0100 |
---|---|---|
committer | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-03-05 11:32:59 +0100 |
commit | ba4b0d6185953c735607ed69c0f70e91e2aa60de (patch) | |
tree | 0180cfcf8610ee1069da7a512e31b5189f4261e1 /svtools/workben/toolpanel | |
parent | d068a1234eff68772943dd8b60d3de28a4d06cc6 (diff) |
slidecopy: introduced TABITEM_AUTO value for TabItemContent, do the automatic adjustment of the tab's contents only when this is set, in all other cases, do not tamper with what our client gave us.
Diffstat (limited to 'svtools/workben/toolpanel')
-rw-r--r-- | svtools/workben/toolpanel/toolpaneltest.cxx | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/svtools/workben/toolpanel/toolpaneltest.cxx b/svtools/workben/toolpanel/toolpaneltest.cxx index 68deeeb7739e..f0e12962d1fd 100644 --- a/svtools/workben/toolpanel/toolpaneltest.cxx +++ b/svtools/workben/toolpanel/toolpaneltest.cxx @@ -234,6 +234,7 @@ private: RadioButton m_aImagesAndText; RadioButton m_aImagesOnly; RadioButton m_aTextOnly; + RadioButton m_aAutomaticContent; }; //============================================================================= @@ -274,6 +275,7 @@ OptionsWindow::OptionsWindow( PanelDemoMainWindow& i_rParent ) ,m_aImagesAndText( this ) ,m_aImagesOnly( this ) ,m_aTextOnly( this ) + ,m_aAutomaticContent( this ) { SetBorderStyle( WINDOW_BORDER_MONO ); const Color aFaceColor( GetSettings().GetStyleSettings().GetFaceColor() ); @@ -281,11 +283,12 @@ OptionsWindow::OptionsWindow( PanelDemoMainWindow& i_rParent ) Window* pControls[] = { - &m_aAlignmentHeader, &m_aAlignLeft, &m_aAlignRight, &m_aTabItemContent, &m_aImagesAndText, &m_aImagesOnly, &m_aTextOnly + &m_aAlignmentHeader, &m_aAlignLeft, &m_aAlignRight, &m_aTabItemContent, &m_aImagesAndText, &m_aImagesOnly, + &m_aTextOnly, &m_aAutomaticContent }; const sal_Char* pTexts[] = { - "Tab Bar Alignment", "Left", "Right", "Tab Items", "Images and Text", "Images only", "Text only" + "Tab Bar Alignment", "Left", "Right", "Tab Items", "Images and Text", "Images only", "Text only", "Automatic" }; for ( size_t i=0; i < sizeof( pControls ) / sizeof( pControls[0] ); ++i ) { @@ -348,13 +351,14 @@ void OptionsWindow::Resize() }; ControlRow aControlRows[] = { - ControlRow( m_aAlignmentHeader, false ), - ControlRow( m_aAlignLeft, true ), - ControlRow( m_aAlignRight, true ), - ControlRow( m_aTabItemContent, false ), - ControlRow( m_aImagesAndText, true ), - ControlRow( m_aImagesOnly, true ), - ControlRow( m_aTextOnly, true ) + ControlRow( m_aAlignmentHeader, false ), + ControlRow( m_aAlignLeft, true ), + ControlRow( m_aAlignRight, true ), + ControlRow( m_aTabItemContent, false ), + ControlRow( m_aImagesAndText, true ), + ControlRow( m_aImagesOnly, true ), + ControlRow( m_aTextOnly, true ), + ControlRow( m_aAutomaticContent, true ) }; bool bPreviousWasSubordinate = false; for ( size_t i=0; i < sizeof( aControlRows ) / sizeof( aControlRows[0] ); ++i ) @@ -399,6 +403,10 @@ IMPL_LINK( OptionsWindow, OnRadioToggled, RadioButton*, i_pRadioButton ) { rController.SetTabItemContent( TABITEM_TEXT_ONLY ); } + else if ( i_pRadioButton == &m_aAutomaticContent ) + { + rController.SetTabItemContent( TABITEM_AUTO ); + } } return 0L; } |