X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fmwindowgui.C;h=613c0324a8c5033b5c23aba53b09efb643597a19;hb=564227981f9c1b021445fa0352b75c7670172912;hp=3c0213af123398ae6e6449d5de74f8f23270b86b;hpb=4b6c39e6cf4a3fd9c1b347db6de686ab55d6cac8;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/cinelerra/mwindowgui.C b/cinelerra-5.1/cinelerra/mwindowgui.C index 3c0213af..613c0324 100644 --- a/cinelerra-5.1/cinelerra/mwindowgui.C +++ b/cinelerra-5.1/cinelerra/mwindowgui.C @@ -320,12 +320,8 @@ void MWindowGUI::create_objects() if(debug) printf("MWindowGUI::create_objects %d\n", __LINE__); add_subwindow(mainclock = new MainClock(mwindow, - mwindow->theme->mclock_x, - mwindow->theme->mclock_y, + mwindow->theme->mclock_x, mwindow->theme->mclock_y, mwindow->theme->mclock_w)); - mainclock->set_position_offset( (double) - (mwindow->edl->session->get_frame_offset() / - mwindow->edl->session->frame_rate)); if(debug) printf("MWindowGUI::create_objects %d\n", __LINE__); mainclock->update(0); @@ -920,16 +916,19 @@ int MWindowGUI::visible(int64_t x1, int64_t x2, int64_t view_x1, int64_t view_x2 void MWindowGUI::show_message(const char *message, int color) { - statusbar->set_message(message, color); + statusbar->show_message(message, color); } -void MWindowGUI::set_default_message(const char *message) + +void MWindowGUI::update_default_message() { - statusbar->set_default_message(message); + statusbar->update_default_message(); } + void MWindowGUI::reset_default_message() { statusbar->reset_default_message(); } + void MWindowGUI::default_message() { statusbar->default_message(); @@ -1169,6 +1168,16 @@ int MWindowGUI::keypress_event() result = 1; break; + case 'k': case 'K': + if( alt_down() ) break; + unlock_window(); + mbuttons->transport->handle_transport(STOP, 1, 0, 0); + lock_window("MWindowGUI::keypress_event 1"); + mwindow->nearest_plugin_keyframe(shift_down(), + !ctrl_down() ? PLAY_FORWARD : PLAY_REVERSE); + result = 1; + break; + case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': if( !alt_down() || shift_down() ) break; @@ -2237,6 +2246,23 @@ void MWindowGUI::draw_trackmovement() } +void MWindowGUI::update_mixers(Track *track, int v) +{ + for( int i=0; ipatchbay; + if( !patchbay ) continue; + for( int j=0; jpatches.total; ++j ) { + PatchGUI *patchgui = patchbay->patches.values[j]; + if( !patchgui->mix ) continue; + if( !track || patchgui->track == track ) { + patchgui->mix->update(v>=0 ? v : + mwindow->mixer_track_active(patchgui->track)); + } + } + } +} + PaneButton::PaneButton(MWindow *mwindow, int x, int y) : BC_Button(x, y, mwindow->theme->get_image_set("pane")) { @@ -2283,9 +2309,7 @@ FFMpegToggle::FFMpegToggle(MWindow *mwindow, MButtons *mbuttons, int x, int y) { this->mwindow = mwindow; this->mbuttons = mbuttons; - set_tooltip(!get_value() ? - _("Currently: Try FFMpeg last\n Click to: Try FFMpeg first") : - _("Currently: Try FFMpeg first\n Click to: Try FFMpeg last")); + set_tooltip(get_value() ? FFMPEG_EARLY_TIP : FFMPEG_LATE_TIP); } FFMpegToggle::~FFMpegToggle() @@ -2295,12 +2319,10 @@ FFMpegToggle::~FFMpegToggle() int FFMpegToggle::handle_event() { int ffmpeg_early_probe = get_value(); - set_tooltip(!ffmpeg_early_probe ? - _("Currently: Try FFMpeg last\n Click to: Try FFMpeg first") : - _("Currently: Try FFMpeg first\n Click to: Try FFMpeg last")); + set_tooltip(ffmpeg_early_probe ? FFMPEG_EARLY_TIP : FFMPEG_LATE_TIP); mwindow->preferences->set_file_probe_armed("FFMPEG_Early", ffmpeg_early_probe); mwindow->preferences->set_file_probe_armed("FFMPEG_Late", !ffmpeg_early_probe); - + mwindow->show_warning(&mwindow->preferences->warn_indexes, _("Changing the base codecs may require rebuilding indexes.")); return 1;