reworking jsc still in progress
This commit is contained in:
@@ -91,9 +91,9 @@ export function convertLegendToDropdown(inID: string) {
|
||||
});
|
||||
}
|
||||
|
||||
export function destroyCurrentSeatmap(inSelector: string, inPanzoom: PanzoomObject | undefined): void {
|
||||
if (inPanzoom)
|
||||
unbindPanzoomEvents(inSelector, inPanzoom);
|
||||
export function destroyCurrentSeatmap(inSelector: string): void {
|
||||
if (config.state.panzoom)
|
||||
unbindPanzoomEvents(inSelector);
|
||||
|
||||
jQuery("#containerSeatmapInner").remove();
|
||||
jQuery("#htmlSeatmapInner .fl-html").removeAttr("style");
|
||||
@@ -109,10 +109,10 @@ export function controlLoftloader(inSwitch: string) {
|
||||
jQuery("body").addClass("loaded loftloader-loaded");
|
||||
}
|
||||
|
||||
function unbindPanzoomEvents(inSelector: string, inPanzoom: PanzoomObject): void {
|
||||
function unbindPanzoomEvents(inSelector: string): void {
|
||||
console.log("unbinding now");
|
||||
const container: HTMLElement = jQuery(inSelector).get(0);
|
||||
container.parentElement?.removeEventListener('wheel', inPanzoom.zoomWithWheel);
|
||||
container.parentElement?.removeEventListener('wheel', config.state.panzoom!.zoomWithWheel);
|
||||
}
|
||||
|
||||
export function addPanzoom(inSelector: string, inBtnZoomIn: string | null = null, inBtnZoomOut: string | null = null, inBtnResetZoom: string | null = null): PanzoomObject | undefined {
|
||||
|
||||
Reference in New Issue
Block a user