Skip to content

Commit 3a31113

Browse files
authored
Merge pull request #4119 from JacksonRG/right-click-bug
SHIFT + Right click bug preventing clip/transition movement
2 parents 53c9029 + 8517ed4 commit 3a31113

File tree

4 files changed

+2
-21
lines changed

4 files changed

+2
-21
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ dist
99
openshot_qt.egg-info
1010

1111
protobuf_data/
12+
openshot_qt/

src/timeline/app.js

-19
Original file line numberDiff line numberDiff line change
@@ -57,25 +57,6 @@ $(document).ready(function () {
5757
$(".playhead-line").height(body_object.scope().playhead_height);
5858
});
5959

60-
// Bind to keydown event (to detect SHIFT)
61-
body_object.keydown(function (event) {
62-
if (event.which === 16) {
63-
if (timeline) {
64-
timeline.qt_log("DEBUG", "Shift pressed!");
65-
}
66-
body_object.scope().shift_pressed = true;
67-
}
68-
});
69-
70-
body_object.keyup(function (event) {
71-
if (event.which === 16) {
72-
if (timeline) {
73-
timeline.qt_log("DEBUG", "Shift released!");
74-
}
75-
body_object.scope().shift_pressed = false;
76-
}
77-
});
78-
7960
// Manually trigger the window resize code (to verify it runs at least once)
8061
$(window).trigger("resize");
8162
});

src/timeline/js/controllers.js

-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ App.controller("TimelineCtrl", function ($scope) {
5959
$scope.playhead_animating = false;
6060
$scope.playhead_height = 300;
6161
$scope.playheadTime = secondsToTime($scope.project.playhead_position, $scope.project.fps.num, $scope.project.fps.den);
62-
$scope.shift_pressed = false;
6362
$scope.snapline_position = 0.0;
6463
$scope.snapline = false;
6564
$scope.enable_snapping = true;

src/timeline/js/functions.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ function moveBoundingBox(scope, previous_x, previous_y, x_offset, y_offset, left
273273
snapping_result.top = top;
274274

275275
// Check for shift key
276-
if (scope.shift_pressed) {
276+
if (event.shiftKey) {
277277
// freeze X movement
278278
x_offset = 0;
279279
snapping_result.left = previous_x;

0 commit comments

Comments
 (0)