diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2015-09-24 13:53:17 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2015-09-24 16:19:37 +0000 |
commit | e85b2333bce7b1dcae73861df6d90b48b9f4efe5 (patch) | |
tree | 21d066cecfbfda9ace96b26953ddcc3ae1764001 /sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx | |
parent | ff6462e6307e6924dc6c8178043ae9032f4b4152 (diff) |
convert Link<> to typed
Change-Id: I59d325c3b051690303a5841907317122fa1ec98b
Reviewed-on: https://gerrit.libreoffice.org/18825
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx')
-rw-r--r-- | sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx | 29 |
1 files changed, 13 insertions, 16 deletions
diff --git a/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx b/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx index 44fdfecc3cc0..16816f5a0f89 100644 --- a/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx +++ b/sc/source/ui/StatisticsDialogs/StatisticsTwoVariableDialog.cxx @@ -95,7 +95,7 @@ void ScStatisticsTwoVariableDialog::Init() mpButtonOk->SetClickHdl( LINK( this, ScStatisticsTwoVariableDialog, OkClicked ) ); mpButtonOk->Enable(false); - Link<> aLink = LINK( this, ScStatisticsTwoVariableDialog, GetFocusHandler ); + Link<Control&,void> aLink = LINK( this, ScStatisticsTwoVariableDialog, GetFocusHandler ); mpVariable1RangeEdit->SetGetFocusHdl( aLink ); mpVariable1RangeButton->SetGetFocusHdl( aLink ); mpVariable2RangeEdit->SetGetFocusHdl( aLink ); @@ -111,10 +111,10 @@ void ScStatisticsTwoVariableDialog::Init() mpOutputRangeEdit->SetLoseFocusHdl( aLink ); mpOutputRangeButton->SetLoseFocusHdl( aLink ); - aLink = LINK( this, ScStatisticsTwoVariableDialog, RefInputModifyHandler); - mpVariable1RangeEdit->SetModifyHdl( aLink); - mpVariable2RangeEdit->SetModifyHdl( aLink); - mpOutputRangeEdit->SetModifyHdl( aLink); + Link<> aLink2 = LINK( this, ScStatisticsTwoVariableDialog, RefInputModifyHandler); + mpVariable1RangeEdit->SetModifyHdl( aLink2); + mpVariable2RangeEdit->SetModifyHdl( aLink2); + mpOutputRangeEdit->SetModifyHdl( aLink2); mpOutputRangeEdit->GrabFocus(); @@ -211,35 +211,32 @@ IMPL_LINK_NOARG_TYPED( ScStatisticsTwoVariableDialog, OkClicked, Button*, void ) Close(); } -IMPL_LINK( ScStatisticsTwoVariableDialog, GetFocusHandler, Control*, pCtrl ) +IMPL_LINK_TYPED( ScStatisticsTwoVariableDialog, GetFocusHandler, Control&, rCtrl, void ) { mpActiveEdit = NULL; - if( pCtrl == mpVariable1RangeEdit - || pCtrl == mpVariable1RangeButton ) + if( &rCtrl == mpVariable1RangeEdit + || &rCtrl == mpVariable1RangeButton ) { mpActiveEdit = mpVariable1RangeEdit; } - else if( pCtrl == mpVariable2RangeEdit - || pCtrl == mpVariable2RangeButton ) + else if( &rCtrl == mpVariable2RangeEdit + || &rCtrl == mpVariable2RangeButton ) { mpActiveEdit = mpVariable2RangeEdit; } - else if( pCtrl == mpOutputRangeEdit - || pCtrl == mpOutputRangeButton ) + else if( &rCtrl == mpOutputRangeEdit + || &rCtrl == mpOutputRangeButton ) { mpActiveEdit = mpOutputRangeEdit; } if( mpActiveEdit ) mpActiveEdit->SetSelection( Selection( 0, SELECTION_MAX ) ); - - return 0; } -IMPL_LINK_NOARG( ScStatisticsTwoVariableDialog, LoseFocusHandler ) +IMPL_LINK_NOARG_TYPED( ScStatisticsTwoVariableDialog, LoseFocusHandler, Control&, void ) { mDialogLostFocus = !IsActive(); - return 0; } IMPL_LINK_NOARG_TYPED( ScStatisticsTwoVariableDialog, GroupByChanged, RadioButton&, void ) |