| 104 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 105 |  | EVT_MENU( wxID_ABOUT, MainWindow::OnAboutClick ) | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 106 |  |  | 
 
 
 
 
 
 
 
 | 107 | + | EVT_BUTTON( Dir_Button, MainWindow::OnDirButtonClick ) | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 108 |  | ////@end MainWindow event table entries | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 109 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 110 |  | END_EVENT_TABLE() | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 115 |  | */ | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 116 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 117 |  | MainWindow::MainWindow() | 
 
 
 
 
 
 
 
 
 
 
 | 118 | < | { | 
 
 
 
 
 
 
 
 
 | 118 | > | { | 
 
 
 
 
 
 
 
 
 
 
 | 119 |  | Init(); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 120 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 121 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 175 |  | SeperatedRadio = NULL; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 176 |  | CompleteRadio = NULL; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 177 |  | ReglobalizeButton = NULL; | 
 
 
 
 
 
 
 
 | 178 | + |  | 
 
 
 
 
 
 
 
 | 179 | + | ChangeDirectoryButton = NULL; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 180 |  | ////@end MainWindow member initialisation | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 181 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 182 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 352 |  | ReglobalizeButton->SetName(_T("Reglobalize_Button")); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 353 |  | itemBoxSizer34->Add(ReglobalizeButton, 0, wxGROW|wxALL, 5); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 354 |  |  | 
 
 
 
 
 
 
 
 
 
 
 | 355 | < | // Connect events and objects | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 355 | > | wxStaticLine* itemStaticLine100 = new wxStaticLine( OptionsPanel, wxID_STATIC, wxDefaultPosition, wxDefaultSize, wxLI_VERTICAL ); | 
 
 
 
 
 | 356 | > | itemBoxSizer25->Add(itemStaticLine100, 0, wxGROW|wxALL, 5); | 
 
 
 
 
 | 357 | > |  | 
 
 
 
 
 | 358 | > | ChangeDirectoryButton =  new wxButton( OptionsPanel, Dir_Button, _("Change Dir"), wxDefaultPosition, wxDefaultSize, 0 ); | 
 
 
 
 
 | 359 | > | ChangeDirectoryButton->SetName(_T("Dir_Button")); | 
 
 
 
 
 | 360 | > | itemBoxSizer34->Add(ChangeDirectoryButton, 0, wxGROW|wxALL, 5); | 
 
 
 
 
 | 361 | > |  | 
 
 
 
 
 | 362 | > | // Connect events and objects | 
 
 
 
 
 
 
 
 
 
 
 | 363 |  | Mods_CheckboxList->Connect(Mods_CheckboxList1, wxEVT_CREATE, wxWindowCreateEventHandler(MainWindow::ModList_OnCreate), NULL, this); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 364 |  | ////@end MainWindow content construction | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 365 |  | #ifdef WIN32 | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 626 |  | // Before editing this code, remove the block markers. | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 627 |  | // TODO: Make About window work again! | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 628 |  | About* window = new About(this); | 
 
 
 
 
 
 
 
 | 629 | + | window->ShowModal(); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 630 |  | window->Destroy(); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 631 |  | ////@end wxEVT_COMMAND_MENU_SELECTED event handler for wxID_ABOUT in MainWindow. | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 632 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 634 |  | /* | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 635 |  | * wxEVT_COMMAND_RADIOBUTTON_SELECTED event handler for NoSep_RadioButton | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 636 |  | */ | 
 
 
 
 
 
 
 
 
 
 
 | 637 | < |  | 
 
 
 
 
 
 
 
 
 | 637 | > |  | 
 
 
 
 
 
 
 
 
 
 
 | 638 |  | void MainWindow::OnNoSepRadioButtonSelected( wxCommandEvent& event ) | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 639 |  | { | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 640 |  | static_cast<string>("-import:nosep"); | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 668 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 669 |  | void MainWindow::OnRefreshButtonClick( wxCommandEvent& event ) | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 670 |  | { | 
 
 
 
 
 
 
 
 | 671 | + | globalPackages = getPackages(); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 672 |  | refreshMods(globalInstalledMods); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 673 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 674 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 789 |  | { | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 790 |  | splitInstances = true; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 791 |  | } | 
 
 
 
 
 
 
 
 | 792 | + |  | 
 
 
 
 
 
 
 
 | 793 | + | void MainWindow::OnDirButtonClick( wxCommandEvent& event ) | 
 
 
 
 
 
 
 
 | 794 | + | { | 
 
 
 
 
 
 
 
 | 795 | + | wxDirDialog* newDir = new wxDirDialog(this, "Set current directory", "", wxDD_DEFAULT_STYLE, | 
 
 
 
 
 
 
 
 | 796 | + | wxDefaultPosition, wxDefaultSize, "wxDirCtrl"); | 
 
 
 
 
 
 
 
 | 797 | + | newDir->ShowModal(); | 
 
 
 
 
 
 
 
 | 798 | + | if(newDir->GetPath()[0]) current_path( (path)newDir->GetPath() ); | 
 
 
 
 
 
 
 
 | 799 | + | OnRefreshButtonClick(event); | 
 
 
 
 
 
 
 
 | 800 | + | } |