MCPcopy Create free account
hub / github.com/DHTMLX/scheduler / onStateChange

Method onStateChange

codebase/sources/dhtmlxscheduler.js:9017–9025  ·  view source on GitHub ↗
(handler)

Source from the content-addressed store, hash-verified

9015 }
9016 }
9017 onStateChange(handler) {
9018 this.onStateChangeHandlers.push(handler);
9019 return () => {
9020 const index = this.onStateChangeHandlers.indexOf(handler);
9021 if (index !== -1) {
9022 this.onStateChangeHandlers.splice(index, 1);
9023 }
9024 };
9025 }
9026 _notifyStateChange(oldState, newState) {
9027 this.onStateChangeHandlers.forEach((handler) => handler(oldState, newState));
9028 }

Callers 1

constructorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected