summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-12-21 21:43:27 +0100
committerStephan Bergmann <sbergman@redhat.com>2016-12-21 21:43:27 +0100
commit87d1657d6bd68e4a3d8ba461078a7bb1dc9ed121 (patch)
tree9646191a7cb57ebd868984760729b5647b52fce4 /extensions
parent20bd8d0426380b5ae52c83923f2eb747a5abf8b0 (diff)
loplugin:staticmethods
Change-Id: I04d3095c657deb72a20fa803964912cf6baf268b
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/propctrlr/taborder.cxx77
-rw-r--r--extensions/source/propctrlr/taborder.hxx4
2 files changed, 40 insertions, 41 deletions
diff --git a/extensions/source/propctrlr/taborder.cxx b/extensions/source/propctrlr/taborder.cxx
index 4724a40d290a..cf2b0eda7d07 100644
--- a/extensions/source/propctrlr/taborder.cxx
+++ b/extensions/source/propctrlr/taborder.cxx
@@ -40,6 +40,46 @@ namespace pcr
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::datatransfer;
+ namespace {
+
+ Image GetImage( const Reference< XPropertySet >& _rxSet )
+ {
+ sal_uInt16 nImageId = RID_SVXBMP_CONTROL;
+ // TODO: classify controls also in Basic propbrw
+ if ( _rxSet.is() && ::comphelper::hasProperty( PROPERTY_CLASSID, _rxSet ) )
+ {
+ switch( ::comphelper::getINT16( _rxSet->getPropertyValue( PROPERTY_CLASSID ) ) )
+ {
+ case FormComponentType::COMMANDBUTTON: nImageId = RID_SVXBMP_BUTTON; break;
+ case FormComponentType::FIXEDTEXT: nImageId = RID_SVXBMP_FIXEDTEXT; break;
+ case FormComponentType::TEXTFIELD: nImageId = RID_SVXBMP_EDITBOX; break;
+ case FormComponentType::RADIOBUTTON: nImageId = RID_SVXBMP_RADIOBUTTON; break;
+ case FormComponentType::CHECKBOX: nImageId = RID_SVXBMP_CHECKBOX; break;
+ case FormComponentType::LISTBOX: nImageId = RID_SVXBMP_LISTBOX; break;
+ case FormComponentType::COMBOBOX: nImageId = RID_SVXBMP_COMBOBOX; break;
+ case FormComponentType::GROUPBOX: nImageId = RID_SVXBMP_GROUPBOX; break;
+ case FormComponentType::IMAGEBUTTON: nImageId = RID_SVXBMP_IMAGEBUTTON; break;
+ case FormComponentType::FILECONTROL: nImageId = RID_SVXBMP_FILECONTROL; break;
+ case FormComponentType::HIDDENCONTROL: nImageId = RID_SVXBMP_HIDDEN; break;
+ case FormComponentType::DATEFIELD: nImageId = RID_SVXBMP_DATEFIELD; break;
+ case FormComponentType::TIMEFIELD: nImageId = RID_SVXBMP_TIMEFIELD; break;
+ case FormComponentType::NUMERICFIELD: nImageId = RID_SVXBMP_NUMERICFIELD; break;
+ case FormComponentType::CURRENCYFIELD: nImageId = RID_SVXBMP_CURRENCYFIELD; break;
+ case FormComponentType::PATTERNFIELD: nImageId = RID_SVXBMP_PATTERNFIELD; break;
+ case FormComponentType::IMAGECONTROL: nImageId = RID_SVXBMP_IMAGECONTROL; break;
+ case FormComponentType::GRIDCONTROL: nImageId = RID_SVXBMP_GRID; break;
+ case FormComponentType::SCROLLBAR: nImageId = RID_SVXBMP_SCROLLBAR; break;
+ case FormComponentType::SPINBUTTON: nImageId = RID_SVXBMP_SPINBUTTON; break;
+ case FormComponentType::NAVIGATIONBAR: nImageId = RID_SVXBMP_NAVIGATIONBAR; break;
+ default:
+ OSL_FAIL( "TabOrderDialog::GetImage: unknown control type" );
+ }
+ }
+
+ return Image(BitmapEx(PcrRes(nImageId)));;
+ }
+
+ }
//= OSimpleTabModel
@@ -126,43 +166,6 @@ namespace pcr
ModalDialog::dispose();
}
- Image TabOrderDialog::GetImage( const Reference< XPropertySet >& _rxSet )
- {
- sal_uInt16 nImageId = RID_SVXBMP_CONTROL;
- // TODO: classify controls also in Basic propbrw
- if ( _rxSet.is() && ::comphelper::hasProperty( PROPERTY_CLASSID, _rxSet ) )
- {
- switch( ::comphelper::getINT16( _rxSet->getPropertyValue( PROPERTY_CLASSID ) ) )
- {
- case FormComponentType::COMMANDBUTTON: nImageId = RID_SVXBMP_BUTTON; break;
- case FormComponentType::FIXEDTEXT: nImageId = RID_SVXBMP_FIXEDTEXT; break;
- case FormComponentType::TEXTFIELD: nImageId = RID_SVXBMP_EDITBOX; break;
- case FormComponentType::RADIOBUTTON: nImageId = RID_SVXBMP_RADIOBUTTON; break;
- case FormComponentType::CHECKBOX: nImageId = RID_SVXBMP_CHECKBOX; break;
- case FormComponentType::LISTBOX: nImageId = RID_SVXBMP_LISTBOX; break;
- case FormComponentType::COMBOBOX: nImageId = RID_SVXBMP_COMBOBOX; break;
- case FormComponentType::GROUPBOX: nImageId = RID_SVXBMP_GROUPBOX; break;
- case FormComponentType::IMAGEBUTTON: nImageId = RID_SVXBMP_IMAGEBUTTON; break;
- case FormComponentType::FILECONTROL: nImageId = RID_SVXBMP_FILECONTROL; break;
- case FormComponentType::HIDDENCONTROL: nImageId = RID_SVXBMP_HIDDEN; break;
- case FormComponentType::DATEFIELD: nImageId = RID_SVXBMP_DATEFIELD; break;
- case FormComponentType::TIMEFIELD: nImageId = RID_SVXBMP_TIMEFIELD; break;
- case FormComponentType::NUMERICFIELD: nImageId = RID_SVXBMP_NUMERICFIELD; break;
- case FormComponentType::CURRENCYFIELD: nImageId = RID_SVXBMP_CURRENCYFIELD; break;
- case FormComponentType::PATTERNFIELD: nImageId = RID_SVXBMP_PATTERNFIELD; break;
- case FormComponentType::IMAGECONTROL: nImageId = RID_SVXBMP_IMAGECONTROL; break;
- case FormComponentType::GRIDCONTROL: nImageId = RID_SVXBMP_GRID; break;
- case FormComponentType::SCROLLBAR: nImageId = RID_SVXBMP_SCROLLBAR; break;
- case FormComponentType::SPINBUTTON: nImageId = RID_SVXBMP_SPINBUTTON; break;
- case FormComponentType::NAVIGATIONBAR: nImageId = RID_SVXBMP_NAVIGATIONBAR; break;
- default:
- OSL_FAIL( "TabOrderDialog::GetImage: unknown control type" );
- }
- }
-
- return Image(BitmapEx(PcrRes(nImageId)));;
- }
-
void TabOrderDialog::FillList()
{
DBG_ASSERT( m_xTempModel.is() && m_xControlContainer.is(), "TabOrderDialog::FillList: invalid call!" );
diff --git a/extensions/source/propctrlr/taborder.hxx b/extensions/source/propctrlr/taborder.hxx
index 0c4aa9d05482..0db369ead9b2 100644
--- a/extensions/source/propctrlr/taborder.hxx
+++ b/extensions/source/propctrlr/taborder.hxx
@@ -83,10 +83,6 @@ namespace pcr
void FillList();
- static Image GetImage(
- const css::uno::Reference< css::beans::XPropertySet > & _rxSet
- );
-
public:
TabOrderDialog(
vcl::Window* _pParent,