[fix] drag when no progress handle

This commit is contained in:
Faris Ansari 2017-01-29 12:43:24 +05:30
parent 44954a77aa
commit 9bcd2a4236
4 changed files with 6 additions and 5 deletions

View File

@ -1621,7 +1621,8 @@ return /******/ (function(modules) { // webpackBootstrap
self.handle_group.select('.handle.right').attr({ self.handle_group.select('.handle.right').attr({
'x': bar.getEndX() - 9 'x': bar.getEndX() - 9
}); });
self.group.select('.handle.progress').attr('points', get_progress_polygon_points()); var handle = self.group.select('.handle.progress');
handle && handle.attr('points', get_progress_polygon_points());
} }
function update_arrow_position() { function update_arrow_position() {

File diff suppressed because one or more lines are too long

View File

@ -51,6 +51,7 @@
progress: parseInt(Math.random() * 100, 10) progress: parseInt(Math.random() * 100, 10)
} }
}); });
tasks[1].progress = 0;
tasks[1].dependencies = "Task 0" tasks[1].dependencies = "Task 0"
tasks[2].dependencies = "Task 1" tasks[2].dependencies = "Task 1"
tasks[3].dependencies = "Task 2" tasks[3].dependencies = "Task 2"

View File

@ -489,9 +489,8 @@ export default function Bar(gt, task) {
self.handle_group.select('.handle.right').attr({ self.handle_group.select('.handle.right').attr({
'x': bar.getEndX() - 9 'x': bar.getEndX() - 9
}); });
self.group.select('.handle.progress').attr( const handle = self.group.select('.handle.progress');
'points', get_progress_polygon_points() handle && handle.attr('points', get_progress_polygon_points());
);
} }
function update_arrow_position() { function update_arrow_position() {