From 32067f0a10362276b1812fd1c0b8bbf265ff6031 Mon Sep 17 00:00:00 2001 From: sirakaba Date: Sun, 10 Feb 2013 01:35:34 +0000 Subject: [PATCH] =?utf8?q?Lychee=E3=81=8B=E3=82=89=E3=81=AEDnD=E3=81=8C?= =?utf8?q?=E3=81=A7=E3=81=8D=E3=81=AA=E3=81=8F=E3=81=AA=E3=81=A3=E3=81=A6?= =?utf8?q?=E3=81=84=E3=81=9F=E3=83=90=E3=82=B0=E3=82=92=E4=BF=AE=E6=AD=A3?= =?utf8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/tpi/tpi@635 9df91469-1e22-0410-86e7-ea8537beb833 --- src/lychee/dlg_process.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/lychee/dlg_process.cpp b/src/lychee/dlg_process.cpp index a0aecfe..bc81267 100644 --- a/src/lychee/dlg_process.cpp +++ b/src/lychee/dlg_process.cpp @@ -89,6 +89,7 @@ void ProcessDialog::OnInit(wxInitDialogEvent &) // 2回目以降は何もせず終了。 return; } + MainFrame * frm_main = (MainFrame *) this->hParent; // XRCと結びつけ。 this->ebTarget = XRCCTRL(* this, "ebTarget", wxTextCtrl); @@ -103,11 +104,11 @@ void ProcessDialog::OnInit(wxInitDialogEvent &) TPI_PROCESSINFO piInfo; piInfo.eMessage = TPI_MESSAGE_STATUS; piInfo.eStatus = 0x1000; - piInfo.fiInfo.fnFileName = ((MainFrame *) this->hParent)->fnArchive; + piInfo.fiInfo.fnFileName = frm_main->fnArchive; piInfo.fiInfo.nUnpackedSize = this->nFileCount; this->CallbackProc(TPI_NOTIFY_COMMON, & piInfo); - if (((MainFrame *) this->hParent)->conf.ReadId(CONF_PROCESS_DLG, false)) + if (frm_main->conf.ReadId(CONF_PROCESS_DLG, false)) { // 旧来の進捗ダイアログを表示。 // ここでOnInitが呼ばれるので、OnInitの最初で無効化している。 @@ -115,7 +116,6 @@ void ProcessDialog::OnInit(wxInitDialogEvent &) } // ウインドウの機能を無効化。 - MainFrame * frm_main = (MainFrame *) this->hParent; frm_main->tree_ctrl->Freeze(); frm_main->list_ctrl->Freeze(); frm_main->menubar->EnableTop(0, false); @@ -124,7 +124,7 @@ void ProcessDialog::OnInit(wxInitDialogEvent &) frm_main->toolbar->Enable(false); #ifdef __WINDOWS__ // タスクバー。 - this->hTBWnd = this->hParent->GetHandle(); + this->hTBWnd = frm_main->GetHandle(); ::CoCreateInstance(CLSID_TaskbarList, NULL, CLSCTX_INPROC_SERVER, IID_ITaskbarList3, (void **) & this->tlTaskbar); if (this->tlTaskbar != NULL) @@ -213,7 +213,7 @@ int ProcessDialog::CallbackProc(unsigned int _uMsg, void * _pStructure) this->ebSource->ChangeValue(piInfo->fiInfo.fnFileName.GetFullPath()); this->Update(); ((MainFrame *) this->hParent)->gFrame->Show(); - ::wxSafeYield(this->hParent, true); +// ::wxSafeYield(this->hParent, true); case 0x1001: // 閲覧時は最初にファイル数が分からないので、ここで設定。 this->gArchive->SetRange(piInfo->fiInfo.nUnpackedSize); ((MainFrame *) this->hParent)->gFrame->SetRange(piInfo->fiInfo.nUnpackedSize); @@ -221,24 +221,24 @@ int ProcessDialog::CallbackProc(unsigned int _uMsg, void * _pStructure) #ifdef __WINDOWS__ s_nFileCount = piInfo->fiInfo.nUnpackedSize; #endif -// sw.Start(); + sw.Start(); if (piInfo->eStatus == 0x1001) { this->fOpen = true; } break; case 0x1002: // 各ファイルの処理を開始。 -// if (sw.Time() > 500) + if (sw.Time() > 500) { if (this->IsShownOnScreen()) { -// sw.Start(); + sw.Start(); this->ebTarget->ChangeValue(piInfo->fiInfo.fnFileName.GetFullPath()); this->gArchive->SetValue(piInfo->nProcessedSize); this->Update(); // ::wxSafeYield(this, true); } -// ::wxSafeYield(this->hParent, true); + ::wxSafeYield(this->hParent, true); } ((MainFrame *) this->hParent)->gFrame->SetValue(piInfo->nProcessedSize); #ifdef __WINDOWS__ -- 2.11.0