diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-04-11 09:42:46 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-04-11 13:15:56 +0200 |
commit | e9f2e6526c68045380b64e7579b07c6064be9c58 (patch) | |
tree | 0a2e4bd234759062b4a34bfde225dcda6293c2b3 /sc/source/ui/inc/namedefdlg.hxx | |
parent | e09bf8260e17e9ab8c4524c3b3d5d617d8d89bd5 (diff) |
weld ScNameDefDlg
Change-Id: Ic5e46a0a9f03733c8e151e6dff55b7b4a3fcda34
Reviewed-on: https://gerrit.libreoffice.org/70588
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc/source/ui/inc/namedefdlg.hxx')
-rw-r--r-- | sc/source/ui/inc/namedefdlg.hxx | 49 |
1 files changed, 25 insertions, 24 deletions
diff --git a/sc/source/ui/inc/namedefdlg.hxx b/sc/source/ui/inc/namedefdlg.hxx index aa971727884c..aa9861cd278f 100644 --- a/sc/source/ui/inc/namedefdlg.hxx +++ b/sc/source/ui/inc/namedefdlg.hxx @@ -22,25 +22,9 @@ class ScDocument; class ScDocShell; class ScViewData; -class ScNameDefDlg : public ScAnyRefDlg +class ScNameDefDlg : public ScAnyRefDlgController { private: - VclPtr<Edit> m_pEdName; - - VclPtr<formula::RefEdit> m_pEdRange; - VclPtr<formula::RefButton> m_pRbRange; - - VclPtr<ListBox> m_pLbScope; - - VclPtr<CheckBox> m_pBtnRowHeader; - VclPtr<CheckBox> m_pBtnColHeader; - VclPtr<CheckBox> m_pBtnPrintArea; - VclPtr<CheckBox> m_pBtnCriteria; - - VclPtr<PushButton> m_pBtnAdd; - VclPtr<PushButton> m_pBtnCancel; - VclPtr<FixedText> m_pFtInfo; - bool const mbUndo; //if true we need to add an undo action after creating a range name ScDocument* mpDoc; ScDocShell* mpDocShell; @@ -58,33 +42,50 @@ private: std::map<OUString, ScRangeName*> maRangeMap; + std::unique_ptr<weld::Entry> m_xEdName; + + std::unique_ptr<formula::WeldRefEdit> m_xEdRange; + std::unique_ptr<formula::WeldRefButton> m_xRbRange; + + std::unique_ptr<weld::ComboBox> m_xLbScope; + + std::unique_ptr<weld::CheckButton> m_xBtnRowHeader; + std::unique_ptr<weld::CheckButton> m_xBtnColHeader; + std::unique_ptr<weld::CheckButton> m_xBtnPrintArea; + std::unique_ptr<weld::CheckButton> m_xBtnCriteria; + + std::unique_ptr<weld::Button> m_xBtnAdd; + std::unique_ptr<weld::Button> m_xBtnCancel; + std::unique_ptr<weld::Label> m_xFtInfo; + std::unique_ptr<weld::Expander> m_xExpander; + std::unique_ptr<weld::Label> m_xFtRange; + void CancelPushed(); void AddPushed(); bool IsNameValid(); bool IsFormulaValid(); - DECL_LINK( CancelBtnHdl, Button*, void ); - DECL_LINK( AddBtnHdl, Button*, void ); - DECL_LINK( NameModifyHdl, Edit&, void ); - DECL_LINK( AssignGetFocusHdl, Control&, void ); + DECL_LINK( CancelBtnHdl, weld::Button&, void ); + DECL_LINK( AddBtnHdl, weld::Button&, void ); + DECL_LINK( NameModifyHdl, weld::Entry&, void ); + DECL_LINK( AssignGetFocusHdl, formula::WeldRefEdit&, void ); protected: virtual void RefInputDone( bool bForced = false ) override; public: - ScNameDefDlg( SfxBindings* pB, SfxChildWindow* pCW, vcl::Window* pParent, + ScNameDefDlg( SfxBindings* pB, SfxChildWindow* pCW, weld::Window* pParent, const ScViewData* pViewData, const std::map<OUString, ScRangeName*>& aRangeMap, const ScAddress& aCursorPos, const bool bUndo); virtual ~ScNameDefDlg() override; - virtual void dispose() override; virtual void SetReference( const ScRange& rRef, ScDocument* pDoc ) override; virtual bool IsRefInputMode() const override; virtual void SetActive() override; - virtual bool Close() override; + virtual void Close() override; void GetNewData( OUString& rName, OUString& rScope ); }; |