--- AE/Installer/trunk/source/main_window.cpp 2009/07/06 14:44:10 392 +++ AE/Installer/trunk/source/main_window.cpp 2009/07/06 19:18:00 396 @@ -1,3 +1,15 @@ +#ifndef NTDDI_VERSION +#define NTDDI_VERSION NTDDI_WIN7 +#endif +#ifdef WIN32 + #include +#include +HWND Handle; + +ITaskbarList *pTaskbarList; +ITaskbarList3 *pTaskbarList3; +#endif + /* AE/Mod Installer by Gumby and Iritscen @@ -306,7 +318,7 @@ int globalizeData(void) logfile << (strOniSplit + " " + strImportOption + " ../GameDataFolder/level" + levels[i] + "_Final packages/VanillaDats/level" + levels[i] + "_Final/level" + levels[i] + "_Final/level" + levels[i] + "_Final.oni >> Globalize.log").c_str() << '\n'; string sys_str = (strOniSplit + " " + strImportOption + " ../GameDataFolder/level" + levels[i] + "_Final packages/VanillaDats/level" + levels[i] + "_Final/level" - + levels[i] + "_Final/level" + levels[i] + "_Final.oni >> Globalize2.log"); + + levels[i] + "_Final/level" + levels[i] + "_Final.oni >> Globalize.log"); system(sys_str.c_str() ); setProgressBar( (int)(1000 * (float)(parts_done) / (float)(total_steps) )); parts_done++; @@ -1131,6 +1143,10 @@ void MainWindow::CreateControls() Mods_CheckboxList->Connect(Mods_CheckboxList1, wxEVT_CREATE, wxWindowCreateEventHandler(MainWindow::ModList_OnCreate), NULL, this); ////@end MainWindow content construction + Handle = (HWND)GetHWND(); + ::CoCreateInstance(CLSID_TaskbarList, NULL, CLSCTX_INPROC_SERVER, IID_ITaskbarList, (void **)&pTaskbarList); + + if ( exists( "../../GameDataFolder/level0_Final.sep" ) ) { strImportOption = "-import:sep"; splitInstances = NOT_SPLIT; @@ -1399,7 +1415,22 @@ void MainWindow::OnInstallButtonClick( w void setProgressBar( int i ) { //TheProgressBar->SetValue( +#ifdef WIN32 + + +if (SUCCEEDED(pTaskbarList->QueryInterface(IID_ITaskbarList3, (void **)&pTaskbarList3))) +{ + + pTaskbarList3->SetProgressValue(Handle,i, 1000); + if ( i == 0 ) { + + pTaskbarList3->SetProgressState(Handle,TBPF_NOPROGRESS); + } +} + + +#endif TheProgressBar->SetValue(i); }