callcatcher: update unused code

a few more ResId using ctors going away

Change-Id: Ic956bc179c094d19989bf850657471192d042a01
This commit is contained in:
Caolán McNamara
2014-05-26 09:19:31 +01:00
parent 2e457e2ee5
commit 3ea1cdfa10
7 changed files with 11 additions and 264 deletions

View File

@@ -44,8 +44,6 @@ private:
public:
SvxCheckListBox( Window* pParent, WinBits nWinStyle = 0 );
SvxCheckListBox( Window* pParent, const ResId& rResId,
const Image& rNormalStaticImage );
void SetNormalStaticImage(const Image& rNormalStaticImage);
virtual ~SvxCheckListBox();

View File

@@ -61,40 +61,7 @@ protected:
};
// class SvxColorBox -----------------------------------------------------
class SvxColorBox : public ColorLB
{
using Window::Update;
sal_uInt16 nCurPos;
Timer aDelayTimer;
Size aLogicalSize;
bool bRelease;
OUString maCommand;
::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > mxFrame;
void ReleaseFocus_Impl();
public:
SvxColorBox( Window* pParent,
const OUString& rCommand,
const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rFrame,
WinBits nBits = WB_BORDER | WB_DROPDOWN | WB_AUTOHSCROLL );
virtual ~SvxColorBox();
void Update( const XLineColorItem* pItem );
protected:
virtual void Select() SAL_OVERRIDE;
virtual bool PreNotify( NotifyEvent& rNEvt ) SAL_OVERRIDE;
virtual bool Notify( NotifyEvent& rNEvt ) SAL_OVERRIDE;
virtual void DataChanged( const DataChangedEvent& rDCEvt ) SAL_OVERRIDE;
};
// class SvxMetricField --------------------------------------------------
class SVX_DLLPUBLIC SvxMetricField : public MetricField
{
using Window::Update;

View File

@@ -46,9 +46,8 @@ public:
};
public:
Throbber( Window* i_parentWindow, WinBits i_style, const ImageSet i_imageSet = IMAGES_AUTO );
Throbber( Window* i_parentWindow, const ResId& i_resId, const ImageSet i_imageSet = IMAGES_AUTO );
virtual ~Throbber();
Throbber(Window* i_parentWindow, WinBits i_style, const ImageSet i_imageSet = IMAGES_AUTO);
virtual ~Throbber();
// Properties
void setStepTime( sal_Int32 nStepTime ) { mnStepTime = nStepTime; }

View File

@@ -47,14 +47,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeSvxCheckListBox(Window *pPa
return new SvxCheckListBox(pParent, nWinStyle);
}
SvxCheckListBox::SvxCheckListBox( Window* pParent, const ResId& rResId,
const Image& rNormalStaticImage )
: SvTreeListBox( pParent, rResId )
{
Init_Impl();
SetNormalStaticImage(rNormalStaticImage);
}
void SvxCheckListBox::SetNormalStaticImage(const Image& rNormalStaticImage)
{
pCheckButton->aBmps[SV_BMP_STATICIMAGE] = rNormalStaticImage;

View File

@@ -29,9 +29,6 @@
#include <svx/dialogs.hrc>
#define TMP_STR_BEGIN "["
#define TMP_STR_END "]"
#define DELAY_TIMEOUT 100
#include <svx/xlnclit.hxx>
@@ -258,201 +255,7 @@ void SvxLineBox::FillControl()
}
}
// SvxColorBox
SvxColorBox::SvxColorBox(
Window* pParent,
const OUString& rCommand,
const Reference< XFrame >& rFrame,
WinBits nBits ) :
ColorLB( pParent, nBits ),
nCurPos ( 0 ),
aLogicalSize(45,80),
bRelease ( true ),
maCommand ( rCommand ),
mxFrame ( rFrame )
{
SetSizePixel( LogicToPixel( aLogicalSize , MAP_APPFONT));
Show();
SfxObjectShell* pSh = SfxObjectShell::Current();
if ( pSh )
{
const SvxColorListItem* pItem =
(const SvxColorListItem*)( pSh->GetItem( SID_COLOR_TABLE ) );
if(pItem)
Fill( pItem->GetColorList() );
}
}
SvxColorBox::~SvxColorBox()
{
}
void SvxColorBox::Update( const XLineColorItem* pItem )
{
if ( pItem )
{
// fdo#64455
::Color aColor = pItem->GetColorValue();
OUString aString( pItem->GetName() );
SelectEntry(aString);
if( GetSelectEntryPos() == LISTBOX_ENTRY_NOTFOUND ||
GetSelectEntryColor() != aColor )
{
SelectEntry( aColor );
}
// Check if the entry is not in the list
if( GetSelectEntryPos() == LISTBOX_ENTRY_NOTFOUND ||
GetSelectEntryColor() != aColor )
{
sal_Int32 nCount = GetEntryCount();
OUString aTmpStr;
if( nCount > 0 )
{
// Last entry gets tested against temporary color
aTmpStr = GetEntry( nCount - 1 );
if( aTmpStr.startsWith(TMP_STR_BEGIN) &&
aTmpStr.endsWith(TMP_STR_END) )
{
RemoveEntry( nCount - 1 );
}
}
aTmpStr = TMP_STR_BEGIN + aString + TMP_STR_END;
sal_Int32 nPos = InsertEntry( aColor, aTmpStr );
SelectEntryPos( nPos );
}
}
else
SetNoSelection();
}
void SvxColorBox::Select()
{
// OJ: base class call needed here because otherwise no event is send for accessibility
ColorLB::Select();
if ( !IsTravelSelect() )
{
XLineColorItem aLineColorItem( GetSelectEntry(), GetSelectEntryColor() );
INetURLObject aObj( maCommand );
Any a;
Sequence< PropertyValue > aArgs( 1 );
aArgs[0].Name = aObj.GetURLPath();
aLineColorItem.QueryValue( a );
aArgs[0].Value = a;
SfxToolBoxControl::Dispatch( Reference< XDispatchProvider >( mxFrame->getController(), UNO_QUERY ),
maCommand,
aArgs );
nCurPos = GetSelectEntryPos();
ReleaseFocus_Impl();
}
}
bool SvxColorBox::PreNotify( NotifyEvent& rNEvt )
{
sal_uInt16 nType = rNEvt.GetType();
switch(nType)
{
case EVENT_MOUSEBUTTONDOWN:
case EVENT_GETFOCUS:
nCurPos = GetSelectEntryPos();
break;
case EVENT_LOSEFOCUS:
SelectEntryPos(nCurPos);
break;
case EVENT_KEYINPUT:
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
if( pKEvt->GetKeyCode().GetCode() == KEY_TAB)
{
bRelease = false;
Select();
}
}
}
return ColorLB::PreNotify( rNEvt );
}
bool SvxColorBox::Notify( NotifyEvent& rNEvt )
{
bool nHandled = ColorLB::Notify( rNEvt );
if ( rNEvt.GetType() == EVENT_KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
switch ( pKEvt->GetKeyCode().GetCode() )
{
case KEY_RETURN:
Select();
nHandled = true;
break;
case KEY_ESCAPE:
SelectEntryPos( nCurPos );
ReleaseFocus_Impl();
nHandled = true;
break;
}
}
return nHandled;
}
void SvxColorBox::DataChanged( const DataChangedEvent& rDCEvt )
{
if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE) )
{
SetSizePixel(LogicToPixel(aLogicalSize, MAP_APPFONT));
Size aDropSize( aLogicalSize.Width(), LOGICAL_EDIT_HEIGHT);
SetDropDownSizePixel(LogicToPixel(aDropSize, MAP_APPFONT));
}
ColorLB::DataChanged( rDCEvt );
}
void SvxColorBox::ReleaseFocus_Impl()
{
if(!bRelease)
{
bRelease = true;
return;
}
if( SfxViewShell::Current() )
{
Window* pShellWnd = SfxViewShell::Current()->GetWindow();
if ( pShellWnd )
pShellWnd->GrabFocus();
}
}
// SvxMetricField
SvxMetricField::SvxMetricField(
Window* pParent, const Reference< XFrame >& rFrame, WinBits nBits )
: MetricField(pParent, nBits)

View File

@@ -1,11 +1,8 @@
(anonymous namespace)::flagToString(unsigned short)
BigInt::BigInt(unsigned int)
CalcUnoApiTest::CalcUnoApiTest(rtl::OUString const&)
ComboBox::GetEntryPos(void const*) const
DocumentHandler::DocumentHandler(com::sun::star::uno::Reference<com::sun::star::xml::sax::XDocumentHandler>&)
EditEngine::IsIdleFormatterActive() const
Font::LoadSystemFont(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, int)
Font::deleteFont()
GDriveDocument::GDriveDocument(GDriveSession*)
GDriveFolder::GDriveFolder(GDriveSession*)
GDriveProperty::GDriveProperty()
@@ -18,7 +15,6 @@ MenuBar::GetMenuBarButtonRectPixel(unsigned short)
MenuBar::RemoveMenuBarButton(unsigned short)
MenuBar::SetMenuBarButtonHighlightHdl(unsigned short, Link const&)
MetafileXmlDump::filterNoneActionTypes()
OpenGLContext::getOpenGLWindow()
OpenGLContext::renderToFile()
OpenGLRender::CreateTextTexture(rtl::OUString const&, Font, long, com::sun::star::awt::Point, com::sun::star::awt::Size, long)
OutputDevice::GetCanvas() const
@@ -28,10 +24,16 @@ OutputDevice::LogicToPixel(Region const&, MapMode const&) const
OutputDevice::LogicToPixel(basegfx::B2DPolygon const&) const
OutputDevice::LogicToPixel(basegfx::B2DPolygon const&, MapMode const&) const
OutputDevice::PixelToLogic(Region const&, MapMode const&) const
RenderPrimitive::bindSortedIndicesBuf()
RenderPrimitive::copyIndiceBufferData(char const*, unsigned int)
RenderPrimitive::copyVertexBufferData(char const*, unsigned int)
SalGraphics::drawTransformedBitmap(basegfx::B2DPoint const&, basegfx::B2DPoint const&, basegfx::B2DPoint const&, SalBitmap const&, SalBitmap const*)
ScDocument::AreaBroadcastInRange(ScRange const&, ScHint const&)
ScDocument::CreateFormatTable() const
ScExtIButton::GetSelected() const
ScFormulaCellGroup::scheduleCompilation()
ScRawToken::Clone() const
ScRawToken::Delete()
ScTabView::DrawMarkRect(Rectangle const&)
ScTabViewShell::SetChartArea(tools::SvRef<ScRangeList> const&, Rectangle const&)
ScVbaFormat<ooo::vba::excel::XStyle>::getAddIndent()
@@ -50,12 +52,12 @@ StyleSettings::SetTitleHeight(long)
StyleSettings::SetUseFlatBorders(bool)
StyleSettings::SetUseFlatMenus(bool)
SvpSalInstance::PostedEventsInQueue()
SvtLanguageTable::AddLanguageTag(LanguageTag const&, rtl::OUString const&)
SvtListener::IsListening(SvtBroadcaster&) const
SvxDummyShapeContainer::SvxDummyShapeContainer(com::sun::star::uno::Reference<com::sun::star::drawing::XShapes>)
SvxFontListBox::GetSelectEntry() const
SvxNumberFormatShell::IsAdded_Impl(unsigned long)
TextDoc::IsValidPaM(TextPaM const&)
Texture::greateEmptyTexture(int, int, unsigned int)
Texture::setSamplerParameter(unsigned int, unsigned int)
UnoApiTest::closeDocument(com::sun::star::uno::Reference<com::sun::star::lang::XComponent>)
VCLXGraphics::getFillColor()
VCLXGraphics::getFont()
@@ -183,6 +185,7 @@ chart::opengl3D::OpenGL3DRenderer::GetTime()
chart::opengl3D::OpenGL3DRenderer::RenderClickPos(Point)
chart::opengl3D::OpenGL3DRenderer::RenderFPS(float)
chart::opengl3D::OpenGL3DRenderer::RenderTexture(unsigned int)
chart::opengl3D::Text::getSize() const
comphelper::detail::ConfigurationWrapper::getGroupReadWrite(boost::shared_ptr<comphelper::ConfigurationChanges> const&, rtl::OUString const&) const
comphelper::detail::ConfigurationWrapper::getLocalizedPropertyValue(rtl::OUString const&) const
comphelper::detail::ConfigurationWrapper::setLocalizedPropertyValue(boost::shared_ptr<comphelper::ConfigurationChanges> const&, rtl::OUString const&, com::sun::star::uno::Any const&) const

View File

@@ -57,21 +57,6 @@ Throbber::Throbber( Window* i_parentWindow, WinBits i_style, const ImageSet i_im
initImages();
}
Throbber::Throbber( Window* i_parentWindow, const ResId& i_resId, const ImageSet i_imageSet )
:ImageControl( i_parentWindow, i_resId )
,mbRepeat( true )
,mnStepTime( 100 )
,mnCurStep( 0 )
,mnStepCount( 0 )
,meImageSet( i_imageSet )
{
maWaitTimer.SetTimeout( mnStepTime );
maWaitTimer.SetTimeoutHdl( LINK( this, Throbber, TimeOutHdl ) );
SetScaleMode( ImageScaleMode::NONE );
initImages();
}
Throbber::~Throbber()
{
maWaitTimer.Stop();