diff options
author | Robert Roth <robert.roth.off@gmail.com> | 2013-01-25 03:27:27 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-01-25 12:31:39 +0000 |
commit | 45dc5f7f4ef579c848a83f5679658977303527bb (patch) | |
tree | df6beaddf621ad1c691982390b080cda7831fc61 /cui/source/inc | |
parent | 71a8f79f4bdf567b6fce23091ca1663455cadba9 (diff) |
Object name, description dialog and messagebox ported to UI files
Change-Id: Iad23998c9ccde22abad9d894af3dd6df7c92564f
Reviewed-on: https://gerrit.libreoffice.org/1857
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'cui/source/inc')
-rw-r--r-- | cui/source/inc/cuires.hrc | 6 | ||||
-rw-r--r-- | cui/source/inc/dlgname.hxx | 56 |
2 files changed, 20 insertions, 42 deletions
diff --git a/cui/source/inc/cuires.hrc b/cui/source/inc/cuires.hrc index 8b3ce61a9868..d8d9ef0b81f8 100644 --- a/cui/source/inc/cuires.hrc +++ b/cui/source/inc/cuires.hrc @@ -245,12 +245,6 @@ #define RID_SVX_IMAPDLG_START (RID_SVX_START + 100) #define RID_SVXDLG_IMAPURL (RID_SVX_IMAPDLG_START + 2) -// name dialog -#define RID_SVXDLG_NAME (RID_SVX_START + 62) -#define RID_SVXDLG_MESSBOX (RID_SVX_START + 63) -#define RID_SVXDLG_OBJECT_NAME (RID_SVX_START + 64) -#define RID_SVXDLG_OBJECT_TITLE_DESC (RID_SVX_START + 67) - // hangulhanja #define RID_SVX_MDLG_HANGULHANJA (RID_SVX_START + 1 ) #define RID_SVX_MDLG_HANGULHANJA_OPT ( RID_SVX_START + 4 ) diff --git a/cui/source/inc/dlgname.hxx b/cui/source/inc/dlgname.hxx index de6405278136..99c89db1e0e5 100644 --- a/cui/source/inc/dlgname.hxx +++ b/cui/source/inc/dlgname.hxx @@ -32,11 +32,9 @@ class SvxNameDialog : public ModalDialog { private: - FixedText aFtDescription; - Edit aEdtName; - OKButton aBtnOK; - CancelButton aBtnCancel; - HelpButton aBtnHelp; + FixedText* pFtDescription; + Edit* pEdtName; + OKButton* pBtnOK; Link aCheckNameHdl; @@ -45,7 +43,7 @@ private: public: SvxNameDialog( Window* pWindow, const String& rName, const String& rDesc ); - void GetName( String& rName ){rName = aEdtName.GetText();} + void GetName( String& rName ){rName = pEdtName->GetText();} /** add a callback Link that is called whenever the content of the edit field is changed. The Link result determines whether the OK @@ -66,29 +64,23 @@ public: { aCheckNameHdl = rLink; if ( bCheckImmediately ) - aBtnOK.Enable( rLink.Call( this ) > 0 ); + pBtnOK->Enable( rLink.Call( this ) > 0 ); } - void SetEditHelpId( const rtl::OString& aHelpId) {aEdtName.SetHelpId(aHelpId);} + void SetEditHelpId( const rtl::OString& aHelpId) {pEdtName->SetHelpId(aHelpId);} }; /** #i68101# - Dialog for editing Object Title and Description + Dialog for editing Object name plus uniqueness-callback-linkHandler */ class SvxObjectNameDialog : public ModalDialog { private: // name - FixedText aFtName; - Edit aEdtName; - - // separator - FixedLine aFlSeparator; + Edit* pEdtName; // buttons - HelpButton aBtnHelp; - OKButton aBtnOK; - CancelButton aBtnCancel; + OKButton* pBtnOK; // callback link for name uniqueness Link aCheckNameHdl; @@ -100,7 +92,7 @@ public: SvxObjectNameDialog(Window* pWindow, const String& rName); // data access - void GetName(String& rName) {rName = aEdtName.GetText(); } + void GetName(String& rName) {rName = pEdtName->GetText(); } // set handler void SetCheckNameHdl(const Link& rLink, bool bCheckImmediately = false) @@ -109,7 +101,7 @@ public: if(bCheckImmediately) { - aBtnOK.Enable(rLink.Call(this) > 0); + pBtnOK->Enable(rLink.Call(this) > 0); } } }; @@ -120,39 +112,31 @@ class SvxObjectTitleDescDialog : public ModalDialog { private: // title - FixedText aFtTitle; - Edit aEdtTitle; + Edit* pEdtTitle; // description - FixedText aFtDescription; - MultiLineEdit aEdtDescription; - - // separator - FixedLine aFlSeparator; + MultiLineEdit* pEdtDescription; // buttons - HelpButton aBtnHelp; - OKButton aBtnOK; - CancelButton aBtnCancel; + OKButton* pBtnOK; public: // constructor SvxObjectTitleDescDialog(Window* pWindow, const String& rTitle, const String& rDesc); // data access - void GetTitle(String& rTitle) {rTitle = aEdtTitle.GetText(); } - void GetDescription(String& rDescription) {rDescription = aEdtDescription.GetText(); } + void GetTitle(String& rTitle) {rTitle = pEdtTitle->GetText(); } + void GetDescription(String& rDescription) {rDescription = pEdtDescription->GetText(); } }; /// Dialog to cancel, save, or add class SvxMessDialog : public ModalDialog { private: - FixedText aFtDescription; - PushButton aBtn1; - PushButton aBtn2; - CancelButton aBtnCancel; - FixedImage aFtImage; + FixedText* pFtDescription; + PushButton* pBtn1; + PushButton* pBtn2; + FixedImage* pFtImage; Image* pImage; DECL_LINK(Button1Hdl, void *); |