X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Finterfaceprefs.C;h=5142b3b6799bf3a672396a4d7706b071cba49dcc;hb=5621db270ccbeabc106e0f438941dba6f930652b;hp=e1d69537e766c2569ea64f509db5c4e81d89e720;hpb=0ac6a1397cf8ee19cf75f3fe893c27e9f4fc0ea5;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/cinelerra/interfaceprefs.C b/cinelerra-5.1/cinelerra/interfaceprefs.C index e1d69537..5142b3b6 100644 --- a/cinelerra-5.1/cinelerra/interfaceprefs.C +++ b/cinelerra-5.1/cinelerra/interfaceprefs.C @@ -86,6 +86,11 @@ void InterfacePrefs::create_objects() add_subwindow(keyframe_reticle); keyframe_reticle->create_objects(); + y += 30; + add_subwindow(title = new BC_Title(x, y, _("Snapshot path:"))); + y += title->get_h() + 5; + add_subwindow(snapshot_path = new SnapshotPathText(pwindow, this, x, y, get_w()-x-30)); + x = x0; y = y2; add_subwindow(new BC_Title(x, y, _("Clicking on edit boundaries does what:"))); y += 25; @@ -140,6 +145,12 @@ void InterfacePrefs::create_objects() add_subwindow(shbtn_prefs); y += shbtn_prefs->get_h() + 30; + add_subwindow(title = new BC_Title(x2, y, _("Default LV2_PATH:"))); + y += title->get_h() + 10; + PrefsLV2PathText *lv2_path_text = new PrefsLV2PathText(pwindow, this, x2, y, get_w()-x2-30); + add_subwindow(lv2_path_text); + y += 30; + y2 = y; x = x0; y = y1; add_subwindow(file_probes = new PrefsFileProbes(pwindow, this, x, y)); @@ -160,37 +171,36 @@ void InterfacePrefs::create_objects() add_subwindow(yuv420p_dvdlace); y += 30; - if( y2 > y ) y = y2; - add_subwindow(title = new BC_Title(x, y + 5, _("Min DB for meter:"))); - x += title->get_w() + 10; + add_subwindow(title = new BC_Title(x1=x, y + 5, _("Min DB for meter:"))); + x1 += title->get_w() + 10; sprintf(string, "%d", pwindow->thread->edl->session->min_meter_db); - add_subwindow(min_db = new MeterMinDB(pwindow, string, x, y)); - x += min_db->get_w() + 10; - add_subwindow(title = new BC_Title(x, y + 5, _("Max DB:"))); - x += title->get_w() + 10; + add_subwindow(min_db = new MeterMinDB(pwindow, string, x1, y)); + x1 += min_db->get_w() + 10; + add_subwindow(title = new BC_Title(x1, y + 5, _("Max DB:"))); + x1 += title->get_w() + 10; sprintf(string, "%d", pwindow->thread->edl->session->max_meter_db); - add_subwindow(max_db = new MeterMaxDB(pwindow, string, x, y)); + add_subwindow(max_db = new MeterMaxDB(pwindow, string, x1, y)); y += 30; StillImageUseDuration *use_stduration = new StillImageUseDuration(pwindow, - pwindow->thread->edl->session->si_useduration, x2, y2); + pwindow->thread->edl->session->si_useduration, x, y); add_subwindow(use_stduration); - int tw = 0, th = 0; - BC_CheckBox::calculate_extents(this, &tw, &th, 0, 0); - x2 += tw + 3; - y2 += use_stduration->get_h() + 3; - StillImageDuration *stduration = new StillImageDuration(pwindow, x2, y2); + x1 = x + use_stduration->get_w() + 10; + StillImageDuration *stduration = new StillImageDuration(pwindow, x1, y); add_subwindow(stduration); - x2 += stduration->get_w() + 10; - y2 += 3; - add_subwindow(new BC_Title(x2, y2, _("Seconds"))); - y2 += 30; + x1 += stduration->get_w() + 10; + add_subwindow(new BC_Title(x1, y, _("Seconds"))); + y += 30; - x = x0; y = y2; + PrefsAutostartLV2UI *autostart_lv2ui = new PrefsAutostartLV2UI(x, y,pwindow); + add_subwindow(autostart_lv2ui); + y += autostart_lv2ui->get_h() + 10; + + if( y2 > y ) y = y2; + x = x0; add_subwindow(new BC_Bar(5, y, get_w() - 10)); y += 5; - add_subwindow(new BC_Title(x, y, _("Index files:"), LARGEFONT, resources->text_default)); y += 30; @@ -604,3 +614,52 @@ int PrefsYUV420P_DVDlace::handle_event() return 1; } + +SnapshotPathText::SnapshotPathText(PreferencesWindow *pwindow, + InterfacePrefs *subwindow, int x, int y, int w) + : BC_TextBox(x, y, w, 1, pwindow->thread->preferences->snapshot_path) +{ + this->pwindow = pwindow; + this->subwindow = subwindow; +} + +SnapshotPathText::~SnapshotPathText() +{ +} + +int SnapshotPathText::handle_event() +{ + strcpy(pwindow->thread->preferences->snapshot_path, get_text()); + return 1; +} + +PrefsAutostartLV2UI::PrefsAutostartLV2UI(int x, int y, PreferencesWindow *pwindow) + : BC_CheckBox(x, y, + pwindow->thread->preferences->autostart_lv2ui, _("Auto start lv2 gui")) +{ + this->pwindow = pwindow; +} +int PrefsAutostartLV2UI::handle_event() +{ + pwindow->thread->preferences->autostart_lv2ui = get_value(); + return 1; +} + +PrefsLV2PathText::PrefsLV2PathText(PreferencesWindow *pwindow, + InterfacePrefs *subwindow, int x, int y, int w) + : BC_TextBox(x, y, w, 1, pwindow->thread->preferences->lv2_path) +{ + this->pwindow = pwindow; + this->subwindow = subwindow; +} + +PrefsLV2PathText::~PrefsLV2PathText() +{ +} + +int PrefsLV2PathText::handle_event() +{ + strcpy(pwindow->thread->preferences->lv2_path, get_text()); + return 1; +} +