dock-spawn-ts
Advanced tools
Comparing version 2.9.0 to 2.10.0
@@ -27,3 +27,3 @@ import { DockManager } from "./DockManager.js"; | ||
_forceResizeCompositeContainer: (container: IDockContainer) => void; | ||
_createDockContainer(containerType: string, newNode: DockNode, referenceNode: DockNode): FillDockContainer | HorizontalDockContainer | VerticalDockContainer; | ||
_createDockContainer(containerType: string, newNode: DockNode, referenceNode: DockNode): HorizontalDockContainer | FillDockContainer | VerticalDockContainer; | ||
/** | ||
@@ -30,0 +30,0 @@ * Gets the bounds of the new node if it were to dock with the specified configuration |
@@ -16,2 +16,3 @@ import { SplitterBar } from "./SplitterBar.js"; | ||
removeFromDOM(): void; | ||
removeSplittersFromDOM(): void; | ||
destroy(): void; | ||
@@ -18,0 +19,0 @@ _insertContainerIntoPanel(container: IDockContainer): void; |
@@ -33,3 +33,12 @@ import { SplitterBar } from "./SplitterBar.js"; | ||
if (!containersEqual || relayoutEvenIfEqual) { | ||
this.removeFromDOM(); | ||
this.childContainers.forEach((container) => { | ||
if (!children.some((item) => item == container)) { | ||
if (container.containerElement) { | ||
container.containerElement.classList.remove('splitter-container-vertical'); | ||
container.containerElement.classList.remove('splitter-container-horizontal'); | ||
Utils.removeNode(container.containerElement); | ||
} | ||
} | ||
}); | ||
this.removeSplittersFromDOM(); | ||
// rebuild | ||
@@ -48,2 +57,5 @@ this.childContainers = children; | ||
}); | ||
this.removeSplittersFromDOM(); | ||
} | ||
removeSplittersFromDOM() { | ||
this.spiltterBars.forEach((bar) => { Utils.removeNode(bar.barElement); }); | ||
@@ -50,0 +62,0 @@ } |
@@ -120,3 +120,3 @@ import { EventHandler } from "./EventHandler.js"; | ||
let dy = position.y - this.dragStartPosition.y; | ||
if (dy > this.thresholdPixels) { | ||
if (dy > this.thresholdPixels || dy < -this.thresholdPixels) { | ||
this.enabled = false; | ||
@@ -123,0 +123,0 @@ this._requestUndock(e); |
{ | ||
"name": "dock-spawn-ts", | ||
"version": "2.9.0", | ||
"version": "2.10.0", | ||
"description": "DockSpawn Typescript Version", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -44,4 +44,14 @@ import { SplitterBar } from "./SplitterBar.js"; | ||
if (!containersEqual || relayoutEvenIfEqual) { | ||
this.removeFromDOM(); | ||
this.childContainers.forEach((container) => { | ||
if (!children.some((item) => item == container)) { | ||
if (container.containerElement) { | ||
container.containerElement.classList.remove('splitter-container-vertical'); | ||
container.containerElement.classList.remove('splitter-container-horizontal'); | ||
Utils.removeNode(container.containerElement); | ||
} | ||
} | ||
}); | ||
this.removeSplittersFromDOM(); | ||
// rebuild | ||
@@ -61,2 +71,6 @@ this.childContainers = children; | ||
}); | ||
this.removeSplittersFromDOM(); | ||
} | ||
removeSplittersFromDOM() { | ||
this.spiltterBars.forEach((bar) => { Utils.removeNode(bar.barElement); }); | ||
@@ -63,0 +77,0 @@ } |
@@ -157,3 +157,3 @@ import { EventHandler } from "./EventHandler.js"; | ||
if (dy > this.thresholdPixels) { | ||
if (dy > this.thresholdPixels || dy < -this.thresholdPixels) { | ||
this.enabled = false; | ||
@@ -160,0 +160,0 @@ this._requestUndock(e); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
549422
8724