diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-10-05 18:36:38 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-10-06 22:14:17 +0200 |
commit | 48595c805dd5b917e9bd01ad1c2deb4a047c5f7b (patch) | |
tree | f1dd7b638b78694cd5ac635e0de6be3ca1d13042 /sc/source | |
parent | 4b28b77eddfe48e709180f1ab81ac0d996796471 (diff) |
Related: tdf#127935 set default activate handler to toggle row expansion
Change-Id: I2bbfb1445b8d2e748f642cdf4723d41b7f072e2b
Reviewed-on: https://gerrit.libreoffice.org/80305
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/ui/condformat/condformatmgr.cxx | 6 | ||||
-rw-r--r-- | sc/source/ui/dbgui/PivotLayoutTreeList.cxx | 8 | ||||
-rw-r--r-- | sc/source/ui/dbgui/PivotLayoutTreeListData.cxx | 6 | ||||
-rw-r--r-- | sc/source/ui/dbgui/pvfundlg.cxx | 9 | ||||
-rw-r--r-- | sc/source/ui/dbgui/scuiimoptdlg.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/inc/PivotLayoutTreeList.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/PivotLayoutTreeListData.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/condformatmgr.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/lbseldlg.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/pvfundlg.hxx | 8 | ||||
-rw-r--r-- | sc/source/ui/inc/scuiautofmt.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/scuiimoptdlg.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/shtabdlg.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/inc/solveroptions.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/miscdlgs/lbseldlg.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/miscdlgs/scuiautofmt.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/miscdlgs/shtabdlg.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/miscdlgs/solveroptions.cxx | 3 |
18 files changed, 41 insertions, 28 deletions
diff --git a/sc/source/ui/condformat/condformatmgr.cxx b/sc/source/ui/condformat/condformatmgr.cxx index 1ac76ac319b1..a8206a3d1d7a 100644 --- a/sc/source/ui/condformat/condformatmgr.cxx +++ b/sc/source/ui/condformat/condformatmgr.cxx @@ -136,17 +136,17 @@ IMPL_LINK_NOARG(ScCondFormatManagerDlg, EditBtnClickHdl, weld::Button&, void) EditBtnHdl(*m_xTreeView); } -IMPL_LINK_NOARG(ScCondFormatManagerDlg, EditBtnHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScCondFormatManagerDlg, EditBtnHdl, weld::TreeView&, bool) { ScConditionalFormat* pFormat = m_xCtrlManager->GetSelection(); if (!pFormat) - return; + return true; m_bModified = true; m_xDialog->response( DLG_RET_EDIT ); - return; + return true; } IMPL_LINK_NOARG(ScCondFormatManagerDlg, AddBtnHdl, weld::Button&, void) diff --git a/sc/source/ui/dbgui/PivotLayoutTreeList.cxx b/sc/source/ui/dbgui/PivotLayoutTreeList.cxx index 6882a19ee6e7..e9a16a33b729 100644 --- a/sc/source/ui/dbgui/PivotLayoutTreeList.cxx +++ b/sc/source/ui/dbgui/PivotLayoutTreeList.cxx @@ -34,17 +34,17 @@ void ScPivotLayoutTreeList::Setup(ScPivotLayoutDialog* pParent, SvPivotTreeListT meType = eType; } -IMPL_LINK_NOARG(ScPivotLayoutTreeList, DoubleClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScPivotLayoutTreeList, DoubleClickHdl, weld::TreeView&, bool) { int nEntry = mxControl->get_cursor_index(); if (nEntry == -1) - return; + return true; ScItemValue* pCurrentItemValue = reinterpret_cast<ScItemValue*>(mxControl->get_id(nEntry).toInt64()); ScPivotFuncData& rCurrentFunctionData = pCurrentItemValue->maFunctionData; if (mpParent->IsDataElement(rCurrentFunctionData.mnCol)) - return; + return true; SCCOL nCurrentColumn = rCurrentFunctionData.mnCol; ScDPLabelData& rCurrentLabelData = mpParent->GetLabelData(nCurrentColumn); @@ -62,6 +62,8 @@ IMPL_LINK_NOARG(ScPivotLayoutTreeList, DoubleClickHdl, weld::TreeView&, void) pDialog->FillLabelData(rCurrentLabelData); rCurrentFunctionData.mnFuncMask = pDialog->GetFuncMask(); } + + return true; } void ScPivotLayoutTreeList::FillFields(ScPivotFieldVector& rFieldVector) diff --git a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx index dec6a897ee95..cde29f02034a 100644 --- a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx +++ b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx @@ -71,11 +71,11 @@ ScPivotLayoutTreeListData::ScPivotLayoutTreeListData(std::unique_ptr<weld::TreeV ScPivotLayoutTreeListData::~ScPivotLayoutTreeListData() {} -IMPL_LINK_NOARG(ScPivotLayoutTreeListData, DoubleClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScPivotLayoutTreeListData, DoubleClickHdl, weld::TreeView&, bool) { int nEntry = mxControl->get_cursor_index(); if (nEntry == -1) - return; + return true; ScItemValue* pCurrentItemValue = reinterpret_cast<ScItemValue*>(mxControl->get_id(nEntry).toInt64()); ScPivotFuncData& rCurrentFunctionData = pCurrentItemValue->maFunctionData; @@ -106,6 +106,8 @@ IMPL_LINK_NOARG(ScPivotLayoutTreeListData, DoubleClickHdl, weld::TreeView&, void mxControl->set_text(nEntry, sDataItemName); } + + return true; } void ScPivotLayoutTreeListData::FillDataField(ScPivotFieldVector& rDataFields) diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx index a082dbfdd544..f9df9a244eb7 100644 --- a/sc/source/ui/dbgui/pvfundlg.cxx +++ b/sc/source/ui/dbgui/pvfundlg.cxx @@ -438,9 +438,10 @@ IMPL_LINK( ScDPFunctionDlg, SelectHdl, weld::ComboBox&, rLBox, void ) } } -IMPL_LINK_NOARG(ScDPFunctionDlg, DblClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScDPFunctionDlg, DblClickHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } ScDPSubtotalDlg::ScDPSubtotalDlg(weld::Widget* pParent, ScDPObject& rDPObj, @@ -529,9 +530,10 @@ IMPL_LINK(ScDPSubtotalDlg, RadioClickHdl, weld::Button&, rBtn, void) mxLbFunc->set_sensitive(&rBtn == mxRbUser.get()); } -IMPL_LINK_NOARG(ScDPSubtotalDlg, DblClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScDPSubtotalDlg, DblClickHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } IMPL_LINK(ScDPSubtotalDlg, ClickHdl, weld::Button&, rBtn, void) @@ -905,9 +907,10 @@ OUString ScDPShowDetailDlg::GetDimensionName() const return mrDPObj.GetDimName(nDim, bIsDataLayout); } -IMPL_LINK_NOARG(ScDPShowDetailDlg, DblClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScDPShowDetailDlg, DblClickHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/dbgui/scuiimoptdlg.cxx b/sc/source/ui/dbgui/scuiimoptdlg.cxx index 0a0d8b2b884b..03fce13e6fbc 100644 --- a/sc/source/ui/dbgui/scuiimoptdlg.cxx +++ b/sc/source/ui/dbgui/scuiimoptdlg.cxx @@ -317,9 +317,10 @@ IMPL_LINK_NOARG(ScImportOptionsDlg, FixedWidthHdl, weld::ToggleButton&, void) m_xCbQuoteAll->set_sensitive( bEnable ); } -IMPL_LINK_NOARG(ScImportOptionsDlg, DoubleClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScImportOptionsDlg, DoubleClickHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } void ScImportOptionsDlg::SaveImportOptions() const diff --git a/sc/source/ui/inc/PivotLayoutTreeList.hxx b/sc/source/ui/inc/PivotLayoutTreeList.hxx index 02120e7b4812..42f090faa5d9 100644 --- a/sc/source/ui/inc/PivotLayoutTreeList.hxx +++ b/sc/source/ui/inc/PivotLayoutTreeList.hxx @@ -21,7 +21,7 @@ private: std::vector<std::unique_ptr<ScItemValue> > maItemValues; DECL_LINK(KeyInputHdl, const KeyEvent&, bool); - DECL_LINK(DoubleClickHdl, weld::TreeView&, void); + DECL_LINK(DoubleClickHdl, weld::TreeView&, bool); public: ScPivotLayoutTreeList(std::unique_ptr<weld::TreeView> xControl); diff --git a/sc/source/ui/inc/PivotLayoutTreeListData.hxx b/sc/source/ui/inc/PivotLayoutTreeListData.hxx index c9f9dce4366c..c5a3fb07ce44 100644 --- a/sc/source/ui/inc/PivotLayoutTreeListData.hxx +++ b/sc/source/ui/inc/PivotLayoutTreeListData.hxx @@ -20,7 +20,7 @@ class ScPivotLayoutTreeListData final : public ScPivotLayoutTreeListBase { private: DECL_LINK(KeyInputHdl, const KeyEvent&, bool); - DECL_LINK(DoubleClickHdl, weld::TreeView&, void); + DECL_LINK(DoubleClickHdl, weld::TreeView&, bool); public: ScPivotLayoutTreeListData(std::unique_ptr<weld::TreeView> xControl); diff --git a/sc/source/ui/inc/condformatmgr.hxx b/sc/source/ui/inc/condformatmgr.hxx index 94bbf346cb1d..02e904b3c255 100644 --- a/sc/source/ui/inc/condformatmgr.hxx +++ b/sc/source/ui/inc/condformatmgr.hxx @@ -63,7 +63,7 @@ private: DECL_LINK(RemoveBtnHdl, weld::Button&, void); DECL_LINK(EditBtnClickHdl, weld::Button&, void); DECL_LINK(AddBtnHdl, weld::Button&, void); - DECL_LINK(EditBtnHdl, weld::TreeView&, void); + DECL_LINK(EditBtnHdl, weld::TreeView&, bool); }; #endif diff --git a/sc/source/ui/inc/lbseldlg.hxx b/sc/source/ui/inc/lbseldlg.hxx index fc78c8a77367..62bec0d291c5 100644 --- a/sc/source/ui/inc/lbseldlg.hxx +++ b/sc/source/ui/inc/lbseldlg.hxx @@ -27,7 +27,7 @@ class ScSelEntryDlg : public weld::GenericDialogController private: std::unique_ptr<weld::TreeView> m_xLb; - DECL_LINK(DblClkHdl, weld::TreeView&, void); + DECL_LINK(DblClkHdl, weld::TreeView&, bool); public: ScSelEntryDlg(weld::Window* pParent, const std::vector<OUString> &rEntryList); diff --git a/sc/source/ui/inc/pvfundlg.hxx b/sc/source/ui/inc/pvfundlg.hxx index 19b1d49cb164..47891ece7a8d 100644 --- a/sc/source/ui/inc/pvfundlg.hxx +++ b/sc/source/ui/inc/pvfundlg.hxx @@ -41,7 +41,7 @@ public: void set_sensitive(bool sensitive) { m_xControl->set_sensitive(sensitive); } void set_selection_mode(SelectionMode eMode) { m_xControl->set_selection_mode(eMode); } - void connect_row_activated(const Link<weld::TreeView&, void>& rLink) { m_xControl->connect_row_activated(rLink); } + void connect_row_activated(const Link<weld::TreeView&, bool>& rLink) { m_xControl->connect_row_activated(rLink); } int get_height_rows(int nRows) const { return m_xControl->get_height_rows(nRows); } void set_size_request(int nWidth, int nHeight) { m_xControl->set_size_request(nWidth, nHeight); } @@ -70,7 +70,7 @@ private: sal_Int32 FindBaseItemPos( const OUString& rEntry, sal_Int32 nStartPos ) const; DECL_LINK(SelectHdl, weld::ComboBox&, void); - DECL_LINK(DblClickHdl, weld::TreeView&, void); + DECL_LINK(DblClickHdl, weld::TreeView&, bool); private: std::unique_ptr<ScDPFunctionListBox> mxLbFunc; @@ -103,7 +103,7 @@ public: private: void Init( const ScDPLabelData& rLabelData, const ScPivotFuncData& rFuncData ); - DECL_LINK( DblClickHdl, weld::TreeView&, void ); + DECL_LINK( DblClickHdl, weld::TreeView&, bool ); DECL_LINK( RadioClickHdl, weld::Button&, void ); DECL_LINK( ClickHdl, weld::Button&, void ); @@ -191,7 +191,7 @@ public: OUString GetDimensionName() const; private: - DECL_LINK(DblClickHdl, weld::TreeView&, void); + DECL_LINK(DblClickHdl, weld::TreeView&, bool); private: typedef std::unordered_map<OUString, long> DimNameIndexMap; diff --git a/sc/source/ui/inc/scuiautofmt.hxx b/sc/source/ui/inc/scuiautofmt.hxx index 6ddaf400ac94..3b05ec1dfd60 100644 --- a/sc/source/ui/inc/scuiautofmt.hxx +++ b/sc/source/ui/inc/scuiautofmt.hxx @@ -70,7 +70,7 @@ private: DECL_LINK( RemoveHdl, weld::Button&, void ); DECL_LINK( SelFmtHdl, weld::TreeView&, void ); DECL_LINK( CloseHdl, weld::Button&, void ); - DECL_LINK( DblClkHdl, weld::TreeView&, void ); + DECL_LINK( DblClkHdl, weld::TreeView&, bool ); DECL_LINK( RenameHdl, weld::Button&, void ); }; diff --git a/sc/source/ui/inc/scuiimoptdlg.hxx b/sc/source/ui/inc/scuiimoptdlg.hxx index fff65114ec98..b100410bf620 100644 --- a/sc/source/ui/inc/scuiimoptdlg.hxx +++ b/sc/source/ui/inc/scuiimoptdlg.hxx @@ -70,7 +70,7 @@ private: void FillFromDbTextEncodingMap(bool bExcludeImportSubsets, sal_uInt32 nExcludeInfoFlags = 0); DECL_LINK(FixedWidthHdl, weld::ToggleButton&, void); - DECL_LINK(DoubleClickHdl, weld::TreeView&, void); + DECL_LINK(DoubleClickHdl, weld::TreeView&, bool); }; #endif diff --git a/sc/source/ui/inc/shtabdlg.hxx b/sc/source/ui/inc/shtabdlg.hxx index 37d69ba07a36..0143ad73a690 100644 --- a/sc/source/ui/inc/shtabdlg.hxx +++ b/sc/source/ui/inc/shtabdlg.hxx @@ -28,7 +28,7 @@ private: std::unique_ptr<weld::Frame> m_xFrame; std::unique_ptr<weld::TreeView> m_xLb; - DECL_LINK( DblClkHdl, weld::TreeView&, void ); + DECL_LINK( DblClkHdl, weld::TreeView&, bool ); public: ScShowTabDlg(weld::Window* pParent); diff --git a/sc/source/ui/inc/solveroptions.hxx b/sc/source/ui/inc/solveroptions.hxx index 18bc0ab3012a..41875a07b7d5 100644 --- a/sc/source/ui/inc/solveroptions.hxx +++ b/sc/source/ui/inc/solveroptions.hxx @@ -67,7 +67,7 @@ class ScSolverOptionsDialog : public weld::GenericDialogController DECL_LINK( EngineSelectHdl, weld::ComboBox&, void ); DECL_LINK( SettingsSelHdl, weld::TreeView&, void ); - DECL_LINK( SettingsDoubleClickHdl, weld::TreeView&, void ); + DECL_LINK( SettingsDoubleClickHdl, weld::TreeView&, bool ); DECL_LINK( ButtonHdl, weld::Button&, void ); void ReadFromComponent(); diff --git a/sc/source/ui/miscdlgs/lbseldlg.cxx b/sc/source/ui/miscdlgs/lbseldlg.cxx index 67adcb1dbe9a..4c0b592c7073 100644 --- a/sc/source/ui/miscdlgs/lbseldlg.cxx +++ b/sc/source/ui/miscdlgs/lbseldlg.cxx @@ -45,9 +45,10 @@ OUString ScSelEntryDlg::GetSelectedEntry() const return m_xLb->get_selected_text(); } -IMPL_LINK_NOARG(ScSelEntryDlg, DblClkHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScSelEntryDlg, DblClkHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/miscdlgs/scuiautofmt.cxx b/sc/source/ui/miscdlgs/scuiautofmt.cxx index f933fc0ffa41..82d80da27619 100644 --- a/sc/source/ui/miscdlgs/scuiautofmt.cxx +++ b/sc/source/ui/miscdlgs/scuiautofmt.cxx @@ -141,12 +141,14 @@ IMPL_LINK(ScAutoFormatDlg, CloseHdl, weld::Button&, rBtn, void) } } -IMPL_LINK_NOARG(ScAutoFormatDlg, DblClkHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScAutoFormatDlg, DblClkHdl, weld::TreeView&, bool) { if ( bCoreDataChanged ) ScGlobal::GetOrCreateAutoFormat()->Save(); m_xDialog->response( RET_OK ); + + return true; } IMPL_LINK(ScAutoFormatDlg, CheckHdl, weld::ToggleButton&, rBtn, void) diff --git a/sc/source/ui/miscdlgs/shtabdlg.cxx b/sc/source/ui/miscdlgs/shtabdlg.cxx index ee21149bd988..71e4fa0d1c03 100644 --- a/sc/source/ui/miscdlgs/shtabdlg.cxx +++ b/sc/source/ui/miscdlgs/shtabdlg.cxx @@ -63,9 +63,10 @@ OUString ScShowTabDlg::GetEntry(sal_Int32 nIndex) const return m_xLb->get_text(nIndex); } -IMPL_LINK_NOARG(ScShowTabDlg, DblClkHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScShowTabDlg, DblClkHdl, weld::TreeView&, bool) { m_xDialog->response(RET_OK); + return true; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/ui/miscdlgs/solveroptions.cxx b/sc/source/ui/miscdlgs/solveroptions.cxx index 33cfc826fd06..40efcef60260 100644 --- a/sc/source/ui/miscdlgs/solveroptions.cxx +++ b/sc/source/ui/miscdlgs/solveroptions.cxx @@ -278,9 +278,10 @@ IMPL_LINK( ScSolverOptionsDialog, ButtonHdl, weld::Button&, rBtn, void ) EditOption(); } -IMPL_LINK_NOARG(ScSolverOptionsDialog, SettingsDoubleClickHdl, weld::TreeView&, void) +IMPL_LINK_NOARG(ScSolverOptionsDialog, SettingsDoubleClickHdl, weld::TreeView&, bool) { EditOption(); + return true; } IMPL_LINK_NOARG(ScSolverOptionsDialog, EngineSelectHdl, weld::ComboBox&, void) |