summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-08-19 09:11:34 +0200
committerNoel Grandin <noel@peralex.com>2015-08-26 11:15:35 +0200
commit167bc621ef825ed5b961502fe9324a675ee34e42 (patch)
tree523838d8adc14a62f846529ee6eab3343b2fe87b /filter
parent46a27805fb707544a844a961a3743b8b992282f0 (diff)
Convert vcl Button Link<> click handler to typed Link<Button*,void>
Change-Id: Ie80dfb003118d40741549c41ebcc7eda4819f05b
Diffstat (limited to 'filter')
-rw-r--r--filter/source/pdf/impdialog.cxx20
-rw-r--r--filter/source/pdf/impdialog.hxx26
-rw-r--r--filter/source/xsltdialog/xmlfiltersettingsdialog.cxx3
-rw-r--r--filter/source/xsltdialog/xmlfiltersettingsdialog.hxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltertabdialog.cxx4
-rw-r--r--filter/source/xsltdialog/xmlfiltertabdialog.hxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltertabpagexslt.cxx4
-rw-r--r--filter/source/xsltdialog/xmlfiltertabpagexslt.hxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltertestdialog.cxx4
-rw-r--r--filter/source/xsltdialog/xmlfiltertestdialog.hxx2
10 files changed, 27 insertions, 42 deletions
diff --git a/filter/source/pdf/impdialog.cxx b/filter/source/pdf/impdialog.cxx
index 43dbec842cfc..8ff8bcf00321 100644
--- a/filter/source/pdf/impdialog.cxx
+++ b/filter/source/pdf/impdialog.cxx
@@ -303,10 +303,9 @@ ImpPDFTabGeneralPage* ImpPDFTabDialog::getGeneralPage() const
return NULL;
}
-IMPL_LINK_NOARG(ImpPDFTabDialog, CancelHdl)
+IMPL_LINK_NOARG_TYPED(ImpPDFTabDialog, CancelHdl, Button*, void)
{
EndDialog();
- return 0;
}
@@ -1291,7 +1290,7 @@ void ImpPDFTabSecurityPage::SetFilterConfigItem( const ImpPDFTabDialog* paParen
ImplPDFASecurityControl(!pGeneralPage->IsPdfaSelected());
}
-IMPL_LINK_NOARG(ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl)
+IMPL_LINK_NOARG_TYPED(ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl, Button*, void)
{
ScopedVclPtrInstance< SfxPasswordDialog > aPwdDialog( this, &msUserPwdTitle );
aPwdDialog->SetMinLen( 0 );
@@ -1318,7 +1317,6 @@ IMPL_LINK_NOARG(ImpPDFTabSecurityPage, ClickmaPbSetPwdHdl)
maPreparedOwnerPassword = Sequence< NamedValue >();
}
enablePermissionControls();
- return 0;
}
void ImpPDFTabSecurityPage::enablePermissionControls()
@@ -1532,23 +1530,21 @@ void ImpPDFTabLinksPage::ImplPDFALinkControl( bool bEnableLaunch )
// reset the memory of Launch action present
// when PDF/A-1 was requested
-IMPL_LINK_NOARG(ImpPDFTabLinksPage, ClickRbOpnLnksDefaultHdl)
+IMPL_LINK_NOARG_TYPED(ImpPDFTabLinksPage, ClickRbOpnLnksDefaultHdl, Button*, void)
{
mbOpnLnksDefaultUserState = m_pRbOpnLnksDefault->IsChecked();
mbOpnLnksLaunchUserState = m_pRbOpnLnksLaunch->IsChecked();
mbOpnLnksBrowserUserState = m_pRbOpnLnksBrowser->IsChecked();
- return 0;
}
// reset the memory of a launch action present
// when PDF/A-1 was requested
-IMPL_LINK_NOARG(ImpPDFTabLinksPage, ClickRbOpnLnksBrowserHdl)
+IMPL_LINK_NOARG_TYPED(ImpPDFTabLinksPage, ClickRbOpnLnksBrowserHdl, Button*, void)
{
mbOpnLnksDefaultUserState = m_pRbOpnLnksDefault->IsChecked();
mbOpnLnksLaunchUserState = m_pRbOpnLnksLaunch->IsChecked();
mbOpnLnksBrowserUserState = m_pRbOpnLnksBrowser->IsChecked();
- return 0;
}
ImplErrorDialog::ImplErrorDialog(const std::set< vcl::PDFWriter::ErrorCode >& rErrors)
@@ -1683,7 +1679,7 @@ void ImpPDFTabSigningPage::dispose()
SfxTabPage::dispose();
}
-IMPL_LINK_NOARG( ImpPDFTabSigningPage, ClickmaPbSignCertSelect )
+IMPL_LINK_NOARG_TYPED( ImpPDFTabSigningPage, ClickmaPbSignCertSelect, Button*, void )
{
Reference< security::XDocumentDigitalSignatures > xSigner(
@@ -1719,11 +1715,9 @@ IMPL_LINK_NOARG( ImpPDFTabSigningPage, ClickmaPbSignCertSelect )
if (mpLBSignTSA->GetEntryCount() > 1)
mpLBSignTSA->Enable();
}
-
- return 0;
}
-IMPL_LINK_NOARG( ImpPDFTabSigningPage, ClickmaPbSignCertClear )
+IMPL_LINK_NOARG_TYPED( ImpPDFTabSigningPage, ClickmaPbSignCertClear, Button*, void )
{
mpEdSignCert->SetText(OUString(""));
maSignCertificate.clear();
@@ -1733,8 +1727,6 @@ IMPL_LINK_NOARG( ImpPDFTabSigningPage, ClickmaPbSignCertClear )
mpEdSignContactInfo->Enable( false );
mpEdSignReason->Enable( false );
mpLBSignTSA->Enable( false );
-
- return 0;
}
diff --git a/filter/source/pdf/impdialog.hxx b/filter/source/pdf/impdialog.hxx
index ffc8acc10b9d..39f9e78011e0 100644
--- a/filter/source/pdf/impdialog.hxx
+++ b/filter/source/pdf/impdialog.hxx
@@ -80,7 +80,7 @@ private:
Any maSelection;
- DECL_LINK(CancelHdl, void *);
+ DECL_LINK_TYPED(CancelHdl, Button*, void);
sal_uInt16 mnSigningPageId;
sal_uInt16 mnSecurityPageId;
@@ -331,7 +331,7 @@ public:
class ImpPDFTabSecurityPage : public SfxTabPage
{
VclPtr<PushButton> mpPbSetPwd;
- OUString msStrSetPwd;
+ OUString msStrSetPwd;
VclPtr<VclContainer> mpUserPwdSet;
VclPtr<VclContainer> mpUserPwdUnset;
@@ -366,7 +366,7 @@ class ImpPDFTabSecurityPage : public SfxTabPage
com::sun::star::uno::Reference< com::sun::star::beans::XMaterialHolder > mxPreparedPasswords;
- DECL_LINK( ClickmaPbSetPwdHdl, void* );
+ DECL_LINK_TYPED( ClickmaPbSetPwdHdl, Button*, void );
void enablePermissionControls();
@@ -388,19 +388,19 @@ public:
//class to implement the relative link stuff
class ImpPDFTabLinksPage : public SfxTabPage
{
- VclPtr<CheckBox> m_pCbExprtBmkrToNmDst;
- VclPtr<CheckBox> m_pCbOOoToPDFTargets;
- VclPtr<CheckBox> m_pCbExportRelativeFsysLinks;
+ VclPtr<CheckBox> m_pCbExprtBmkrToNmDst;
+ VclPtr<CheckBox> m_pCbOOoToPDFTargets;
+ VclPtr<CheckBox> m_pCbExportRelativeFsysLinks;
- VclPtr<RadioButton> m_pRbOpnLnksDefault;
+ VclPtr<RadioButton> m_pRbOpnLnksDefault;
bool mbOpnLnksDefaultUserState;
- VclPtr<RadioButton> m_pRbOpnLnksLaunch;
+ VclPtr<RadioButton> m_pRbOpnLnksLaunch;
bool mbOpnLnksLaunchUserState;
- VclPtr<RadioButton> m_pRbOpnLnksBrowser;
+ VclPtr<RadioButton> m_pRbOpnLnksBrowser;
bool mbOpnLnksBrowserUserState;
- DECL_LINK( ClickRbOpnLnksDefaultHdl, void* );
- DECL_LINK( ClickRbOpnLnksBrowserHdl, void* );
+ DECL_LINK_TYPED( ClickRbOpnLnksDefaultHdl, Button*, void );
+ DECL_LINK_TYPED( ClickRbOpnLnksBrowserHdl, Button*, void );
public:
ImpPDFTabLinksPage( vcl::Window* pParent,
@@ -430,8 +430,8 @@ class ImpPDFTabSigningPage : public SfxTabPage
VclPtr<ListBox> mpLBSignTSA;
com::sun::star::uno::Reference< com::sun::star::security::XCertificate > maSignCertificate;
- DECL_LINK( ClickmaPbSignCertSelect, void* );
- DECL_LINK( ClickmaPbSignCertClear, void* );
+ DECL_LINK_TYPED( ClickmaPbSignCertSelect, Button*, void );
+ DECL_LINK_TYPED( ClickmaPbSignCertClear, Button*, void );
public:
ImpPDFTabSigningPage( vcl::Window* pParent,
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
index c937e3f4029a..8ab238461a80 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
@@ -124,7 +124,7 @@ void XMLFilterSettingsDialog::dispose()
ModelessDialog::dispose();
}
-IMPL_LINK(XMLFilterSettingsDialog, ClickHdl_Impl, PushButton *, pButton )
+IMPL_LINK_TYPED(XMLFilterSettingsDialog, ClickHdl_Impl, Button *, pButton, void )
{
m_bIsClosable = false;
@@ -158,7 +158,6 @@ IMPL_LINK(XMLFilterSettingsDialog, ClickHdl_Impl, PushButton *, pButton )
}
m_bIsClosable = true;
- return 0;
}
IMPL_LINK_NOARG(XMLFilterSettingsDialog, SelectionChangedHdl_Impl)
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.hxx b/filter/source/xsltdialog/xmlfiltersettingsdialog.hxx
index 0e40a14a24f3..c102cf5d79cb 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.hxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.hxx
@@ -91,7 +91,7 @@ public:
virtual ~XMLFilterSettingsDialog();
virtual void dispose() SAL_OVERRIDE;
- DECL_LINK(ClickHdl_Impl, PushButton * );
+ DECL_LINK_TYPED(ClickHdl_Impl, Button *, void );
DECL_LINK(SelectionChangedHdl_Impl, void * );
DECL_LINK(DoubleClickHdl_Impl, void * );
diff --git a/filter/source/xsltdialog/xmlfiltertabdialog.cxx b/filter/source/xsltdialog/xmlfiltertabdialog.cxx
index 1511f12ba39f..0f63a5858967 100644
--- a/filter/source/xsltdialog/xmlfiltertabdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertabdialog.cxx
@@ -284,12 +284,10 @@ bool XMLFilterTabDialog::onOk()
-IMPL_LINK_NOARG(XMLFilterTabDialog, OkHdl)
+IMPL_LINK_NOARG_TYPED(XMLFilterTabDialog, OkHdl, Button*, void)
{
if( onOk() )
EndDialog(1);
-
- return 0;
}
diff --git a/filter/source/xsltdialog/xmlfiltertabdialog.hxx b/filter/source/xsltdialog/xmlfiltertabdialog.hxx
index a3501e1ceac0..616ec5485816 100644
--- a/filter/source/xsltdialog/xmlfiltertabdialog.hxx
+++ b/filter/source/xsltdialog/xmlfiltertabdialog.hxx
@@ -46,7 +46,7 @@ private:
com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > mxContext;
DECL_STATIC_LINK( XMLFilterTabDialog, ActivatePageHdl, TabControl * );
- DECL_LINK(OkHdl, void *);
+ DECL_LINK_TYPED(OkHdl, Button*, void);
ResMgr& mrResMgr;
diff --git a/filter/source/xsltdialog/xmlfiltertabpagexslt.cxx b/filter/source/xsltdialog/xmlfiltertabpagexslt.cxx
index dfcf3afb9736..693e37f27d48 100644
--- a/filter/source/xsltdialog/xmlfiltertabpagexslt.cxx
+++ b/filter/source/xsltdialog/xmlfiltertabpagexslt.cxx
@@ -154,7 +154,7 @@ OUString XMLFilterTabPageXSLT::GetURL( SvtURLBox* rURLBox )
return aURL;
}
-IMPL_LINK ( XMLFilterTabPageXSLT, ClickBrowseHdl_Impl, PushButton *, pButton )
+IMPL_LINK_TYPED ( XMLFilterTabPageXSLT, ClickBrowseHdl_Impl, Button *, pButton, void )
{
SvtURLBox* pURLBox;
@@ -183,8 +183,6 @@ IMPL_LINK ( XMLFilterTabPageXSLT, ClickBrowseHdl_Impl, PushButton *, pButton )
SetURL( pURLBox, aURL );
}
-
- return 0L;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/filter/source/xsltdialog/xmlfiltertabpagexslt.hxx b/filter/source/xsltdialog/xmlfiltertabpagexslt.hxx
index 110ddca6bf7a..6ec26deffedf 100644
--- a/filter/source/xsltdialog/xmlfiltertabpagexslt.hxx
+++ b/filter/source/xsltdialog/xmlfiltertabpagexslt.hxx
@@ -40,7 +40,7 @@ public:
bool FillInfo( filter_info_impl* pInfo );
void SetInfo(const filter_info_impl* pInfo);
- DECL_LINK( ClickBrowseHdl_Impl, PushButton * );
+ DECL_LINK_TYPED( ClickBrowseHdl_Impl, Button *, void );
VclPtr<Edit> m_pEDDocType;
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.cxx b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
index 34990328a91c..6ad0844b935d 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
@@ -657,7 +657,7 @@ void XMLFilterTestDialog::import( const OUString& rURL )
}
}
-IMPL_LINK(XMLFilterTestDialog, ClickHdl_Impl, PushButton *, pButton )
+IMPL_LINK_TYPED(XMLFilterTestDialog, ClickHdl_Impl, Button *, pButton, void )
{
if (m_pPBExportBrowse == pButton)
{
@@ -679,8 +679,6 @@ IMPL_LINK(XMLFilterTestDialog, ClickHdl_Impl, PushButton *, pButton )
{
Close();
}
-
- return 0;
}
/** returns the front most open component that supports the given service */
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.hxx b/filter/source/xsltdialog/xmlfiltertestdialog.hxx
index 5f1d86ef8569..56f99483175f 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.hxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.hxx
@@ -44,7 +44,7 @@ public:
void updateCurrentDocumentButtonState( com::sun::star::uno::Reference< com::sun::star::lang::XComponent > * pRef = NULL );
private:
- DECL_LINK(ClickHdl_Impl, PushButton * );
+ DECL_LINK_TYPED(ClickHdl_Impl, Button *, void );
void onExportBrowse();
void onExportCurrentDocument();