mirror of
https://github.com/nasa/openmct.git
synced 2025-05-21 17:57:39 +00:00
[Layout] Cache reference to body later in mct-drag
Get a reference to the body element at link-time, instead of instantiation time, from the mct-drag directive. Failure to do so causes the reference to fall out of date when switching between Browse and Edit mode. Supports position/sizing interactions for Layout view, WTD-535.
This commit is contained in:
parent
7080ca585e
commit
a0486495c4
@ -6,10 +6,10 @@ define(
|
|||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
function MCTDrag($document) {
|
function MCTDrag($document) {
|
||||||
var body = $document.find('body');
|
|
||||||
|
|
||||||
function link(scope, element, attrs) {
|
function link(scope, element, attrs) {
|
||||||
var initialPosition,
|
var body = $document.find('body'),
|
||||||
|
initialPosition,
|
||||||
currentPosition,
|
currentPosition,
|
||||||
delta;
|
delta;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user