mirror of
https://gitee.com/acl-dev/acl.git
synced 2024-12-14 08:50:53 +08:00
455 lines
12 KiB
C++
455 lines
12 KiB
C++
锘¿// JencodeDlg.cpp : 瀹炵幇é<E280A1>‚囦欢
|
||
//
|
||
|
||
#include "stdafx.h"
|
||
#include "Jencode.h"
|
||
#include "Gb2Utf8.h"
|
||
#include "AclTrans.h"
|
||
#include "IdxTrans.h"
|
||
#include "JencodeDlg.h"
|
||
#include "DelBOM.h"
|
||
#include "AddBOM.h"
|
||
#include "JencodeDlg.h"
|
||
#include ".\jencodedlg.h"
|
||
|
||
#ifdef _DEBUG
|
||
#define new DEBUG_NEW
|
||
#endif
|
||
|
||
#define WM_USER_TRANS_OVER WM_USER + 100
|
||
#define WM_USER_TRANS_OVER2 WM_USER + 101
|
||
|
||
// é<>¢ã„¤ç°¬æ<C2AC>´æ—‚敤绋嬪ç°éˆ¥æ»ƒå<C692>§æµœåº˜â‚¬æ¿Šå½<C3A5>é<EFBFBD>—曢ã€<C3A3>é<EFBFBD>¨„ CAboutDlg 瀵硅瘽妗†
|
||
|
||
class CAboutDlg : public CDialog
|
||
{
|
||
public:
|
||
CAboutDlg();
|
||
|
||
// 瀵硅瘽妗嗘暟鎹®
|
||
enum { IDD = IDD_ABOUTBOX };
|
||
|
||
protected:
|
||
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV é<>€îˆ›å¯”
|
||
|
||
// 瀹炵幇
|
||
protected:
|
||
DECLARE_MESSAGE_MAP()
|
||
};
|
||
|
||
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
|
||
{
|
||
}
|
||
|
||
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
|
||
{
|
||
CDialog::DoDataExchange(pDX);
|
||
}
|
||
|
||
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
|
||
END_MESSAGE_MAP()
|
||
|
||
|
||
// CJencodeDlg 瀵硅瘽妗†
|
||
|
||
|
||
|
||
CJencodeDlg::CJencodeDlg(CWnd* pParent /*=NULL*/)
|
||
: CDialog(CJencodeDlg::IDD, pParent)
|
||
, m_sIdxPath(_T(""))
|
||
, m_fsPath(_T(""))
|
||
{
|
||
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
|
||
}
|
||
|
||
void CJencodeDlg::DoDataExchange(CDataExchange* pDX)
|
||
{
|
||
CDialog::DoDataExchange(pDX);
|
||
}
|
||
|
||
BEGIN_MESSAGE_MAP(CJencodeDlg, CDialog)
|
||
ON_WM_SYSCOMMAND()
|
||
ON_WM_PAINT()
|
||
ON_WM_QUERYDRAGICON()
|
||
//}}AFX_MSG_MAP
|
||
ON_BN_CLICKED(IDC_BUTTON_GB2UTF, OnBnClickedButtonGb2utf)
|
||
ON_BN_CLICKED(IDC_BUTTON_UTF2GB, OnBnClickedButtonUtf2gb)
|
||
ON_BN_CLICKED(IDC_BUTTON2, OnBnClickedButton2)
|
||
ON_BN_CLICKED(IDC_BUTTON3, OnBnClickedButton3)
|
||
ON_MESSAGE(WM_USER_TRANS_OVER, OnTransOver)
|
||
ON_MESSAGE(WM_USER_TRANS_OVER2, OnTransOver2)
|
||
ON_BN_CLICKED(IDC_ACL_TRANS, OnBnClickedAclTrans)
|
||
ON_BN_CLICKED(IDC_ACL_RESTORE, OnBnClickedAclRestore)
|
||
ON_BN_CLICKED(IDC_IDX_SELECT, OnBnClickedIdxSelect)
|
||
ON_BN_CLICKED(IDC_TRANS_IDX, OnBnClickedTransIdx)
|
||
ON_BN_CLICKED(IDC_DEL_BOM, OnBnClickedDelBom)
|
||
ON_BN_CLICKED(IDC_BUTTON_GB2UNI, &CJencodeDlg::OnBnClickedButtonGb2uni)
|
||
ON_BN_CLICKED(IDC_ADD_BOM, &CJencodeDlg::OnBnClickedAddBom)
|
||
END_MESSAGE_MAP()
|
||
|
||
|
||
// CJencodeDlg å¨‘å Ÿä¼…æ¾¶å‹æ‚Šç»‹å¬ªç°
|
||
|
||
BOOL CJencodeDlg::OnInitDialog()
|
||
{
|
||
CDialog::OnInitDialog();
|
||
|
||
// ç<><C3A7>哱鈥滃å<C692>§æµœŽ...\鈥濊å½<C3A5>é<EFBFBD>—曢ã€<C3A3>娣诲姞é<C5BE>’扮郴ç¼<C3A7>熻å½<C3A5>é<EFBFBD>—曚腑銆‚
|
||
|
||
// IDM_ABOUTBOX 蹇呴ã€<C3A3>é<EFBFBD>¦ã„§éƒ´ç¼<C3A7>ç†·æ‡¡æµ ã‚ˆå¯–é<E28093>¥æ<C2A5>‘唴銆‚
|
||
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
|
||
ASSERT(IDM_ABOUTBOX < 0xF000);
|
||
|
||
CMenu* pSysMenu = GetSystemMenu(FALSE);
|
||
if (pSysMenu != NULL) {
|
||
CString strAboutMenu;
|
||
strAboutMenu.LoadString(IDS_ABOUTBOX);
|
||
if (!strAboutMenu.IsEmpty()) {
|
||
pSysMenu->AppendMenu(MF_SEPARATOR);
|
||
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
|
||
}
|
||
}
|
||
|
||
// ç’<C3A7>剧疆å§<C3A5>ゅ璇濇é<E280B9>¨å‹«æµ˜é<CB9C><C3A9>囥€傚綋æ<E280B9>´æ—‚敤绋嬪ç°æ¶“è<E2809C>¤ç<C2A4>¥é<C2A5>™ï½„笉é<E280B0>„璇濇é<E280B9>ƒè®¹ç´<C3A7>妗嗘ç<CB9C>¦ç<C2A6><C3A7>å—šåšœé<C593>”¨
|
||
// 鎵цå§<C3A5>ゆæ<E280A0>·æµ£œ
|
||
SetIcon(m_hIcon, TRUE); // ç’<C3A7>剧疆澶у浘é<CB9C><C3A9>‡
|
||
SetIcon(m_hIcon, FALSE); // ç’<C3A7>剧疆ç<E280A0><C3A7>忓浘é<CB9C><C3A9>‡
|
||
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞棰濆é<C2BB>¨å‹«åžµæ¿®å¬ªå¯²æµ g爜
|
||
|
||
acl::log::open("jencode.log", "jencode");
|
||
logger("started!");
|
||
|
||
//freopen("CONOUT$","w+t",stdout);
|
||
// 娣诲姞é<C5BE>˜èˆµâ‚¬ä½¹çˆ®
|
||
int aWidths[2] = {50, -1};
|
||
m_wndStatus.Create(WS_CHILD | WS_VISIBLE | WS_BORDER
|
||
| CCS_BOTTOM | SBARS_SIZEGRIP,
|
||
CRect(0,0,0,0), this, 0);
|
||
m_wndStatus.SetParts(2, aWidths);
|
||
m_wndStatus.SetText("ç<EFBFBD><EFBFBD>辩å<EFBFBD>Ž", 0, 0);
|
||
m_wndStatus.SetText("", 1, 0);
|
||
return TRUE; // 闄ら潪ç’<C3A7>å‰§ç–†æµœå—˜å¸¶æµ å‰<C3A5>殑é<E28098>’︾å<C2BE>£é”›å±½æƒ<C3A6>é<EFBFBD>’欒繑é<E28098>¥ž TRUE
|
||
}
|
||
|
||
void CJencodeDlg::OnSysCommand(UINT nID, LPARAM lParam)
|
||
{
|
||
if ((nID & 0xFFF0) == IDM_ABOUTBOX) {
|
||
CAboutDlg dlgAbout;
|
||
dlgAbout.DoModal();
|
||
} else {
|
||
CDialog::OnSysCommand(nID, lParam);
|
||
}
|
||
}
|
||
|
||
// æ¿¡å‚›ç<E280BA>‰é<E280B0>šæˆ<C3A6>璇濇娣诲姞é<C5BE>ˆâ‚¬ç<C2AC><C3A7>忓寲鎸å¤<C3A5>æŒ³é”›å±½åž¯é—‡â‚¬ç‘•ä½·ç¬…é—ˆãˆ¢æ®‘æµ ï½‡çˆœ
|
||
// é<>‰ãƒ§ç²¯é<C2AF>’惰é<C5A1>¥ç‚¬çˆ£éŠ†å‚šî‡®æµœåº<C3A5>娇é<E280A1>¢ã„¦æžƒå¦—£/瑙嗗浘妯″瀷é<C2B7>¨„ MFC æ<>´æ—‚敤绋嬪ç°é”›Œ
|
||
// æ<>©æ¬<C3A6>皢é<C2A2>¢è¾¨î”‹é<E280B9>‹æƒ°åšœé<C593>”ㄥ畬鎴愩€‚
|
||
|
||
void CJencodeDlg::OnPaint()
|
||
{
|
||
if (IsIconic()) {
|
||
CPaintDC dc(this); // é<>¢ã„¤ç°¬ç¼<C3A7>樺埗é<E28094>¨å‹®î†•æ¾¶å›¦ç¬‚涓嬫枃
|
||
|
||
SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
|
||
|
||
// 浣垮浘é<CB9C><C3A9>囧湪宸ヤ綔é<E2809D>â•<C3A2>舰涓眳涓
|
||
int cxIcon = GetSystemMetrics(SM_CXICON);
|
||
int cyIcon = GetSystemMetrics(SM_CYICON);
|
||
CRect rect;
|
||
GetClientRect(&rect);
|
||
int x = (rect.Width() - cxIcon + 1) / 2;
|
||
int y = (rect.Height() - cyIcon + 1) / 2;
|
||
|
||
// ç¼<C3A7>樺埗é<E28094>¥ç‚¬çˆ£
|
||
dc.DrawIcon(x, y, m_hIcon);
|
||
} else {
|
||
CDialog::OnPaint();
|
||
}
|
||
}
|
||
|
||
//褰撶敤鎴锋嫋é<E280B9>”ㄦ渶ç<C2B6><C3A7>忓寲ç»<C3A7>楀彛é<E280BA>ƒå‰<C3A5>郴ç¼<C3A7>熻皟é<C5B8>¢ã„¦î„<C3AE>é<EFBFBD>‘芥暟é<C5B8>™æ §ç·±é<C2B1><C3A9>夋爣é<C2A3>„剧ã<C2A7>šéŠ†‚
|
||
HCURSOR CJencodeDlg::OnQueryDragIcon()
|
||
{
|
||
return static_cast<HCURSOR>(m_hIcon);
|
||
}
|
||
|
||
void CJencodeDlg::ButtonsEnable(void)
|
||
{
|
||
GetDlgItem(IDC_BUTTON_GB2UTF)->EnableWindow(TRUE);
|
||
GetDlgItem(IDC_BUTTON_UTF2GB)->EnableWindow(TRUE);
|
||
GetDlgItem(IDC_ACL_TRANS)->EnableWindow(TRUE);
|
||
GetDlgItem(IDC_ACL_RESTORE)->EnableWindow(TRUE);
|
||
GetDlgItem(IDC_DEL_BOM)->EnableWindow(TRUE);
|
||
GetDlgItem(IDC_ADD_BOM)->EnableWindow(TRUE);
|
||
}
|
||
|
||
BOOL CJencodeDlg::CheckPath(void)
|
||
{
|
||
UpdateData(TRUE);
|
||
GetDlgItem(IDC_EDIT_SPATH)->GetWindowText(m_sPath);
|
||
//MessageBox(m_sPath);
|
||
if (m_sPath.GetLength() == 0) {
|
||
MessageBox("璇烽€夋嫨婧愮洰褰•...");
|
||
return FALSE;
|
||
}
|
||
|
||
m_dPath = m_sPath;
|
||
|
||
//GetDlgItem(IDC_EDIT_DPATH)->GetWindowText(m_dPath);
|
||
//if (m_dPath.GetLength() == 0)
|
||
//{
|
||
// MessageBox("璇烽€夋嫨é<C2A8>©î†¾æ®‘é<E28098>©î†¼ç¶<C3A7>...");
|
||
// return FALSE;
|
||
//}
|
||
|
||
return TRUE;
|
||
}
|
||
|
||
void CJencodeDlg::ButtonsDisable(void)
|
||
{
|
||
GetDlgItem(IDC_BUTTON_GB2UTF)->EnableWindow(FALSE);
|
||
GetDlgItem(IDC_BUTTON_UTF2GB)->EnableWindow(FALSE);
|
||
GetDlgItem(IDC_ACL_TRANS)->EnableWindow(FALSE);
|
||
GetDlgItem(IDC_ACL_RESTORE)->EnableWindow(FALSE);
|
||
GetDlgItem(IDC_DEL_BOM)->EnableWindow(FALSE);
|
||
GetDlgItem(IDC_ADD_BOM)->EnableWindow(FALSE);
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedButtonGb2utf()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
return;
|
||
}
|
||
|
||
static CGb2Utf8 gb2Utf8("gbk", "UTF-8");
|
||
|
||
gb2Utf8.Init(this->GetSafeHwnd(), m_sPath, m_dPath);
|
||
gb2Utf8.OnTransEnd(WM_USER_TRANS_OVER);
|
||
gb2Utf8.start();
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedButtonUtf2gb()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
MessageBox(m_sPath);
|
||
return;
|
||
}
|
||
|
||
static CGb2Utf8 utf2gb("utf-8", "gbk");
|
||
|
||
utf2gb.Init(this->GetSafeHwnd(), m_sPath, m_dPath);
|
||
utf2gb.OnTransEnd(WM_USER_TRANS_OVER);
|
||
utf2gb.start();
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedButtonGb2uni()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
MessageBox(m_sPath);
|
||
return;
|
||
}
|
||
|
||
return;
|
||
|
||
static CGb2Utf8 gb2uni("gbk", "UCS2LE");
|
||
|
||
gb2uni.Init(this->GetSafeHwnd(), m_sPath, m_dPath);
|
||
gb2uni.OnTransEnd(WM_USER_TRANS_OVER);
|
||
gb2uni.start();
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedButton2()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
CString sPath;
|
||
BROWSEINFO bi;
|
||
char name[MAX_PATH];
|
||
ZeroMemory(&bi, sizeof(BROWSEINFO));
|
||
|
||
bi.hwndOwner = GetSafeHwnd();
|
||
bi.pszDisplayName = name;
|
||
bi.lpszTitle = "Select folder";
|
||
bi.ulFlags = BIF_RETURNONLYFSDIRS;
|
||
LPITEMIDLIST idl = SHBrowseForFolder(&bi);
|
||
if(idl == NULL)
|
||
return;
|
||
SHGetPathFromIDList(idl, sPath.GetBuffer(MAX_PATH));
|
||
|
||
sPath.ReleaseBuffer();
|
||
|
||
if (sPath.Right(1) != "\\") {
|
||
sPath += "\\";
|
||
}
|
||
|
||
GetDlgItem(IDC_EDIT_SPATH)->SetWindowText(sPath);
|
||
// CFileDialog file(TRUE,"é<>‚囦欢","result.txt",OFN_HIDEREADONLY,"FILE(*.*)|*.*||",NULL);
|
||
// if(file.DoModal()==IDOK)
|
||
// {
|
||
// CString pathname;
|
||
//
|
||
// pathname=file.GetPathName();
|
||
// GetDlgItem(IDC_EDIT_SPATH)->SetWindowText(pathname);
|
||
// }
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedButton3()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
CString sPath;
|
||
BROWSEINFO bi;
|
||
char name[MAX_PATH];
|
||
ZeroMemory(&bi, sizeof(BROWSEINFO));
|
||
|
||
bi.hwndOwner = GetSafeHwnd();
|
||
bi.pszDisplayName = name;
|
||
bi.lpszTitle = "Select folder";
|
||
bi.ulFlags = BIF_RETURNONLYFSDIRS;
|
||
LPITEMIDLIST idl = SHBrowseForFolder(&bi);
|
||
if(idl == NULL)
|
||
return;
|
||
SHGetPathFromIDList(idl, sPath.GetBuffer(MAX_PATH));
|
||
|
||
sPath.ReleaseBuffer();
|
||
|
||
if (sPath.Right(1) != "\\") {
|
||
sPath += "\\";
|
||
}
|
||
|
||
GetDlgItem(IDC_EDIT_DPATH)->SetWindowText(sPath);
|
||
}
|
||
|
||
afx_msg LRESULT CJencodeDlg::OnTransOver(WPARAM uID, LPARAM lEvent)
|
||
{
|
||
CString msg;
|
||
|
||
ButtonsEnable();
|
||
msg.Format("é‘°æ¥<EFBFBD>椂锛š%d 绉’", time(NULL) - m_nBegin);
|
||
m_wndStatus.SetText("瀹屾垚", 0, 0);
|
||
m_wndStatus.SetText(msg, 1, 0);
|
||
return 0;
|
||
}
|
||
|
||
afx_msg LRESULT CJencodeDlg::OnTransOver2(WPARAM uID, LPARAM lEvent)
|
||
{
|
||
CString msg;
|
||
|
||
GetDlgItem(IDC_TRANS_IDX)->EnableWindow(TRUE);
|
||
msg.Format("é‘°æ¥<EFBFBD>椂锛š%d 绉’", time(NULL) - m_nBegin);
|
||
m_wndStatus.SetText("瀹屾垚!", 0, 0);
|
||
m_wndStatus.SetText(msg, 1, 0);
|
||
return 0;
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedAclTrans()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
return;
|
||
}
|
||
|
||
static CAclTrans aclTrans;
|
||
|
||
aclTrans.Init(this->GetSafeHwnd(), m_sPath);
|
||
aclTrans.OnTransEnd(WM_USER_TRANS_OVER);
|
||
aclTrans.Run();
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedAclRestore()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
return;
|
||
}
|
||
|
||
static CAclTrans aclTrans;
|
||
|
||
aclTrans.Init(this->GetSafeHwnd(), m_sPath);
|
||
aclTrans.OnTransEnd(WM_USER_TRANS_OVER);
|
||
aclTrans.Run(FALSE);
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedDelBom()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
return;
|
||
}
|
||
|
||
static CDelBOM delBom;
|
||
delBom.Init(this->GetSafeHwnd(), m_sPath);
|
||
delBom.OnDeleted(WM_USER_TRANS_OVER);
|
||
delBom.start();
|
||
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedAddBom()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
if (!CheckPath()) {
|
||
return;
|
||
}
|
||
|
||
static CAddBOM addBom;
|
||
addBom.Init(this->GetSafeHwnd(), m_sPath);
|
||
addBom.OnAdded(WM_USER_TRANS_OVER);
|
||
addBom.start();
|
||
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
ButtonsDisable();
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedIdxSelect()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
CFileDialog file(TRUE,"é<EFBFBD>‚囦欢","search.idx",OFN_HIDEREADONLY,"FILE(*.*)|*.*||",NULL);
|
||
if(file.DoModal()==IDOK) {
|
||
CString pathname;
|
||
|
||
pathname=file.GetPathName();
|
||
GetDlgItem(IDC_IDX_PATH)->SetWindowText(pathname);
|
||
}
|
||
}
|
||
|
||
void CJencodeDlg::OnBnClickedTransIdx()
|
||
{
|
||
// TODO: é<>¦ã„¦î„<C3AE>娣诲姞鎺т欢閫氱煡澶å‹æ‚Šç»‹å¬ªç°æµ g爜
|
||
static CIdxTrans idxTrans;
|
||
|
||
UpdateData(TRUE);
|
||
GetDlgItem(IDC_IDX_PATH)->GetWindowText(m_fsPath);
|
||
if (m_fsPath.GetLength() == 0) {
|
||
MessageBox("璇烽€夋嫨绱㈠紩é<EFBFBD>‚囦欢...");
|
||
return;
|
||
}
|
||
|
||
GetDlgItem(IDC_TRANS_IDX)->EnableWindow(FALSE);
|
||
idxTrans.Init(this->GetSafeHwnd(), m_fsPath);
|
||
idxTrans.OnTransEnd(WM_USER_TRANS_OVER2);
|
||
idxTrans.Run();
|
||
m_wndStatus.SetText("æ<EFBFBD>©æ„¯î”‘", 0, 0);
|
||
m_nBegin = time(NULL);
|
||
}
|