upgrade ffmpeg to 3.4.2, add proxy popup, undo/redo deadlock fix, rework nested edl
[goodguy/history.git] / cinelerra-5.1 / cinelerra / browsebutton.C
index 95f358db9945cdf2ac31b433e47fffa4b920f4b4..fae5758b94d7eb35fa31afd364f6493cfd846cf2 100644 (file)
@@ -2,21 +2,21 @@
 /*
  * CINELERRA
  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
- * 
+ *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- * 
+ *
  */
 
 #include "bcsignals.h"
 #include "theme.h"
 
 
-
-
-BrowseButton::BrowseButton(Theme *theme, 
-       BC_WindowBase *parent_window, 
-       BC_TextBox *textbox, 
-       int x, 
-       int y, 
-       const char *init_directory, 
-       const char *title, 
-       const char *caption, 
+BrowseButton::BrowseButton(Theme *theme,
+       BC_WindowBase *parent_window,
+       BC_TextBox *textbox,
+       int x,
+       int y,
+       const char *init_directory,
+       const char *title,
+       const char *caption,
        int want_directory)
- : BC_Button(x, y, theme->get_image_set("magnify_button")), 
+ : BC_Button(x, y, theme->get_image_set("magnify_button")),
    Thread(1, 0, 0)
 {
        this->parent_window = parent_window;
@@ -92,15 +90,16 @@ int BrowseButton::handle_event()
 void BrowseButton::run()
 {
        BrowseButtonWindow browsewindow(theme,
-               this,
-               parent_window, 
-               textbox->get_text(), 
-               title, 
-               caption, 
+               get_x() - BC_WindowBase::get_resources()->filebox_w / 2,
+               get_y() - BC_WindowBase::get_resources()->filebox_h / 2,
+               parent_window,
+               textbox->get_text(),
+               title,
+               caption,
                want_directory);
        gui = &browsewindow;
        startup_lock->unlock();
-       
+
        browsewindow.lock_window("BrowseButton::run");
        browsewindow.create_objects();
        browsewindow.unlock_window();
@@ -129,34 +128,16 @@ void BrowseButton::run()
        startup_lock->unlock();
 }
 
-
-
-
-
-
-BrowseButtonWindow::BrowseButtonWindow(Theme *theme, 
-       BrowseButton *button,
-       BC_WindowBase *parent_window, 
-       const char *init_directory, 
-       const char *title, 
-       const char *caption, 
-       int want_directory)
- : BC_FileBox(button->x - 
-               BC_WindowBase::get_resources()->filebox_w / 2, 
-       button->y - 
-               BC_WindowBase::get_resources()->filebox_h / 2,
-       init_directory,
-       title,
-       caption,
-// Set to 1 to get hidden files. 
-       want_directory,
-// Want only directories
-       want_directory,
-       0,
-       theme->browse_pad)
+BrowseButtonWindow::BrowseButtonWindow(Theme *theme, int x, int y,
+       BC_WindowBase *parent_window, const char *init_directory,
+       const char *title, const char *caption, int want_directory)
+ : BC_FileBox(x, y, init_directory, title, caption,
+       want_directory, // Set to 1 to get hidden files.
+       want_directory, // Want only directories
+       0, theme->browse_pad)
 {
 }
 
-BrowseButtonWindow::~BrowseButtonWindow() 
+BrowseButtonWindow::~BrowseButtonWindow()
 {
 }