13
0

vtl: draw cross if info-request fails in open-video preview.

This commit is contained in:
Robin Gareus 2013-04-01 18:39:15 +02:00
parent 2da10afb64
commit 922ef41995
2 changed files with 13 additions and 4 deletions

View File

@ -347,6 +347,15 @@ AddVideoDialog::auto_set_session_fps ()
return set_session_fps_checkbox.get_active();
}
void
AddVideoDialog::clear_preview_image ()
{
imgbuf->fill(RGBA_TO_UINT(0,0,0,255));
video_draw_cross(imgbuf);
preview_image->set(imgbuf);
preview_image->show();
}
void
AddVideoDialog::set_action_ok (bool yn)
{
@ -359,10 +368,7 @@ AddVideoDialog::set_action_ok (bool yn)
pi_aspect.set_text("-");
pi_fps.set_text("-");
ok_button->set_sensitive(false);
imgbuf->fill(RGBA_TO_UINT(0,0,0,255));
video_draw_cross(imgbuf);
preview_image->set(imgbuf);
preview_image->show();
clear_preview_image();
}
}
@ -563,6 +569,8 @@ AddVideoDialog::request_preview(std::string u)
pi_tcout.set_text("-");
pi_aspect.set_text("-");
pi_fps.set_text("-");
clear_preview_image();
return;
}

View File

@ -51,6 +51,7 @@ class AddVideoDialog : public ArdourDialog
void on_show ();
bool page_switch();
void set_action_ok(bool yn);
void clear_preview_image();
/* preview pane related */
void request_preview(std::string vpath);