#include "cpanel.inc"
#include "ctimebar.inc"
#include "cwindow.inc"
+#include "cwindowgui.inc"
#include "cwindowtool.inc"
#include "editpanel.h"
#include "floatauto.inc"
#include "track.inc"
#include "zoompanel.h"
-class CWindowZoom;
-class CWindowSlider;
-class CWindowReset;
-class CWindowDestination;
-class CWindowMeters;
-class CWindowTransport;
-class CWindowCanvas;
-class CWindowEditing;
-
#define AUTO_ZOOM N_("Auto")
+#define CROP_REFORMAT 0
+#define CROP_RESIZE 1
+#define CROP_SHRINK 2
+#define CROP_MODES 3
+
+
class CWindowGUI : public BC_Window
{
public:
void create_objects();
int resize_event(int w, int h);
- void zoom_canvas(double value, int update_menu);
- float get_auto_zoom();
+ void update_canvas(int redraw=1);
// Events for the fullscreen canvas fall through to here.
int button_press_event();
CTimeBar *timebar;
BC_Pixmap *active;
BC_Pixmap *inactive;
+ VFrame *focus_frame;
// MainClock *clock;
void panel_fit_autos(int all);
void panel_set_editing_mode(int mode);
void panel_set_auto_keyframes(int v);
+ void panel_set_span_keyframes(int v);
void panel_set_labels_follow_edits(int v);
MWindow *mwindow;
MWindow *mwindow;
};
-// class CWindowDestination : public BC_PopupTextBox
-// {
-// public:
-// CWindowDestination(MWindow *mwindow, CWindowGUI *cwindow, int x, int y);
-// ~CWindowDestination();
-// int handle_event();
-// CWindowGUI *cwindow;
-// MWindow *mwindow;
-// };
-
class CWindowTransport : public PlayTransport
{
public:
CWindowTransport(MWindow *mwindow,
- CWindowGUI *gui,
- int x,
- int y);
+ CWindowGUI *gui, int x, int y);
+ bool use_mixers() { return true; }
EDL* get_edl();
void goto_start();
void goto_end();
CWindowGUI *gui;
};
+class CWindowCanvasToggleControls : public BC_MenuItem
+{
+public:
+ CWindowCanvasToggleControls(CWindowCanvas *canvas);
+ int handle_event();
+ static const char *calculate_text(int cwindow_controls);
+ CWindowCanvas *canvas;
+};
class CWindowCanvas : public Canvas
{
public:
CWindowCanvas(MWindow *mwindow, CWindowGUI *gui);
+ void create_objects(EDL *edl);
void status_event();
void zoom_resize_window(float percentage);
void update_zoom(int x, int y, float zoom);
int get_xscroll();
int get_yscroll();
float get_zoom();
+ void zoom_auto();
+ int do_scroll(EDL *edl, float cursor_x, float cursor_y);
int do_eyedrop(int &rerender, int button_press, int draw);
- int do_mask(int &redraw,
- int &rerender,
- int button_press,
- int cursor_motion,
- int draw);
+ int do_mask(int &redraw, int &rerender,
+ int button_press, int cursor_motion, int draw);
+ int do_mask_focus();
void draw_refresh(int flash = 1);
int need_overlays();
void draw_overlays();
int button_release_event();
int test_crop(int button_press, int &redraw);
int test_bezier(int button_press,
- int &redraw,
- int &redraw_canvas,
- int &rerender,
- int do_camera);
+ int &redraw, int &redraw_canvas, int &rerender, int do_camera);
int do_ruler(int draw, int motion, int button_press, int button_release);
int test_zoom(int &redraw);
void create_keyframe(int do_camera);
void reset_camera();
void reset_projector();
void draw_crophandle(int x, int y);
- void zoom_auto();
+ int set_fullscreen(int on, int unlock);
+ int scope_on();
+ void draw_scope(VFrame *output, int refresh);
// Draw the camera/projector overlay in different colors.
void draw_outlines(int do_camera);
void draw_crop();
void calculate_origin();
+ int get_clear_color();
+ int get_controls();
void toggle_controls();
- int get_cwindow_controls();
MWindow *mwindow;
CWindowGUI *gui;
+ CWindowCanvasToggleControls *controls;
+ float last_xscroll, last_yscroll;
+ float last_zoom;
};
#endif