[Libreoffice-commits] core.git: cui/source

Noel Grandin noelgrandin at gmail.com
Fri Sep 25 11:20:07 PDT 2015


 cui/source/dialogs/postdlg.cxx |    4 ++--
 cui/source/factory/dlgfact.cxx |   10 ++++------
 cui/source/factory/dlgfact.hxx |    4 ++--
 cui/source/inc/postdlg.hxx     |    8 ++++----
 4 files changed, 12 insertions(+), 14 deletions(-)

New commits:
commit 6fd356a08e92c043be612594eeba1521a837e48a
Author: Noel Grandin <noelgrandin at gmail.com>
Date:   Thu Sep 24 19:04:43 2015 +0200

    convert Link<> to typed
    
    Change-Id: I845f48577a9b93854e24a2004168c2d2311d9542
    Reviewed-on: https://gerrit.libreoffice.org/18854
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noelgrandin at gmail.com>

diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx
index 14dea85..a2ab2ec 100644
--- a/cui/source/dialogs/postdlg.cxx
+++ b/cui/source/dialogs/postdlg.cxx
@@ -176,12 +176,12 @@ void SvxPostItDialog::EnableTravel(bool bNext, bool bPrev)
 
 IMPL_LINK_NOARG_TYPED(SvxPostItDialog, PrevHdl, Button*, void)
 {
-    aPrevHdlLink.Call( this );
+    aPrevHdlLink.Call( *this );
 }
 
 IMPL_LINK_NOARG_TYPED(SvxPostItDialog, NextHdl, Button*, void)
 {
-    aNextHdlLink.Call( this );
+    aNextHdlLink.Call( *this );
 }
 
 IMPL_LINK_NOARG_TYPED(SvxPostItDialog, Stamp, Button*, void)
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index 94356f2..6810b42 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -785,7 +785,7 @@ void AbstractSvxPostItDialog_Impl::SetNextHdl( const Link<>& rLink )
     if( rLink.IsSet() )
         pDlg->SetNextHdl( LINK(this, AbstractSvxPostItDialog_Impl, NextHdl ) );
     else
-        pDlg->SetNextHdl( Link<>() );
+        pDlg->SetNextHdl( Link<SvxPostItDialog&,void>() );
 }
 void AbstractSvxPostItDialog_Impl::SetPrevHdl( const Link<>& rLink )
 {
@@ -793,19 +793,17 @@ void AbstractSvxPostItDialog_Impl::SetPrevHdl( const Link<>& rLink )
     if( rLink.IsSet() )
         pDlg->SetPrevHdl( LINK(this, AbstractSvxPostItDialog_Impl, PrevHdl ) );
     else
-        pDlg->SetPrevHdl( Link<>() );
+        pDlg->SetPrevHdl( Link<SvxPostItDialog&,void>() );
 }
-IMPL_LINK_NOARG(AbstractSvxPostItDialog_Impl, NextHdl)
+IMPL_LINK_NOARG_TYPED(AbstractSvxPostItDialog_Impl, NextHdl, SvxPostItDialog&, void)
 {
     if( aNextHdl.IsSet() )
         aNextHdl.Call(this);
-    return 0;
 }
-IMPL_LINK_NOARG(AbstractSvxPostItDialog_Impl, PrevHdl)
+IMPL_LINK_NOARG_TYPED(AbstractSvxPostItDialog_Impl, PrevHdl, SvxPostItDialog&, void)
 {
     if( aPrevHdl.IsSet() )
         aPrevHdl.Call(this);
-    return 0;
 }
 vcl::Window * AbstractSvxPostItDialog_Impl::GetWindow()
 {
diff --git a/cui/source/factory/dlgfact.hxx b/cui/source/factory/dlgfact.hxx
index 949e252..af543dc 100644
--- a/cui/source/factory/dlgfact.hxx
+++ b/cui/source/factory/dlgfact.hxx
@@ -460,8 +460,8 @@ class AbstractSvxPostItDialog_Impl :public AbstractSvxPostItDialog
 private:
     Link<> aNextHdl;
     Link<> aPrevHdl;
-    DECL_LINK(NextHdl, void *);
-    DECL_LINK(PrevHdl, void *);
+    DECL_LINK_TYPED(NextHdl, SvxPostItDialog&, void);
+    DECL_LINK_TYPED(PrevHdl, SvxPostItDialog&, void);
 };
 
 class PasswordToOpenModifyDialog;
diff --git a/cui/source/inc/postdlg.hxx b/cui/source/inc/postdlg.hxx
index 3951908..d367676 100644
--- a/cui/source/inc/postdlg.hxx
+++ b/cui/source/inc/postdlg.hxx
@@ -51,9 +51,9 @@ public:
     static const sal_uInt16*      GetRanges();
     const SfxItemSet*   GetOutputItemSet() const { return pOutSet; }
 
-    void                SetPrevHdl( const Link<>& rLink )
+    void                SetPrevHdl( const Link<SvxPostItDialog&,void>& rLink )
                             { aPrevHdlLink = rLink; }
-    void                SetNextHdl( const Link<>& rLink )
+    void                SetNextHdl( const Link<SvxPostItDialog&,void>& rLink )
                             { aNextHdlLink = rLink; }
 
     void EnableTravel(bool bNext, bool bPrev);
@@ -91,8 +91,8 @@ private:
     const SfxItemSet&   rSet;
     SfxItemSet*         pOutSet;
 
-    Link<>              aPrevHdlLink;
-    Link<>              aNextHdlLink;
+    Link<SvxPostItDialog&,void>  aPrevHdlLink;
+    Link<SvxPostItDialog&,void>  aNextHdlLink;
 
     DECL_LINK_TYPED(Stamp, Button*, void);
     DECL_LINK_TYPED(OKHdl, Button*, void);


More information about the Libreoffice-commits mailing list