2513d06633
Tweaks by Curt to progress bar, plus sanity checks on included uninstall box entries.
77 lines
2.5 KiB
C++
77 lines
2.5 KiB
C++
// generated by Fast Light User Interface Designer (fluid) version 1.0104
|
|
|
|
#include "fgadmin.h"
|
|
|
|
inline void FGAdminUI::cb_quit_b_i(Fl_Button*, void*) {
|
|
quit();
|
|
}
|
|
void FGAdminUI::cb_quit_b(Fl_Button* o, void* v) {
|
|
((FGAdminUI*)(o->parent()->user_data()))->cb_quit_b_i(o,v);
|
|
}
|
|
|
|
inline void FGAdminUI::cb_source_b_i(Fl_Button*, void*) {
|
|
select_install_source();
|
|
refresh_lists();
|
|
}
|
|
void FGAdminUI::cb_source_b(Fl_Button* o, void* v) {
|
|
((FGAdminUI*)(o->parent()->user_data()))->cb_source_b_i(o,v);
|
|
}
|
|
|
|
inline void FGAdminUI::cb_dest_b_i(Fl_Button*, void*) {
|
|
select_install_dest();
|
|
refresh_lists();
|
|
}
|
|
void FGAdminUI::cb_dest_b(Fl_Button* o, void* v) {
|
|
((FGAdminUI*)(o->parent()->user_data()))->cb_dest_b_i(o,v);
|
|
}
|
|
|
|
inline void FGAdminUI::cb_install_b_i(Fl_Button*, void*) {
|
|
install_selected();
|
|
}
|
|
void FGAdminUI::cb_install_b(Fl_Button* o, void* v) {
|
|
((FGAdminUI*)(o->parent()->user_data()))->cb_install_b_i(o,v);
|
|
}
|
|
|
|
inline void FGAdminUI::cb_remove_b_i(Fl_Button*, void*) {
|
|
remove_selected();
|
|
}
|
|
void FGAdminUI::cb_remove_b(Fl_Button* o, void* v) {
|
|
((FGAdminUI*)(o->parent()->user_data()))->cb_remove_b_i(o,v);
|
|
}
|
|
#include <iostream>
|
|
using std::cout;
|
|
using std::endl;
|
|
|
|
FGAdminUI::FGAdminUI() {
|
|
Fl_Double_Window* w;
|
|
{ Fl_Double_Window* o = main_window = new Fl_Double_Window(465, 435, "FlightGear Admin Wizard");
|
|
w = o;
|
|
o->user_data((void*)(this));
|
|
{ Fl_Button* o = quit_b = new Fl_Button(360, 405, 85, 25, "Quit");
|
|
o->callback((Fl_Callback*)cb_quit_b);
|
|
}
|
|
{ Fl_Button* o = source_b = new Fl_Button(5, 5, 225, 25, "Select Scenery Source ...");
|
|
o->callback((Fl_Callback*)cb_source_b);
|
|
}
|
|
source_text = new Fl_Input(5, 35, 225, 25);
|
|
{ Fl_Button* o = dest_b = new Fl_Button(235, 5, 225, 25, "Select Install Destination ...");
|
|
o->callback((Fl_Callback*)cb_dest_b);
|
|
}
|
|
dest_text = new Fl_Input(235, 35, 225, 25);
|
|
install_box = new Fl_Check_Browser(5, 65, 225, 270, "Select Files to Install");
|
|
remove_box = new Fl_Check_Browser(235, 65, 225, 270, "Select Files to Remove");
|
|
{ Fl_Button* o = install_b = new Fl_Button(20, 360, 195, 35, "Install Selected Files");
|
|
o->labelfont(1);
|
|
o->callback((Fl_Callback*)cb_install_b);
|
|
}
|
|
{ Fl_Button* o = remove_b = new Fl_Button(250, 360, 195, 35, "Remove Selected Files");
|
|
o->labelfont(1);
|
|
o->callback((Fl_Callback*)cb_remove_b);
|
|
}
|
|
{ Fl_Progress* o = progress = new Fl_Progress(20, 405, 195, 25);
|
|
o->color(FL_BACKGROUND_COLOR);
|
|
o->selection_color((Fl_Color)175);
|
|
}
|
|
o->end();
|
|
}
|
|
}
|