summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-09-17 09:25:04 +0200
committerNoel Grandin <noel@peralex.com>2015-09-17 12:22:47 +0200
commit061934621664c61dd04de2e48935a7fcfe00e552 (patch)
treeb8357db65af20fd46a5b89855401384d6162bad1 /extensions
parentbd1da371633c8df7f31da1cdaeb6f9e61dee4429 (diff)
convert Link<> to typed
Change-Id: Id600a5ee28440ee91c7089c8f7aa05f83bc0e63c
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/scanner/sane.cxx2
-rw-r--r--extensions/source/scanner/sane.hxx8
-rw-r--r--extensions/source/scanner/sanedlg.cxx5
-rw-r--r--extensions/source/scanner/sanedlg.hxx8
4 files changed, 11 insertions, 12 deletions
diff --git a/extensions/source/scanner/sane.cxx b/extensions/source/scanner/sane.cxx
index c5ff202aa7ba..e95446af369a 100644
--- a/extensions/source/scanner/sane.cxx
+++ b/extensions/source/scanner/sane.cxx
@@ -281,7 +281,7 @@ void Sane::ReloadOptions()
CheckConsistency( NULL, true );
- maReloadOptionsLink.Call( this );
+ maReloadOptionsLink.Call( *this );
}
bool Sane::Open( const char* name )
diff --git a/extensions/source/scanner/sane.hxx b/extensions/source/scanner/sane.hxx
index 06687028a5e8..7f204f6f5544 100644
--- a/extensions/source/scanner/sane.hxx
+++ b/extensions/source/scanner/sane.hxx
@@ -96,7 +96,7 @@ private:
int mnDevice;
SANE_Handle maHandle;
- Link<> maReloadOptionsLink;
+ Link<Sane&,void> maReloadOptionsLink;
static inline oslGenericFunction
LoadSymbol( const char* );
@@ -168,7 +168,7 @@ public:
bool Start( BitmapTransporter& );
- inline Link<> SetReloadOptionsHdl( const Link<>& rLink );
+ inline Link<Sane&,void> SetReloadOptionsHdl( const Link<Sane&,void>& rLink );
};
inline int Sane::GetOptionElements( int n )
@@ -181,9 +181,9 @@ inline int Sane::GetOptionElements( int n )
return 1;
}
-inline Link<> Sane::SetReloadOptionsHdl( const Link<>& rLink )
+inline Link<Sane&,void> Sane::SetReloadOptionsHdl( const Link<Sane&,void>& rLink )
{
- Link<> aRet = maReloadOptionsLink;
+ Link<Sane&,void> aRet = maReloadOptionsLink;
maReloadOptionsLink = rLink;
return aRet;
}
diff --git a/extensions/source/scanner/sanedlg.cxx b/extensions/source/scanner/sanedlg.cxx
index 4d245941ab74..0d3290890e3b 100644
--- a/extensions/source/scanner/sanedlg.cxx
+++ b/extensions/source/scanner/sanedlg.cxx
@@ -662,7 +662,7 @@ IMPL_LINK_TYPED( SaneDlg, ClickBtnHdl, Button*, pButton, void )
}
else if( pButton == mpAdvancedBox )
{
- ReloadSaneOptionsHdl( NULL );
+ ReloadSaneOptionsHdl( mrSane );
}
}
if( pButton == mpOKButton || pButton == mpScanButton )
@@ -873,14 +873,13 @@ IMPL_LINK( SaneDlg, ModifyHdl, Edit*, pEdit )
return 0;
}
-IMPL_LINK( SaneDlg, ReloadSaneOptionsHdl, Sane*, /*pSane*/ )
+IMPL_LINK_NOARG_TYPED( SaneDlg, ReloadSaneOptionsHdl, Sane&, void )
{
mnCurrentOption = -1;
mnCurrentElement = 0;
DisableOption();
InitFields();
mpPreview->Invalidate();
- return 0;
}
void SaneDlg::AcquirePreview()
diff --git a/extensions/source/scanner/sanedlg.hxx b/extensions/source/scanner/sanedlg.hxx
index 2854da5d4d29..17cae7604a9f 100644
--- a/extensions/source/scanner/sanedlg.hxx
+++ b/extensions/source/scanner/sanedlg.hxx
@@ -35,10 +35,10 @@ class ScanPreview;
class SaneDlg : public ModalDialog
{
private:
- Sane& mrSane;
- bool mbScanEnabled;
+ Sane& mrSane;
+ bool mbScanEnabled;
- Link<> maOldLink;
+ Link<Sane&,void> maOldLink;
VclPtr<OKButton> mpOKButton;
VclPtr<CancelButton> mpCancelButton;
@@ -83,7 +83,7 @@ private:
DECL_LINK_TYPED( ClickBtnHdl, Button*, void );
DECL_LINK( SelectHdl, ListBox* );
DECL_LINK( ModifyHdl, Edit* );
- DECL_LINK( ReloadSaneOptionsHdl, Sane* );
+ DECL_LINK_TYPED( ReloadSaneOptionsHdl, Sane&, void );
DECL_LINK_TYPED( OptionsBoxSelectHdl, SvTreeListBox*, void );
void SaveState();