Skip to content

Commit

Permalink
Box selection panning after some time #784
Browse files Browse the repository at this point in the history
  • Loading branch information
maxkfranz committed Jan 8, 2015
1 parent 2070df7 commit 16cf865
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion documentation/md/core/init.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ var cy = cytoscape({
userZoomingEnabled: true,
panningEnabled: true,
userPanningEnabled: true,
boxSelectionEnabled: true,
boxSelectionEnabled: false,
selectionType: (isTouchDevice ? 'additive' : 'single'),
touchTapThreshold: 8,
desktopTapThreshold: 4,
Expand Down
2 changes: 1 addition & 1 deletion src/extensions/renderer.canvas.load-and-listeners.js
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@
} else if(
select[4] == 1 && (down == null || down.isEdge())
&& ( !cy.boxSelectionEnabled() || +new Date() - r.hoverData.downTime >= CanvasRenderer.panOrBoxSelectDelay )
//&& (Math.abs(select[3] - select[1]) + Math.abs(select[2] - select[0]) < 4)
&& (Math.abs(select[3] - select[1]) + Math.abs(select[2] - select[0]) < 4)
&& rdist2 >= r.tapThreshold2
&& cy.panningEnabled() && cy.userPanningEnabled()
){
Expand Down

0 comments on commit 16cf865

Please sign in to comment.