X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fpatchgui.C;h=9ae8c4ef8cae7068ac69c36ac5d00d205321cd6f;hb=803cf48f8f7ee246eb5473e55fc2125e8b398250;hp=a2a19864703cb2cb9ff1c6b46b8c3ec741fe675f;hpb=0513350234a8dcd08e5a0117d5121724ef7b76b6;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/cinelerra/patchgui.C b/cinelerra-5.1/cinelerra/patchgui.C index a2a19864..9ae8c4ef 100644 --- a/cinelerra-5.1/cinelerra/patchgui.C +++ b/cinelerra-5.1/cinelerra/patchgui.C @@ -425,6 +425,10 @@ int RecordPatch::button_press_event() get_value(), this, &patch->track->record); + patch->title->set_back_color(patch->track->record ? + get_resources()->text_background : + get_resources()->text_background_disarmed); + patch->title->set_text_row(0); return 1; } return 0; @@ -658,19 +662,23 @@ int ExpandPatch::button_release_event() } - - - TitlePatch::TitlePatch(MWindow *mwindow, PatchGUI *patch, int x, int y) - : BC_TextBox(x, - y, - patch->patchbay->get_w() - 10, - 1, - patch->track->title, - 1, MEDIUMFONT, 1) + : BC_TextBox(x, y, patch->patchbay->get_w() - 10, 1, + patch->track->title, 1, MEDIUMFONT, 1) { this->mwindow = mwindow; this->patch = patch; + set_back_color(patch->track->record ? + get_resources()->text_background : + get_resources()->text_background_disarmed); +} + +void TitlePatch::update(const char *text) +{ + set_back_color(patch->track->record ? + get_resources()->text_background : + get_resources()->text_background_disarmed); + BC_TextBox::update(text); } int TitlePatch::handle_event() @@ -684,13 +692,6 @@ int TitlePatch::handle_event() } - - - - - - - NudgePatch::NudgePatch(MWindow *mwindow, PatchGUI *patch, int x,