Kaydet (Commit) da1d5215 authored tarafından Noel Grandin's avatar Noel Grandin

convert Link<> to typed

Change-Id: I16452cc87c48d95466a46e54619e4247742328ff
üst b9d0dc6a
......@@ -22,12 +22,12 @@
namespace svxform
{
void DelayedEvent::Call( void* _pArg )
void DelayedEvent::Call()
{
CancelPendingCall();
SAL_WARN_IF( m_nEventId != 0, "svx.form", "DelayedEvent::Call: CancelPendingCall did not work!" );
m_nEventId = Application::PostUserEvent( LINK( this, DelayedEvent, OnCall ), _pArg );
m_nEventId = Application::PostUserEvent( LINK( this, DelayedEvent, OnCall ), nullptr );
}
void DelayedEvent::CancelPendingCall()
......
......@@ -1435,12 +1435,11 @@ void FormController::toggleAutoFields(bool bAutoFields)
}
IMPL_LINK_NOARG(FormController, OnToggleAutoFields)
IMPL_LINK_NOARG_TYPED(FormController, OnToggleAutoFields, void*, void)
{
OSL_ENSURE( !impl_isDisposed_nofail(), "FormController: already disposed!" );
toggleAutoFields(m_bCurrentRecordNew);
return 1L;
}
// XTextListener
......@@ -1757,23 +1756,19 @@ void FormController::focusGained(const FocusEvent& e) throw( RuntimeException, s
}
IMPL_LINK_NOARG( FormController, OnActivated )
IMPL_LINK_NOARG_TYPED( FormController, OnActivated, void*, void )
{
EventObject aEvent;
aEvent.Source = *this;
m_aActivateListeners.notifyEach( &XFormControllerListener::formActivated, aEvent );
return 0L;
}
IMPL_LINK_NOARG( FormController, OnDeactivated )
IMPL_LINK_NOARG_TYPED( FormController, OnDeactivated, void*, void )
{
EventObject aEvent;
aEvent.Source = *this;
m_aActivateListeners.notifyEach( &XFormControllerListener::formDeactivated, aEvent );
return 0L;
}
......@@ -2613,7 +2608,7 @@ void FormController::updateAllDispatchers() const
}
IMPL_LINK_NOARG(FormController, OnLoad)
IMPL_LINK_NOARG_TYPED(FormController, OnLoad, void*, void)
{
OSL_ENSURE( !impl_isDisposed_nofail(), "FormController: already disposed!" );
m_bLocked = determineLockState();
......@@ -2626,8 +2621,6 @@ IMPL_LINK_NOARG(FormController, OnLoad)
// just one exception toggle the auto values
if (m_bCurrentRecordNew)
toggleAutoFields(true);
return 1L;
}
......
......@@ -38,7 +38,7 @@ namespace svxform
class DelayedEvent
{
public:
DelayedEvent( const Link<>& _rHandler )
DelayedEvent( const Link<void*,void>& _rHandler )
:m_aHandler( _rHandler )
,m_nEventId( 0 )
{
......@@ -53,7 +53,7 @@ namespace svxform
If there's already a call pending, this previous call is cancelled.
*/
void Call( void* _pArg = NULL );
void Call();
/** cancels a call which is currently pending
......@@ -62,7 +62,7 @@ namespace svxform
void CancelPendingCall();
private:
Link<> m_aHandler;
Link<void*,void> m_aHandler;
ImplSVEvent * m_nEventId;
private:
......
......@@ -564,10 +564,10 @@ namespace svxform
DECL_LINK_TYPED( OnActivateTabOrder, Idle*, void );
DECL_LINK_TYPED( OnInvalidateFeatures, Timer*, void );
DECL_LINK( OnLoad, void* );
DECL_LINK( OnToggleAutoFields, void* );
DECL_LINK( OnActivated, void* );
DECL_LINK( OnDeactivated, void* );
DECL_LINK_TYPED( OnLoad, void*, void );
DECL_LINK_TYPED( OnToggleAutoFields, void*, void );
DECL_LINK_TYPED( OnActivated, void*, void );
DECL_LINK_TYPED( OnDeactivated, void*, void );
};
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment