X-Git-Url: https://git.cinelerra-gg.org/git/?p=goodguy%2Fcinelerra.git;a=blobdiff_plain;f=cinelerra-5.1%2Fguicast%2Fbcfilebox.C;fp=cinelerra-5.1%2Fguicast%2Fbcfilebox.C;h=803f2fc465542afec39b9179c744f0de2e44cd08;hp=f24a39e0b3ee96389b9e4f8d3972229aa050a6b7;hb=72a88d4704507f72e05b380d9604d9eb3e7d5a89;hpb=75267dc010a3c3f351a2312469deb5b419fae819 diff --git a/cinelerra-5.1/guicast/bcfilebox.C b/cinelerra-5.1/guicast/bcfilebox.C index f24a39e0..803f2fc4 100644 --- a/cinelerra-5.1/guicast/bcfilebox.C +++ b/cinelerra-5.1/guicast/bcfilebox.C @@ -546,6 +546,7 @@ BC_FileBox::BC_FileBox(int x, int y, const char *init_path, this->h_padding = h_padding; delete_thread = new BC_DeleteThread(this); rename_thread = 0; + y_margin = 0; } BC_FileBox::~BC_FileBox() @@ -679,7 +680,9 @@ void BC_FileBox::create_objects() add_subwindow(filter_text = new BC_FileBoxFilterText(x1, y, this)); add_subwindow(filter_popup = new BC_FileBoxFilterMenu(x1 + filter_text->get_w(), y, this)); + y += filter_text->get_h() + 10; } + y_margin = y; // listbox has to be active because refresh might be called from newfolder_thread listbox->activate(); @@ -781,6 +784,9 @@ int BC_FileBox::resize_event(int w, int h) set_w(w); set_h(h); get_resources()->filebox_w = get_w(); get_resources()->filebox_h = get_h(); + y_margin = filter_text ? + filter_text->get_y() + filter_text->get_h() + 10 : + textbox->get_y() + textbox->get_h() + 10 ; flush(); return 1; } @@ -1324,6 +1330,11 @@ void BC_FileBox::create_listbox(int x, int y, int mode) add_subwindow(listbox = new BC_FileBoxListBox(x, y, this)); } +int BC_FileBox::get_y_margin() +{ + return y_margin; +} + char* BC_FileBox::get_path(int selection) { if(selection == 0)