diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-01-30 09:55:38 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-01-30 10:00:40 +0000 |
commit | 3103445754969aaf0fdf6c29ee0318228d74b266 (patch) | |
tree | f8378439db0ae436025f619d8456916abb11348c /xmlsecurity/source | |
parent | 92c8a8fc823e8a96fb3997386364652b759a31fa (diff) |
convert view certs tabdialog to .ui
Change-Id: Iee67e273cf19a1af6c4947870bb9f131f0a6cc11
Diffstat (limited to 'xmlsecurity/source')
-rw-r--r-- | xmlsecurity/source/dialogs/certificateviewer.cxx | 25 | ||||
-rw-r--r-- | xmlsecurity/source/dialogs/certificateviewer.src | 47 | ||||
-rw-r--r-- | xmlsecurity/source/dialogs/helpids.hrc | 1 |
3 files changed, 13 insertions, 60 deletions
diff --git a/xmlsecurity/source/dialogs/certificateviewer.cxx b/xmlsecurity/source/dialogs/certificateviewer.cxx index a1586d539f40..f9ef599e0102 100644 --- a/xmlsecurity/source/dialogs/certificateviewer.cxx +++ b/xmlsecurity/source/dialogs/certificateviewer.cxx @@ -46,29 +46,30 @@ CertificateViewer::CertificateViewer( Window* _pParent, const css::uno::Reference< css::xml::crypto::XSecurityEnvironment >& _rxSecurityEnvironment, const css::uno::Reference< css::security::XCertificate >& _rXCert, bool bCheckForPrivateKey ) - :TabDialog ( _pParent, XMLSEC_RES( RID_XMLSECDLG_CERTVIEWER ) ) - ,maTabCtrl ( this, XMLSEC_RES( 1 ) ) - ,maOkBtn ( this, XMLSEC_RES( BTN_OK ) ) - ,maHelpBtn ( this, XMLSEC_RES( BTN_HELP ) ) + : TabDialog(_pParent, "ViewCertDialog", "xmlsec/ui/viewcertdialog.ui" ) { - FreeResource(); + get(mpTabCtrl, "tabcontrol"); mbCheckForPrivateKey = bCheckForPrivateKey; mxSecurityEnvironment = _rxSecurityEnvironment; mxCert = _rXCert; - maTabCtrl.SetTabPage( RID_XMLSECTP_GENERAL, new CertificateViewerGeneralTP( &maTabCtrl, this ) ); - maTabCtrl.SetTabPage( RID_XMLSECTP_DETAILS, new CertificateViewerDetailsTP( &maTabCtrl, this ) ); - maTabCtrl.SetTabPage( RID_XMLSECTP_CERTPATH, new CertificateViewerCertPathTP( &maTabCtrl, this ) ); - maTabCtrl.SetCurPageId( RID_XMLSECTP_GENERAL ); + mnGeneralId = mpTabCtrl->GetPageId("general"); + mnDetailsId = mpTabCtrl->GetPageId("details"); + mnPathId = mpTabCtrl->GetPageId("path"); + + mpTabCtrl->SetTabPage(mnGeneralId, new CertificateViewerGeneralTP( mpTabCtrl, this)); + mpTabCtrl->SetTabPage(mnDetailsId, new CertificateViewerDetailsTP( mpTabCtrl, this)); + mpTabCtrl->SetTabPage(mnPathId, new CertificateViewerCertPathTP( mpTabCtrl, this)); + mpTabCtrl->SetCurPageId(mnGeneralId); } CertificateViewer::~CertificateViewer() { - delete maTabCtrl.GetTabPage( RID_XMLSECTP_CERTPATH ); - delete maTabCtrl.GetTabPage( RID_XMLSECTP_DETAILS ); - delete maTabCtrl.GetTabPage( RID_XMLSECTP_GENERAL ); + delete mpTabCtrl->GetTabPage(mnGeneralId); + delete mpTabCtrl->GetTabPage(mnDetailsId); + delete mpTabCtrl->GetTabPage(mnPathId); } CertificateViewerTP::CertificateViewerTP( Window* _pParent, const ResId& _rResId, CertificateViewer* _pDlg ) diff --git a/xmlsecurity/source/dialogs/certificateviewer.src b/xmlsecurity/source/dialogs/certificateviewer.src index a5a6778376e3..9deabd966189 100644 --- a/xmlsecurity/source/dialogs/certificateviewer.src +++ b/xmlsecurity/source/dialogs/certificateviewer.src @@ -20,53 +20,6 @@ #include "dialogs.hrc" #include "helpids.hrc" -TabDialog RID_XMLSECDLG_CERTVIEWER -{ - HelpID = HID_XMLSEC_DLG_CERTVIEWER; - Size = MAP_APPFONT( TD_WIDTH, TD_HEIGHT ); - OutputSize = TRUE; - Closeable = TRUE; - Moveable = TRUE; - SVLook = TRUE; - - Text [ en-US ] = "View Certificate"; - TabControl 1 - { - Pos = MAP_APPFONT( TD_SP_INNERBORDER_LEFT, TD_SP_INNERBORDER_TOP ); - Size = MAP_APPFONT( TP_WIDTH, TP_HEIGHT+RIDDER_HEIGHT ); - SVLook = TRUE ; - PageList = - { - PageItem - { - Identifier = RID_XMLSECTP_GENERAL; - Text [ en-US ] = "General"; - }; - PageItem - { - Identifier = RID_XMLSECTP_DETAILS; - Text [ en-US ] = "Details"; - }; - PageItem - { - Identifier = RID_XMLSECTP_CERTPATH; - Text [ en-US ] = "Certification Path"; - }; - }; - }; - OKButton BTN_OK - { - Pos = MAP_APPFONT( CV_COL_A, CV_ROW_A ); - Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); - DefButton = TRUE; - }; - HelpButton BTN_HELP - { - Pos = MAP_APPFONT( CV_COL_C, CV_ROW_A ); - Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); - }; -}; - TabPage RID_XMLSECTP_GENERAL { HelpId = HID_XMLSEC_TP_GENERAL; diff --git a/xmlsecurity/source/dialogs/helpids.hrc b/xmlsecurity/source/dialogs/helpids.hrc index 9745f05c5439..88a772987d76 100644 --- a/xmlsecurity/source/dialogs/helpids.hrc +++ b/xmlsecurity/source/dialogs/helpids.hrc @@ -24,7 +24,6 @@ // Help-Ids -------------------------------------------------------------- -#define HID_XMLSEC_DLG_CERTVIEWER "XMLSECURITY_HID_XMLSEC_DLG_CERTVIEWER" #define HID_XMLSEC_TP_GENERAL "XMLSECURITY_HID_XMLSEC_TP_GENERAL" #define HID_XMLSEC_TP_DETAILS "XMLSECURITY_HID_XMLSEC_TP_DETAILS" #define HID_XMLSEC_TP_CERTPATH "XMLSECURITY_HID_XMLSEC_TP_CERTPATH" |