mirror of
https://github.com/nasa/openmct.git
synced 2025-06-18 15:18:12 +00:00
move newPosition check from mctSplitPane to splitter
This commit is contained in:
@ -229,14 +229,13 @@ define(
|
||||
anchor: function () {
|
||||
return anchor;
|
||||
},
|
||||
position: function (initialValue, newValue) {
|
||||
position: function (newPosition) {
|
||||
if (arguments.length === 0) {
|
||||
return getSetPosition();
|
||||
}
|
||||
if (initialValue !== newValue) {
|
||||
setUserWidthPreference(newValue);
|
||||
getSetPosition(newValue);
|
||||
}
|
||||
|
||||
setUserWidthPreference(newPosition);
|
||||
return getSetPosition(newPosition);
|
||||
},
|
||||
startResizing: function () {
|
||||
toggleClass('resizing');
|
||||
|
@ -57,7 +57,10 @@ define(
|
||||
|
||||
// Update the position of this splitter
|
||||
newPosition = initialPosition + pixelDelta;
|
||||
mctSplitPane.position(initialPosition, newPosition);
|
||||
|
||||
if (initialPosition !== newPosition) {
|
||||
mctSplitPane.position(newPosition);
|
||||
}
|
||||
},
|
||||
// Grab the event when the user is done moving
|
||||
// the splitter and pass it on
|
||||
|
Reference in New Issue
Block a user