PerpetualSession *perpetual = new PerpetualSession(x1, y1, pwindow);
add_subwindow(perpetual);
y1 += perpetual->get_h() + 5;
+ CtrlToggle *ctrl_toggle = new CtrlToggle(x1, y1, pwindow);
+ add_subwindow(ctrl_toggle);
+ y1 += ctrl_toggle->get_h() + 5;
if( y < y1 ) y = y1;
}
return 1;
}
+CtrlToggle::CtrlToggle(int x, int y, PreferencesWindow *pwindow)
+ : BC_CheckBox(x, y,
+ pwindow->thread->preferences->ctrl_toggle, _("Clears before toggle"))
+{
+ this->pwindow = pwindow;
+}
+
+int CtrlToggle::handle_event()
+{
+ pwindow->thread->preferences->ctrl_toggle = get_value();
+ return 1;
+}
+
PreferencesWindow *pwindow;
};
+class CtrlToggle : public BC_CheckBox
+{
+public:
+ CtrlToggle(int x, int y, PreferencesWindow *pwindow);
+ int handle_event();
+ PreferencesWindow *pwindow;
+};
+
#endif
*((SEdit *)this)->get_text() = 0;
}
+void Edit::set_selected(int v)
+{
+ if( group_id )
+ edl->tracks->set_group_selected(group_id, v);
+ else
+ is_selected = v >= 0 ? v : !is_selected ? 1 : 0;
+}
+
void Edit::copy_from(Edit *edit)
{
this->nested_edl = edl->nested_edls.get_nested(edit->nested_edl);
// Determine if silence depending on existance of asset or plugin title
virtual int silence();
void mute();
+ void set_selected(int v);
// Media edit information
// Units are native units for the track.
DRAG_PLUGINHANDLE2, // Dragging outside drag threshold
DRAG_SPEED,
DRAG_GROUP,
- DRAG_BUTTON_DOWN,
+ GROUP_TOGGLE,
DROP_TARGETING,
};
yuv_color_space = BC_COLORS_BT601;
yuv_color_range = BC_COLORS_JPEG;
autocolor_assets = 0;
+ ctrl_toggle = 0;
// Default brender asset
brender_asset = new Asset;
yuv_color_space = that->yuv_color_space;
yuv_color_range = that->yuv_color_range;
autocolor_assets = that->autocolor_assets;
+ ctrl_toggle = that->ctrl_toggle;
renderfarm_nodes.remove_all_objects();
renderfarm_ports.remove_all();
renderfarm_enabled.remove_all();
yuv_color_space = defaults->get("YUV_COLOR_SPACE", yuv_color_space);
yuv_color_range = defaults->get("YUV_COLOR_RANGE", yuv_color_range);
autocolor_assets = defaults->get("AUTOCOLOR_ASSETS", autocolor_assets);
+ ctrl_toggle = defaults->get("CTRL_TOGGLE", ctrl_toggle);
use_brender = defaults->get("USE_BRENDER", use_brender);
brender_fragment = defaults->get("BRENDER_FRAGMENT", brender_fragment);
cache_size = defaults->get("CACHE_SIZE", cache_size);
defaults->update("YUV_COLOR_SPACE", yuv_color_space);
defaults->update("YUV_COLOR_RANGE", yuv_color_range);
defaults->update("AUTOCOLOR_ASSETS", autocolor_assets);
+ defaults->update("CTRL_TOGGLE", ctrl_toggle);
brender_asset->save_defaults(defaults, "BRENDER_", 1, 1, 1, 0, 0);
defaults->update("USE_BRENDER", use_brender);
defaults->update("BRENDER_FRAGMENT", brender_fragment);
int yuv_color_range;
// autocolor asset edit title
int autocolor_assets;
+// ctrl_toggle && !ctrl_down() clears selection before toggle
+ int ctrl_toggle;
// Default positions for channels
int channel_positions[MAXCHANNELS][MAXCHANNELS];
int rerender = 0;
int new_cursor, update_cursor;
- if( mwindow->session->current_operation == DRAG_BUTTON_DOWN )
+ if( mwindow->session->current_operation == GROUP_TOGGLE )
mwindow->session->current_operation = NO_OPERATION;
else if( mwindow->session->current_operation != NO_OPERATION )
return 0;
result = 1;
break; }
- case DRAG_BUTTON_DOWN: {
+ case GROUP_TOGGLE: {
Edit *edit = mwindow->session->drag_edit;
if( edit ) {
if( shift_down() && edit->is_selected ) {
redraw = 0;
}
else {
- if( edit->group_id )
- mwindow->edl->tracks->set_group_selected(edit->group_id, -1);
- else
- edit->is_selected = !edit->is_selected ? 1 : 0;
+ if( mwindow->preferences->ctrl_toggle && !ctrl_down() )
+ mwindow->edl->tracks->clear_selected_edits();
+ edit->set_selected(-1);
}
}
mwindow->session->current_operation = NO_OPERATION;
if(cursor_x >= edit_x && cursor_x < edit_x + edit_w &&
cursor_y >= edit_y && cursor_y < edit_y + edit_h) {
if( button_press && get_buttonpress() == LEFT_BUTTON ) {
- if( mwindow->edl->session->editing_mode == EDITING_IBEAM &&
- get_double_click() ) {
-// Select duration of edit
+ if( get_double_click() ) {
+ mwindow->edl->tracks->clear_selected_edits();
double start = edit->track->from_units(edit->startproject);
start = mwindow->edl->align_to_frame(start, 0);
mwindow->edl->local_session->set_selectionstart(start);
- double end = edit->track->from_units(edit->startproject+edit->length);
- end = mwindow->edl->align_to_frame(end, 0);
- mwindow->edl->local_session->set_selectionend(end);
- mwindow->edl->tracks->clear_selected_edits();
- mwindow->edl->tracks->select_affected_edits(
- edit->track->from_units(edit->startproject),
- edit->track, 1);
+ if( ctrl_down() ) {
+// Select duration of edit
+ double end = edit->track->from_units(edit->startproject+edit->length);
+ end = mwindow->edl->align_to_frame(end, 0);
+ mwindow->edl->local_session->set_selectionend(end);
+ mwindow->edl->tracks->select_affected_edits(
+ edit->track->from_units(edit->startproject),
+ edit->track, 1);
+ }
+ else {
+ mwindow->edl->local_session->set_selectionend(start);
+ edit->set_selected(1);
+ }
result = 1;
}
- else if( mwindow->edl->session->editing_mode == EDITING_ARROW ||
- (mwindow->edl->session->editing_mode == EDITING_IBEAM &&
- ctrl_down()) ) {
+ else if( mwindow->edl->session->editing_mode == EDITING_ARROW ) {
mwindow->session->drag_edit = edit;
- mwindow->session->current_operation = DRAG_BUTTON_DOWN;
+ mwindow->session->current_operation = GROUP_TOGGLE;
result = 1;
}
if( result ) {
}
}
else if( drag_start && track->record ) {
- if( mwindow->edl->session->editing_mode == EDITING_ARROW ||
- ( mwindow->edl->session->editing_mode == EDITING_IBEAM &&
- ctrl_down() ) ) {
-// Need to create drag window
- mwindow->session->drag_edit = edit;
- mwindow->session->drag_origin_x = cursor_x;
- mwindow->session->drag_origin_y = cursor_y;
- // Where the drag started, so we know relative position inside the edit later
- mwindow->session->drag_position =
- mwindow->edl->get_cursor_position(cursor_x, pane->number);
+ mwindow->session->drag_edit = edit;
+ mwindow->session->drag_origin_x = cursor_x;
+ mwindow->session->drag_origin_y = cursor_y;
+// Where the drag started, so we know relative position inside the edit later
+ mwindow->session->drag_position =
+ mwindow->edl->get_cursor_position(cursor_x, pane->number);
+ if( ctrl_down() ) {
+ mwindow->session->current_operation = DRAG_EDIT;
// Construct list of all affected edits
- if( ctrl_down() ) {
- mwindow->session->current_operation = DRAG_EDIT;
- mwindow->edl->tracks->get_selected_edits(mwindow->session->drag_edits);
- int cx, cy; get_abs_cursor(cx, cy);
- gui->drag_popup = new BC_DragWindow(gui,
- mwindow->theme->get_image("clip_icon"), cx, cy);
-
- }
- else if( edit->is_selected ) {
- if( mwindow->session->drag_group )
- mwindow->session->drag_group->remove_user();
- double start_position = 0;
- mwindow->session->drag_group =
- mwindow->selected_edits_to_clip(0, &start_position,
- &mwindow->session->drag_group_first_track);
- if( mwindow->session->drag_group ) {
- mwindow->session->current_operation = DRAG_GROUP;
- mwindow->session->drag_group_position = start_position;
- mwindow->session->drag_group_edit = edit;
- mwindow->session->drag_origin_y = edit_y;
- }
+ mwindow->edl->tracks->get_selected_edits(mwindow->session->drag_edits);
+// Need to create drag window
+ int cx, cy; get_abs_cursor(cx, cy);
+ gui->drag_popup = new BC_DragWindow(gui,
+ mwindow->theme->get_image("clip_icon"), cx, cy);
+ }
+ else if( edit->is_selected ) {
+ if( mwindow->session->drag_group )
+ mwindow->session->drag_group->remove_user();
+ double start_position = 0;
+ mwindow->session->drag_group =
+ mwindow->selected_edits_to_clip(0, &start_position,
+ &mwindow->session->drag_group_first_track);
+ if( mwindow->session->drag_group ) {
+ mwindow->session->current_operation = DRAG_GROUP;
+ mwindow->session->drag_group_position = start_position;
+ mwindow->session->drag_group_edit = edit;
+ mwindow->session->drag_origin_y = edit_y;
}
- result = 1;
}
+ result = 1;
}
}
}
<tr>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4>Ctrl and Drag</font></td>
- <td align="left"><font face="Liberation Serif" size=4>Move a single edit elsewhere</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Ctrl / LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Toggles selected of group/edit</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>If “Clear before toggle”, only select this edit/group</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>If not “Clear before toggle”, toggle edit/group</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Double click</font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Only select this edit/group</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Double click</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Ctrl</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Selects column and highlights</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Shift </font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Group/ungroup selected edits/group</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Ctrl + Drag </font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Column drag</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>LMB</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Drag</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Clip drag</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4><br></font></td>
</tr>
- <tr>
- <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4><br></font></td>
- </tr>
<tr>
<td height="26" align="left"><b><font face="Liberation Serif" size=4> FFMpeg probes early</font></b></td>
<td align="left"><font face="Liberation Serif" size=4>- FFMPEG early</font></td>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4>PGUP (page up)</font></td>
<td align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4>Scroll current track horiz window pane up</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Scroll current track vertical window pane up</font></td>
</tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Up</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Scroll current track vertical window pane up</font></td>
+ </tr>
<tr>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4>PGUP (page up)</font></td>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4>Pgdn page down</font></td>
<td align="left"><font face="Liberation Serif" size=4><br></font></td>
- <td align="left"><font face="Liberation Serif" size=4>Scroll current track horiz window pane down</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Scroll current track vertical window pane down</font></td>
</tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Down</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Scroll current track vertical window pane down</font></td>
+ </tr>
<tr>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4>Pgdn page down</font></td>
<td align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4>Move insertion point to end of timeline</font></td>
</tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Shift + up</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Zoom out view without resizing the window</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Shift + down</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Zoom in view without resizing the window</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Ctrl + up</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Move left on the timeline without resize</font></td>
+ </tr>
+ <tr>
+ <td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Mouse wheel</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Ctrl + down</font></td>
+ <td align="left"><font face="Liberation Serif" size=4>Move right on the timeline without resize</font></td>
+ </tr>
<tr>
<td height="26" align="left"><font face="Liberation Serif" size=4><br></font></td>
<td align="left"><font face="Liberation Serif" size=4><br></font></td>