+
+
+CreateDVD_FormatItem::CreateDVD_FormatItem(CreateDVD_Format *popup,
+ int standard, const char *text)
+ : BC_MenuItem(text)
+{
+ this->popup = popup;
+ this->standard = standard;
+}
+
+CreateDVD_FormatItem::~CreateDVD_FormatItem()
+{
+}
+
+int CreateDVD_FormatItem::handle_event()
+{
+ popup->set_text(get_text());
+ popup->gui->thread->use_standard = standard;
+ return popup->handle_event();
+}
+
+
+CreateDVD_Format::CreateDVD_Format(CreateDVD_GUI *gui, int x, int y)
+ : BC_PopupMenu(x, y, 180, "", 1)
+{
+ this->gui = gui;
+}
+
+CreateDVD_Format::~CreateDVD_Format()
+{
+}
+
+void CreateDVD_Format::create_objects()
+{
+ for( int i=0; i<(int)(sizeof(dvd_formats)/sizeof(dvd_formats[0])); ++i ) {
+ int norm = dvd_formats[i].norm;
+ int aspect = dvd_formats[i].aspect;
+ char item_text[BCTEXTLEN];
+ sprintf(item_text,"%4s (%5.2f) %dx%d",
+ dvd_norms[norm].name, dvd_norms[norm].framerate,
+ dvd_aspects[aspect].w, dvd_aspects[aspect].h);
+ add_item(new CreateDVD_FormatItem(this, i, item_text));
+ }
+ set_value(gui->thread->use_standard);
+}
+
+int CreateDVD_Format::handle_event()
+{
+ gui->thread->option_presets();
+ gui->update();
+ return 1;
+}
+
+
+CreateDVD_ScaleItem::CreateDVD_ScaleItem(CreateDVD_Scale *popup,
+ int scale, const char *text)
+ : BC_MenuItem(text)
+{
+ this->popup = popup;
+ this->scale = scale;
+}
+
+CreateDVD_ScaleItem::~CreateDVD_ScaleItem()
+{
+}
+
+int CreateDVD_ScaleItem::handle_event()
+{
+ popup->gui->thread->use_scale = scale;
+ popup->set_value(scale);
+ return popup->handle_event();
+}
+
+
+CreateDVD_Scale::CreateDVD_Scale(CreateDVD_GUI *gui, int x, int y)
+ : BC_PopupMenu(x, y, 100, "", 1)
+{
+ this->gui = gui;
+}
+
+CreateDVD_Scale::~CreateDVD_Scale()
+{
+}
+
+void CreateDVD_Scale::create_objects()
+{
+
+ for( int i=0; i<(int)Rescale::n_scale_types; ++i ) {
+ add_item(new CreateDVD_ScaleItem(this, i, Rescale::scale_types[i]));
+ }
+ set_value(gui->thread->use_scale);
+}
+
+int CreateDVD_Scale::handle_event()
+{
+ gui->update();
+ return 1;
+}
+
+
+CreateDVD_MediaSize::CreateDVD_MediaSize(CreateDVD_GUI *gui, int x, int y)
+ : BC_PopupTextBox(gui, 0, 0, x, y, 70,50)
+{
+ this->gui = gui;
+}
+
+CreateDVD_MediaSize::~CreateDVD_MediaSize()
+{
+}
+
+int CreateDVD_MediaSize::handle_event()
+{
+ gui->disk_space->update();
+ return 1;
+}
+