X-Git-Url: https://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fvwindowgui.C;h=e1524d6dd269adbadd1a6b276b09a4dbbb769070;hb=413642aafb5e96e9c72b53312176838526fbfd97;hp=52ef387e38dae4295bb698777a7f5839fce105d4;hpb=3bf30d220f7855b995b887dc10812ae3780e6805;p=goodguy%2Fcinelerra.git diff --git a/cinelerra-5.1/cinelerra/vwindowgui.C b/cinelerra-5.1/cinelerra/vwindowgui.C index 52ef387e..e1524d6d 100644 --- a/cinelerra-5.1/cinelerra/vwindowgui.C +++ b/cinelerra-5.1/cinelerra/vwindowgui.C @@ -86,7 +86,7 @@ VWindowGUI::VWindowGUI(MWindow *mwindow, VWindow *vwindow) VWindowGUI::~VWindowGUI() { - vwindow->playback_engine->interrupt_playback(1); + vwindow->stop_playback(1); sources.remove_all_objects(); labels.remove_all_objects(); delete canvas; @@ -135,7 +135,7 @@ void VWindowGUI::draw_wave() delete cache; delete canvas->refresh_frame; canvas->refresh_frame = vframe; - canvas->draw_refresh(1); + canvas->refresh(1); } void VWindowGUI::change_source(EDL *edl, const char *title) @@ -358,7 +358,7 @@ int VWindowGUI::keypress_event() break; case 'f': unlock_window(); - if(mwindow->session->vwindow_fullscreen) + if( canvas->get_fullscreen() ) canvas->stop_fullscreen(); else canvas->start_fullscreen(); @@ -366,7 +366,7 @@ int VWindowGUI::keypress_event() break; case ESC: unlock_window(); - if(mwindow->session->vwindow_fullscreen) + if( canvas->get_fullscreen() ) canvas->stop_fullscreen(); lock_window("VWindowGUI::keypress_event 2"); break; @@ -457,7 +457,7 @@ void VWindowGUI::drag_motion() int need_highlight = cursor_above() && get_cursor_over_window() ? 1 : 0; if( highlighted == need_highlight ) return; highlighted = need_highlight; - canvas->draw_refresh(); + canvas->refresh(1); } int VWindowGUI::drag_stop() @@ -467,7 +467,7 @@ int VWindowGUI::drag_stop() if( highlighted && mwindow->session->current_operation == DRAG_ASSET ) { highlighted = 0; - canvas->draw_refresh(); + canvas->refresh(1); unlock_window(); Indexable *indexable = @@ -590,7 +590,7 @@ void VWindowEditing::set_position(double position) if( position < 0 ) position = 0; edl->local_session->set_selectionstart(position); edl->local_session->set_selectionend(position); - vwindow->update_position(CHANGE_NONE, 0, 1); + vwindow->update_position(); } } @@ -620,9 +620,7 @@ void VWindowEditing::panel_toggle_label() void VWindowEditing::panel_next_label(int cut) { if( !vwindow->get_edl() ) return; - vwindow->gui->unlock_window(); - vwindow->playback_engine->interrupt_playback(1); - vwindow->gui->lock_window("VWindowEditing::next_label"); + vwindow->interrupt_playback(1); EDL *edl = vwindow->get_edl(); Label *current = edl->labels->next_label( @@ -631,16 +629,14 @@ void VWindowEditing::panel_next_label(int cut) edl->tracks->total_length(); edl->local_session->set_selectionstart(position); edl->local_session->set_selectionend(position); - vwindow->update_position(CHANGE_NONE, 0, 1, 0); + vwindow->update_position(); vwindow->gui->timebar->update(1); } void VWindowEditing::panel_prev_label(int cut) { if( !vwindow->get_edl() ) return; - vwindow->gui->unlock_window(); - vwindow->playback_engine->interrupt_playback(1); - vwindow->gui->lock_window("VWindowEditing::prev_label"); + vwindow->interrupt_playback(1); EDL *edl = vwindow->get_edl(); Label *current = edl->labels->prev_label( @@ -648,7 +644,7 @@ void VWindowEditing::panel_prev_label(int cut) double position = !current ? 0 : current->position; edl->local_session->set_selectionstart(position); edl->local_session->set_selectionend(position); - vwindow->update_position(CHANGE_NONE, 0, 1, 0); + vwindow->update_position(); vwindow->gui->timebar->update(1); } @@ -818,9 +814,7 @@ void VWindowCanvas::zoom_resize_window(float percentage) void VWindowCanvas::close_source() { - gui->unlock_window(); - gui->vwindow->playback_engine->interrupt_playback(1); - gui->lock_window("VWindowCanvas::close_source"); + gui->vwindow->interrupt_playback(1); gui->vwindow->delete_source(1, 1); } @@ -883,13 +877,3 @@ void VWindowCanvas::draw_overlays() } } -int VWindowCanvas::get_fullscreen() -{ - return mwindow->session->vwindow_fullscreen; -} - -void VWindowCanvas::set_fullscreen(int value) -{ - mwindow->session->vwindow_fullscreen = value; -} -