diff options
author | yipstanley <stanley_yip@brown.edu> | 2019-07-19 17:01:52 -0400 |
---|---|---|
committer | yipstanley <stanley_yip@brown.edu> | 2019-07-19 17:01:52 -0400 |
commit | 8c266048054dccc20851f79b08c82aa552765158 (patch) | |
tree | 19106491ede918ccafa2a3c2be4a458499e9cc67 /src/client/util/DragManager.ts | |
parent | e4ef3a04e3bd0bb20ed70181d51a9c419a00613f (diff) | |
parent | 17f53f604e0087615c2baff6cffa344771301b5e (diff) |
Merge branch 'schema_view_improvements_2' of https://github.com/browngraphicslab/Dash-Web into schema_view_improvements_2
Diffstat (limited to 'src/client/util/DragManager.ts')
-rw-r--r-- | src/client/util/DragManager.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/client/util/DragManager.ts b/src/client/util/DragManager.ts index 323908302..f9f6b05c0 100644 --- a/src/client/util/DragManager.ts +++ b/src/client/util/DragManager.ts @@ -288,6 +288,15 @@ export namespace DragManager { [id: string]: any; } + // for column dragging in schema view + export class ColumnDragData { + constructor(colKey: string) { + this.colKey = colKey; + } + colKey: string; + [id: string]: any; + } + export function StartLinkDrag(ele: HTMLElement, dragData: LinkDragData, downX: number, downY: number, options?: DragOptions) { StartDrag([ele], dragData, downX, downY, options); } @@ -296,6 +305,10 @@ export namespace DragManager { StartDrag([ele], dragData, downX, downY, options); } + export function StartColumnDrag(ele: HTMLElement, dragData: ColumnDragData, downX: number, downY: number, options?:DragOptions) { + StartDrag([ele], dragData, downX, downY, options); + } + export let AbortDrag: () => void = emptyFunction; function StartDrag(eles: HTMLElement[], dragData: { [id: string]: any }, downX: number, downY: number, options?: DragOptions, finishDrag?: (dropData: { [id: string]: any }) => void) { |