summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-01-22 16:53:17 (GMT)
committerCaolán McNamara <caolanm@redhat.com>2013-01-22 16:57:44 (GMT)
commitc892615bfcfe1e6412c026d810c2bb411c3bbd30 (patch)
treed9c6f52c7bbc254433f2b61dc876acbe45d5697a
parent1b995cd4a6af8e8be60419ce76b7463ded72af8d (diff)
Tutorial step #5 convert first remaining widget
taking m_aBP_OK as a standalone example: 1. Change OKButton m_aBP_OK in header to OKButton* m_pBP_OK; 1.1. Remove m_aBP_OK ctor call and change to get(<pointer>, "name in .ui file"), e.g. get(m_aBP_OK, "ok"); 1.1. Mass-convert calls from "m_aBP_OK." to "m_pBP_OK->" e.g. :%s/m_aBP_OK./m_pBP_OK->/g 1.2. Search for anyremaining m_aBP_OK instances and adapt Change-Id: Iadb3ed674413c0b8eca3ba7a00bafaab112d8ff5
-rw-r--r--svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.cxx4
-rw-r--r--svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.hxx2
2 files changed, 3 insertions, 3 deletions
diff --git a/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.cxx b/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.cxx
index 1293d40..825a5af 100644
--- a/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.cxx
+++ b/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.cxx
@@ -50,9 +50,9 @@ ChineseTranslationDialog::ChineseTranslationDialog( Window* pParent )
, m_aRB_To_Traditional( this, TextConversionDlgs_ResId( RB_TO_TRADITIONAL ) )
, m_aCB_Translate_Commonterms( this, TextConversionDlgs_ResId( CB_TRANSLATE_COMMONTERMS ) )
, m_aPB_Editterms( this, TextConversionDlgs_ResId( PB_EDITTERMS ) )
- , m_aBP_OK( this, TextConversionDlgs_ResId( PB_OK ) )
, m_pDictionaryDialog(0)
{
+ get(m_pBP_OK, "ok");
FreeResource();
m_aRB_To_Simplified.SetHelpId( HID_SVX_CHINESE_TRANSLATION_RB_CONVERSION_TO_SIMPLIFIED );
@@ -72,7 +72,7 @@ ChineseTranslationDialog::ChineseTranslationDialog( Window* pParent )
m_aCB_Translate_Commonterms.Check( bValue );
m_aPB_Editterms.SetClickHdl( LINK( this, ChineseTranslationDialog, DictionaryHdl ) );
- m_aBP_OK.SetClickHdl( LINK( this, ChineseTranslationDialog, OkHdl ) );
+ m_pBP_OK->SetClickHdl( LINK( this, ChineseTranslationDialog, OkHdl ) );
}
ChineseTranslationDialog::~ChineseTranslationDialog()
diff --git a/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.hxx b/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.hxx
index a91a966..f9c9b83 100644
--- a/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.hxx
+++ b/svx/source/unodialogs/textconversiondlgs/chinese_translationdialog.hxx
@@ -58,7 +58,7 @@ private:
CheckBox m_aCB_Translate_Commonterms;
PushButton m_aPB_Editterms;
- OKButton m_aBP_OK;
+ OKButton* m_pBP_OK;
ChineseDictionaryDialog* m_pDictionaryDialog;
};