@nativescript-community/ui-carto
Version:
NativeScript plugin for CARTO Mobile SDK
47 lines • 1.91 kB
JavaScript
export { toNativeMapRange, fromNativeMapRange, nativeVectorToArray, arrayToNativeVector } from '../utils';
export class ScreenBounds {
}
export var ClickType;
(function (ClickType) {
ClickType[ClickType["SINGLE"] = 0] = "SINGLE";
ClickType[ClickType["LONG"] = 1] = "LONG";
ClickType[ClickType["DOUBLE"] = 2] = "DOUBLE";
ClickType[ClickType["DUAL"] = 3] = "DUAL";
})(ClickType || (ClickType = {}));
// export namespace MapBounds {
// function fromCoordinates(southwest: MapPos, northeast: MapPos): MapBounds;
// }
export let LatitudeKey = 'latitude';
export let LongitudeKey = 'longitude';
export let AltitudeKey = 'altitude';
export function setMapPosKeys(latitude, longitude, altitude) {
LatitudeKey = latitude;
LongitudeKey = longitude;
if (altitude) {
AltitudeKey = altitude;
}
}
export function applyMixins(derivedCtor, baseCtors) {
baseCtors.forEach((baseCtor) => {
Object.getOwnPropertyNames(baseCtor.prototype).forEach((name) => {
if (name !== 'constructor') {
derivedCtor.prototype[name] = baseCtor.prototype[name];
}
});
Object.getOwnPropertyNames(baseCtor.prototype).forEach((name) => {
const descriptor = Object.getOwnPropertyDescriptor(baseCtor.prototype, name);
if (name === 'constructor')
return;
if (descriptor && (!descriptor.writable || !descriptor.configurable || descriptor.get || descriptor.set)) {
Object.defineProperty(derivedCtor.prototype, name, descriptor);
}
else {
derivedCtor.prototype[name] = baseCtor.prototype[name];
}
});
Object.getOwnPropertySymbols(baseCtor.prototype).forEach((symbol) => {
derivedCtor.prototype[symbol] = baseCtor.prototype[symbol];
});
});
}
//# sourceMappingURL=index.common.js.map