added clip snapping
This commit is contained in:
+3
-2
@@ -18,8 +18,9 @@ Timeline::Timeline(QWidget *parent) :
|
||||
QDockWidget(parent),
|
||||
ui(new Ui::Timeline)
|
||||
{
|
||||
selecting = moving_init = moving_proc = splitting = importing = playing = trim_in = false;
|
||||
last_frame = playhead = 0;
|
||||
selecting = moving_init = moving_proc = splitting = importing = playing = trim_in = snapped = false;
|
||||
snapping = true;
|
||||
last_frame = playhead = snap_point = 0;
|
||||
trim_target = -1;
|
||||
|
||||
ui->setupUi(this);
|
||||
|
||||
@@ -87,6 +87,11 @@ public:
|
||||
int drag_track_start;
|
||||
void redraw_all_clips();
|
||||
|
||||
// snapping
|
||||
bool snapping;
|
||||
bool snapped;
|
||||
long snap_point;
|
||||
|
||||
// selecting functions
|
||||
bool selecting;
|
||||
QVector<Selection> selections;
|
||||
|
||||
+27
-2
@@ -207,6 +207,12 @@
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="toolSlipButton">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>30</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slip Tool (Y)</string>
|
||||
</property>
|
||||
@@ -223,6 +229,25 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="snappingButton">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>30</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>S</string>
|
||||
</property>
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_4">
|
||||
<property name="maximumSize">
|
||||
@@ -287,8 +312,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>789</width>
|
||||
<height>494</height>
|
||||
<width>796</width>
|
||||
<height>506</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
|
||||
Reference in New Issue
Block a user