[Libreoffice-commits] core.git: 5 commits - chart2/source include/svx sw/source
Noel Grandin
noel at peralex.com
Fri Oct 16 05:38:50 PDT 2015
chart2/source/controller/dialogs/res_LegendPosition.cxx | 2 -
chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx | 3 --
chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx | 2 -
chart2/source/controller/inc/res_LegendPosition.hxx | 4 +-
include/svx/dialcontrol.hxx | 3 --
sw/source/ui/dbui/mmaddressblockpage.cxx | 3 --
sw/source/ui/dbui/mmaddressblockpage.hxx | 2 -
sw/source/ui/index/cnttab.cxx | 11 +++++--
sw/source/uibase/cctrl/popbox.cxx | 12 --------
sw/source/uibase/dbui/mailmergehelper.cxx | 4 +-
sw/source/uibase/inc/mailmergehelper.hxx | 4 +-
sw/source/uibase/inc/popbox.hxx | 5 ---
sw/source/uibase/inc/swuicnttab.hxx | 14 +++++-----
13 files changed, 25 insertions(+), 44 deletions(-)
New commits:
commit a8248293c301e6804dfbe195c9a9be39e4328480
Author: Noel Grandin <noel at peralex.com>
Date: Fri Oct 16 14:12:04 2015 +0200
convert Link<> to typed
Change-Id: I9ce3a85eb5eba35691c376d19436c624df68be33
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index 08e32af..57b0732 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -2017,9 +2017,13 @@ void SwTOXEntryTabPage::dispose()
// pVoid is used as signal to change all levels of the example
IMPL_LINK_TYPED(SwTOXEntryTabPage, ModifyClickHdl, Button*, pVoid, void)
{
- ModifyHdl(pVoid);
+ OnModify(pVoid);
}
-IMPL_LINK(SwTOXEntryTabPage, ModifyHdl, void*, pVoid)
+IMPL_LINK_NOARG_TYPED(SwTOXEntryTabPage, ModifyHdl, LinkParamNone*, void)
+{
+ OnModify(nullptr);
+}
+void SwTOXEntryTabPage::OnModify(void* pVoid)
{
UpdateDescriptor();
@@ -2032,7 +2036,6 @@ IMPL_LINK(SwTOXEntryTabPage, ModifyHdl, void*, pVoid)
pTOXDlg->CreateOrUpdateExample(
pTOXDlg->GetCurrentTOXType().eType, TOX_PAGE_ENTRY, nCurLevel);
}
- return 0;
}
bool SwTOXEntryTabPage::FillItemSet( SfxItemSet* )
@@ -2362,7 +2365,7 @@ IMPL_LINK_NOARG_TYPED(SwTOXEntryTabPage, AllLevelsHdl, Button*, void)
for(sal_uInt16 i = 1; i < m_pCurrentForm->GetFormMax(); i++)
m_pCurrentForm->SetPattern(i, sNewToken);
- ModifyHdl(this);
+ OnModify(this);
}
}
diff --git a/sw/source/uibase/inc/swuicnttab.hxx b/sw/source/uibase/inc/swuicnttab.hxx
index 4d51f43..0a81436 100644
--- a/sw/source/uibase/inc/swuicnttab.hxx
+++ b/sw/source/uibase/inc/swuicnttab.hxx
@@ -258,9 +258,9 @@ class SwTokenWindow : public VclHBox, public VclBuilderContainer
OUString aButtonTexts[TOKEN_END]; // Text of the buttons
OUString aButtonHelpTexts[TOKEN_END]; // QuickHelpText of the buttons
OUString sCharStyle;
- Link<SwFormToken&,void> aButtonSelectedHdl;
- VclPtr<Control> pActiveCtrl;
- Link<> aModifyHdl;
+ Link<SwFormToken&,void> aButtonSelectedHdl;
+ VclPtr<Control> pActiveCtrl;
+ Link<LinkParamNone*,void> aModifyHdl;
OUString accessibleName;
OUString sAdditionalAccnameString1;
OUString sAdditionalAccnameString2;
@@ -301,10 +301,9 @@ public:
void SetButtonSelectedHdl(const Link<SwFormToken&,void>& rLink)
{ aButtonSelectedHdl = rLink;}
- void SetModifyHdl(const Link<>& rLink){aModifyHdl = rLink;}
+ void SetModifyHdl(const Link<LinkParamNone*,void>& rLink){aModifyHdl = rLink;}
- Control* GetActiveControl()
- { return pActiveCtrl;}
+ Control* GetActiveControl() { return pActiveCtrl; }
void InsertAtSelection(const OUString& rText, const SwFormToken& aToken);
void RemoveControl(SwTOXButton* pDel, bool bInternalCall = false);
@@ -429,7 +428,8 @@ class SwTOXEntryTabPage : public SfxTabPage
void WriteBackLevel();
void UpdateDescriptor();
- DECL_LINK(ModifyHdl, void*);
+ DECL_LINK_TYPED(ModifyHdl, LinkParamNone*, void);
+ void OnModify(void*);
DECL_LINK_TYPED(ModifyClickHdl, Button*, void);
using SfxTabPage::ActivatePage;
commit 5ba32287aebc1e4d3a1e114699cb1b479d3f13f7
Author: Noel Grandin <noel at peralex.com>
Date: Fri Oct 16 13:58:01 2015 +0200
remove unused Link<> field
Change-Id: Idfd163528b173b7428a3febfde271762a9d31d03
diff --git a/sw/source/uibase/cctrl/popbox.cxx b/sw/source/uibase/cctrl/popbox.cxx
index ded277b..6a1f301 100644
--- a/sw/source/uibase/cctrl/popbox.cxx
+++ b/sw/source/uibase/cctrl/popbox.cxx
@@ -28,18 +28,6 @@ SwHelpToolBox::SwHelpToolBox( SwNavigationPI* pParent, const ResId& rResId )
{
}
-void SwHelpToolBox::MouseButtonDown(const MouseEvent &rEvt)
-{
- // If doubleclick is detected use doubleclick handler
- if(rEvt.GetButtons() == MOUSE_RIGHT &&
- 0 == GetItemId(rEvt.GetPosPixel()))
- {
- aRightClickLink.Call(const_cast<MouseEvent *>(&rEvt));
- }
- else
- ToolBox::MouseButtonDown(rEvt);
-}
-
SwHelpToolBox::~SwHelpToolBox() {}
sal_Int8 SwHelpToolBox::AcceptDrop( const AcceptDropEvent& rEvt )
diff --git a/sw/source/uibase/inc/popbox.hxx b/sw/source/uibase/inc/popbox.hxx
index 43b6ce3..7793755 100644
--- a/sw/source/uibase/inc/popbox.hxx
+++ b/sw/source/uibase/inc/popbox.hxx
@@ -26,12 +26,7 @@ class SwNavigationPI;
class SwHelpToolBox: public ToolBox, public DropTargetHelper
{
- Link<> aRightClickLink; // link gets mouse event as parameter !!!
-
- using ToolBox::DoubleClick;
-
protected:
- virtual void MouseButtonDown(const MouseEvent &rEvt) override;
virtual sal_Int8 AcceptDrop( const AcceptDropEvent& rEvt ) override;
virtual sal_Int8 ExecuteDrop( const ExecuteDropEvent& rEvt ) override;
commit 08e7bc6abd93947627e7a38646a02f9d44ddabed
Author: Noel Grandin <noel at peralex.com>
Date: Fri Oct 16 13:54:40 2015 +0200
convert Link<> to typed
Change-Id: Iea90c0e46902936bde3b51475292999fa0ead934
diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx
index 3eaf0e8..3a0cf44 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.cxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.cxx
@@ -248,7 +248,7 @@ IMPL_LINK_TYPED(SwMailMergeAddressBlockPage, AddressBlockHdl_Impl, Button*, pBox
m_pWizard->UpdateRoadmap();
}
-IMPL_LINK_NOARG(SwMailMergeAddressBlockPage, AddressBlockSelectHdl_Impl)
+IMPL_LINK_NOARG_TYPED(SwMailMergeAddressBlockPage, AddressBlockSelectHdl_Impl, LinkParamNone*, void)
{
const sal_uInt16 nSel = m_pSettingsWIN->GetSelectedAddress();
const uno::Sequence< OUString> aBlocks =
@@ -258,7 +258,6 @@ IMPL_LINK_NOARG(SwMailMergeAddressBlockPage, AddressBlockSelectHdl_Impl)
m_pWizard->GetConfigItem().SetCurrentAddressBlockIndex( nSel );
GetWizard()->UpdateRoadmap();
GetWizard()->enableButtons(WizardButtonFlags::NEXT, GetWizard()->isStateEnabled(MM_GREETINGSPAGE));
- return 0;
}
IMPL_LINK_TYPED(SwMailMergeAddressBlockPage, HideParagraphsHdl_Impl, Button*, pBox, void)
diff --git a/sw/source/ui/dbui/mmaddressblockpage.hxx b/sw/source/ui/dbui/mmaddressblockpage.hxx
index f91287a..b046df8 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.hxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.hxx
@@ -68,7 +68,7 @@ class SwMailMergeAddressBlockPage : public svt::OWizardPage
DECL_LINK_TYPED(AssignHdl_Impl, Button*, void);
DECL_LINK_TYPED(AddressBlockHdl_Impl, Button*, void);
DECL_LINK_TYPED(InsertDataHdl_Impl, Button*, void);
- DECL_LINK(AddressBlockSelectHdl_Impl, void *);
+ DECL_LINK_TYPED(AddressBlockSelectHdl_Impl, LinkParamNone*, void);
DECL_LINK_TYPED(HideParagraphsHdl_Impl, Button*, void);
void EnableAddressBlock(bool bAll, bool bSelective);
diff --git a/sw/source/uibase/dbui/mailmergehelper.cxx b/sw/source/uibase/dbui/mailmergehelper.cxx
index f6da0d2..22160a2 100644
--- a/sw/source/uibase/dbui/mailmergehelper.cxx
+++ b/sw/source/uibase/dbui/mailmergehelper.cxx
@@ -379,7 +379,7 @@ void SwAddressPreview::MouseButtonDown( const MouseEvent& rMEvt )
pImpl->nSelectedAddress != (sal_uInt16)nSelect)
{
pImpl->nSelectedAddress = (sal_uInt16)nSelect;
- m_aSelectHdl.Call(this);
+ m_aSelectHdl.Call(nullptr);
}
Invalidate();
}
@@ -422,7 +422,7 @@ void SwAddressPreview::KeyInput( const KeyEvent& rKEvt )
pImpl->nSelectedAddress != (sal_uInt16)nSelect)
{
pImpl->nSelectedAddress = (sal_uInt16)nSelect;
- m_aSelectHdl.Call(this);
+ m_aSelectHdl.Call(nullptr);
Invalidate();
}
}
diff --git a/sw/source/uibase/inc/mailmergehelper.hxx b/sw/source/uibase/inc/mailmergehelper.hxx
index a707fa5..a1cdbf6 100644
--- a/sw/source/uibase/inc/mailmergehelper.hxx
+++ b/sw/source/uibase/inc/mailmergehelper.hxx
@@ -61,7 +61,7 @@ class SW_DLLPUBLIC SwAddressPreview : public vcl::Window
{
VclPtr<ScrollBar> aVScrollBar;
SwAddressPreview_Impl* pImpl;
- Link<> m_aSelectHdl;
+ Link<LinkParamNone*,void> m_aSelectHdl;
void DrawText_Impl(vcl::RenderContext& rRenderContext, const OUString& rAddress,
const Point& rTopLeft, const Size& rSize, bool bIsSelected);
@@ -109,7 +109,7 @@ public:
static OUString FillData(const OUString& rAddress, SwMailMergeConfigItem& rConfigItem,
const css::uno::Sequence<OUString>* pAssignments = 0);
- void SetSelectHdl (const Link<>& rLink) { m_aSelectHdl = rLink; }
+ void SetSelectHdl (const Link<LinkParamNone*,void>& rLink) { m_aSelectHdl = rLink; }
};
// iterate over an address block or a greeting line the iterator returns the
commit 945965e525afb4b86d235822fff39de43b5f3f9a
Author: Noel Grandin <noel at peralex.com>
Date: Fri Oct 16 13:48:41 2015 +0200
convert Link<> to typed
Change-Id: I51d39d9d1688c4c734cd132213ef654fdc7d9b8e
diff --git a/chart2/source/controller/dialogs/res_LegendPosition.cxx b/chart2/source/controller/dialogs/res_LegendPosition.cxx
index 8202e1a..d9445e3 100644
--- a/chart2/source/controller/dialogs/res_LegendPosition.cxx
+++ b/chart2/source/controller/dialogs/res_LegendPosition.cxx
@@ -234,7 +234,7 @@ IMPL_LINK_TYPED( LegendPositionResources, PositionChangeHdl, RadioButton&, rRadi
m_aChangeLink.Call(NULL);
}
-void LegendPositionResources::SetChangeHdl( const Link<>& rLink )
+void LegendPositionResources::SetChangeHdl( const Link<LinkParamNone*,void>& rLink )
{
m_aChangeLink = rLink;
}
diff --git a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx
index 982bacb..bbb96df 100644
--- a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx
+++ b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx
@@ -154,11 +154,10 @@ IMPL_LINK_NOARG_TYPED(TitlesAndObjectsTabPage, ChangeEditHdl, Edit&, void)
{
ChangeHdl(NULL);
}
-IMPL_LINK_NOARG(TitlesAndObjectsTabPage, ChangeHdl)
+IMPL_LINK_NOARG_TYPED(TitlesAndObjectsTabPage, ChangeHdl, LinkParamNone*, void)
{
if( m_bCommitToModel )
commitToModel();
- return 0;
}
bool TitlesAndObjectsTabPage::canAdvance() const
diff --git a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx
index 8cf86a5..639ca60 100644
--- a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx
+++ b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx
@@ -53,7 +53,7 @@ public:
protected:
void commitToModel();
- DECL_LINK( ChangeHdl, void* );
+ DECL_LINK_TYPED( ChangeHdl, LinkParamNone*, void );
DECL_LINK_TYPED( ChangeEditHdl, Edit&, void );
DECL_LINK_TYPED( ChangeCheckBoxHdl, CheckBox&, void );
diff --git a/chart2/source/controller/inc/res_LegendPosition.hxx b/chart2/source/controller/inc/res_LegendPosition.hxx
index 348045d..e8d70e0 100644
--- a/chart2/source/controller/inc/res_LegendPosition.hxx
+++ b/chart2/source/controller/inc/res_LegendPosition.hxx
@@ -48,7 +48,7 @@ public:
void initFromItemSet( const SfxItemSet& rInAttrs );
void writeToItemSet( SfxItemSet& rOutAttrs ) const;
- void SetChangeHdl( const Link<>& rLink );
+ void SetChangeHdl( const Link<LinkParamNone*,void>& rLink );
DECL_LINK_TYPED( PositionEnableHdl, CheckBox&, void );
DECL_LINK_TYPED( PositionChangeHdl, RadioButton&, void );
@@ -67,7 +67,7 @@ private:
VclPtr<RadioButton> m_pRbtTop;
VclPtr<RadioButton> m_pRbtBottom;
- Link<> m_aChangeLink;
+ Link<LinkParamNone*,void> m_aChangeLink;
};
} //namespace chart
commit 877149f21c625a6583c6b11198a7adeed0e5128a
Author: Noel Grandin <noel at peralex.com>
Date: Fri Oct 16 13:46:44 2015 +0200
remove unimplemented and private method
Change-Id: Ic0d869720890b21c65e7736326d9bd0ee53cada0
diff --git a/include/svx/dialcontrol.hxx b/include/svx/dialcontrol.hxx
index bcc5c03..d400e08b 100644
--- a/include/svx/dialcontrol.hxx
+++ b/include/svx/dialcontrol.hxx
@@ -156,9 +156,6 @@ protected:
private:
void InvalidateControl();
- void ImplSetFieldLink( const Link<>& rLink );
-
-
DECL_LINK_TYPED( LinkedFieldModifyHdl, Edit&, void );
DECL_LINK_TYPED( LinkedFieldFocusHdl, Control&, void );
void LinkedFieldModifyHdl();
More information about the Libreoffice-commits
mailing list