added "Open Program Folder" button to smpackage
This commit is contained in:
@@ -48,6 +48,7 @@ BEGIN_MESSAGE_MAP(CSmpackageExportDlg, CDialog)
|
||||
ON_BN_CLICKED(IDC_BUTTON_PLAY, OnButtonPlay)
|
||||
ON_BN_CLICKED(IDC_BUTTON_EDIT, OnButtonEdit)
|
||||
ON_CBN_SELCHANGE(IDC_COMBO_DIR, OnSelchangeComboDir)
|
||||
ON_BN_CLICKED(IDC_BUTTON_OPEN, OnButtonOpen)
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
@@ -495,3 +496,32 @@ void CSmpackageExportDlg::RefreshTree()
|
||||
if( m_tree.GetItemText(aItems[i]).CompareNoCase("CVS")==0 )
|
||||
m_tree.DeleteItem( aItems[i] );
|
||||
}
|
||||
|
||||
void CSmpackageExportDlg::OnButtonOpen()
|
||||
{
|
||||
// TODO: Add your control notification handler code here
|
||||
|
||||
char szCurDir[MAX_PATH];
|
||||
GetCurrentDirectory( MAX_PATH, szCurDir );
|
||||
|
||||
char szCommandToExecute[MAX_PATH] = "explorer ";
|
||||
strcat( szCommandToExecute, szCurDir );
|
||||
|
||||
|
||||
PROCESS_INFORMATION pi;
|
||||
STARTUPINFO si;
|
||||
ZeroMemory( &si, sizeof(si) );
|
||||
|
||||
CreateProcess(
|
||||
NULL, // pointer to name of executable module
|
||||
szCommandToExecute, // pointer to command line string
|
||||
NULL, // process security attributes
|
||||
NULL, // thread security attributes
|
||||
false, // handle inheritance flag
|
||||
0, // creation flags
|
||||
NULL, // pointer to new environment block
|
||||
NULL, // pointer to current directory name
|
||||
&si, // pointer to STARTUPINFO
|
||||
&pi // pointer to PROCESS_INFORMATION
|
||||
);
|
||||
}
|
||||
|
||||
@@ -52,6 +52,7 @@ protected:
|
||||
afx_msg void OnButtonPlay();
|
||||
afx_msg void OnButtonEdit();
|
||||
afx_msg void OnSelchangeComboDir();
|
||||
afx_msg void OnButtonOpen();
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
};
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#define IDC_BUTTON_EXPORT_AS_ONE 1002
|
||||
#define IDC_BUTTON_BACK 1003
|
||||
#define IDC_BUTTON_EXPORT_AS_INDIVIDUAL 1003
|
||||
#define IDC_BUTTON_OPEN 1004
|
||||
#define IDC_EDIT_MESSAGE1 1005
|
||||
#define IDC_EDIT_MESSAGE3 1006
|
||||
#define IDC_EDIT_MESSAGE2 1007
|
||||
|
||||
@@ -13,10 +13,10 @@ Class2=CSmpackageDlg
|
||||
|
||||
ResourceCount=5
|
||||
Resource1=IDR_MAINFRAME
|
||||
Resource2=IDD_EXPORTER
|
||||
Resource2=IDD_DIALOG_NAME
|
||||
Class3=CSMPackageInstallDlg
|
||||
Class4=CSmpackageExportDlg
|
||||
Resource3=IDD_DIALOG_NAME
|
||||
Resource3=IDD_EXPORTER
|
||||
Class5=EnterName
|
||||
Resource4=IDD_INSTALL
|
||||
Class6=EditInsallations
|
||||
@@ -68,7 +68,7 @@ VirtualFilter=dWC
|
||||
[DLG:IDD_EXPORTER]
|
||||
Type=1
|
||||
Class=CSmpackageExportDlg
|
||||
ControlCount=9
|
||||
ControlCount=10
|
||||
Control1=IDOK,button,1342242817
|
||||
Control2=IDC_BUTTON_PLAY,button,1342242816
|
||||
Control3=IDC_BUTTON_EXPORT_AS_ONE,button,1342242816
|
||||
@@ -78,6 +78,7 @@ Control6=IDC_TREE,SysTreeView32,1350631687
|
||||
Control7=IDC_COMBO_DIR,combobox,1344339971
|
||||
Control8=IDC_BUTTON_EDIT,button,1342242816
|
||||
Control9=IDC_STATIC,static,1342308352
|
||||
Control10=IDC_BUTTON_OPEN,button,1342242816
|
||||
|
||||
[CLS:CSmpackageExportDlg]
|
||||
Type=0
|
||||
@@ -85,7 +86,7 @@ HeaderFile=SmpackageExportDlg.h
|
||||
ImplementationFile=SmpackageExportDlg.cpp
|
||||
BaseClass=CDialog
|
||||
Filter=D
|
||||
LastObject=IDC_COMBO_DIR
|
||||
LastObject=IDC_BUTTON_PLAY
|
||||
VirtualFilter=dWC
|
||||
|
||||
[DLG:IDD_DIALOG_NAME]
|
||||
|
||||
@@ -116,6 +116,7 @@ BEGIN
|
||||
WS_VSCROLL | WS_TABSTOP
|
||||
PUSHBUTTON "Edit Installations",IDC_BUTTON_EDIT,253,39,71,14
|
||||
LTEXT "Select Installation:",IDC_STATIC,7,42,66,11
|
||||
PUSHBUTTON "Open Program Folder",IDC_BUTTON_OPEN,83,215,79,15
|
||||
END
|
||||
|
||||
IDD_DIALOG_NAME DIALOG DISCARDABLE 0, 0, 261, 58
|
||||
|
||||
Reference in New Issue
Block a user