import * as React from 'react';
import { delegateCombine, delegateRemove } from "igniteui-react-core/ES2015/type";
import { ZoomSliderOrientation_$type } from "./ZoomSliderOrientation";
import { ZoomSliderResolvingAxisValueEventArgs } from "./igr-zoom-slider-resolving-axis-value-event-args";
import { RectChangedEventArgs } from "igniteui-react-core/ES2015/igr-rect-changed-event-args";
import { ZoomSlider } from "./ZoomSlider";
import { getModifiedProps, isValidProp, fromRect, toRect, ensureEnum, brushToString, stringToBrush, ensureBool } from "igniteui-react-core/ES2015/componentUtil";
import { FontInfo } from "igniteui-react-core/ES2015/FontInfo";
export class IgrZoomSlider extends React.Component {
    constructor(props) {
        super(props);
        this._resolvingAxisValue = null;
        this._resolvingAxisValue_wrapped = null;
        this._windowRectChanged = null;
        this._windowRectChanged_wrapped = null;
        this._implementation = this.createImplementation();
        this._implementation.externalObject = this;
        this.onImplementationCreated();
    }
    createImplementation() {
        return new ZoomSlider();
    }
    get i() {
        return this._implementation;
    }
    onImplementationCreated() {
    }
    componentDidMount() {
        for (const p of Object.keys(this.props)) {
            if (isValidProp(this, p)) {
                this[p] = this.props[p];
            }
        }
    }
    shouldComponentUpdate(nextProps, nextState) {
        const mod = getModifiedProps(this.props, nextProps);
        for (const p of Object.keys(mod)) {
            if (isValidProp(this, p)) {
                this[p] = mod[p];
            }
        }
        return true;
    }
    render() {
        return null;
    }
    get panTransitionDuration() {
        return this.i.br;
    }
    set panTransitionDuration(v) {
        this.i.br = +v;
    }
    get maxZoomWidth() {
        return this.i.bj;
    }
    set maxZoomWidth(v) {
        this.i.bj = +v;
    }
    get pixelScalingRatio() {
        return this.i.bl;
    }
    set pixelScalingRatio(v) {
        this.i.bl = +v;
    }
    get actualPixelScalingRatio() {
        return this.i.a5;
    }
    set actualPixelScalingRatio(v) {
        this.i.a5 = +v;
    }
    get windowRect() {
        return fromRect(this.i.fs);
    }
    set windowRect(v) {
        this.i.fs = toRect(v);
    }
    get minZoomWidth() {
        return this.i.bk;
    }
    set minZoomWidth(v) {
        this.i.bk = +v;
    }
    get startInset() {
        return this.i.bn;
    }
    set startInset(v) {
        this.i.bn = +v;
    }
    get endInset() {
        return this.i.a8;
    }
    set endInset(v) {
        this.i.a8 = +v;
    }
    get trackStartInset() {
        return this.i.bp;
    }
    set trackStartInset(v) {
        this.i.bp = +v;
    }
    get trackEndInset() {
        return this.i.bo;
    }
    set trackEndInset(v) {
        this.i.bo = +v;
    }
    get barExtent() {
        return this.i.a6;
    }
    set barExtent(v) {
        this.i.a6 = +v;
    }
    get orientation() {
        return this.i.e;
    }
    set orientation(v) {
        this.i.e = ensureEnum(ZoomSliderOrientation_$type, v);
    }
    get lowerThumbBrush() {
        return brushToString(this.i.fg);
    }
    set lowerThumbBrush(v) {
        this.i.fg = stringToBrush(v);
    }
    get lowerThumbStrokeThickness() {
        return this.i.bh;
    }
    set lowerThumbStrokeThickness(v) {
        this.i.bh = +v;
    }
    get higherThumbStrokeThickness() {
        return this.i.bc;
    }
    set higherThumbStrokeThickness(v) {
        this.i.bc = +v;
    }
    get higherThumbBrush() {
        return brushToString(this.i.e8);
    }
    set higherThumbBrush(v) {
        this.i.e8 = stringToBrush(v);
    }
    get lowerThumbOutline() {
        return brushToString(this.i.fh);
    }
    set lowerThumbOutline(v) {
        this.i.fh = stringToBrush(v);
    }
    get higherThumbOutline() {
        return brushToString(this.i.e9);
    }
    set higherThumbOutline(v) {
        this.i.e9 = stringToBrush(v);
    }
    get lowerThumbRidgesBrush() {
        return brushToString(this.i.fi);
    }
    set lowerThumbRidgesBrush(v) {
        this.i.fi = stringToBrush(v);
    }
    get higherThumbRidgesBrush() {
        return brushToString(this.i.fa);
    }
    set higherThumbRidgesBrush(v) {
        this.i.fa = stringToBrush(v);
    }
    get lowerThumbWidth() {
        return this.i.bi;
    }
    set lowerThumbWidth(v) {
        this.i.bi = +v;
    }
    get higherThumbWidth() {
        return this.i.bd;
    }
    set higherThumbWidth(v) {
        this.i.bd = +v;
    }
    get lowerThumbHeight() {
        return this.i.bg;
    }
    set lowerThumbHeight(v) {
        this.i.bg = +v;
    }
    get higherThumbHeight() {
        return this.i.bb;
    }
    set higherThumbHeight(v) {
        this.i.bb = +v;
    }
    get lowerShadeBrush() {
        return brushToString(this.i.fe);
    }
    set lowerShadeBrush(v) {
        this.i.fe = stringToBrush(v);
    }
    get lowerShadeOutline() {
        return brushToString(this.i.ff);
    }
    set lowerShadeOutline(v) {
        this.i.ff = stringToBrush(v);
    }
    get lowerShadeStrokeThickness() {
        return this.i.bf;
    }
    set lowerShadeStrokeThickness(v) {
        this.i.bf = +v;
    }
    get higherShadeBrush() {
        return brushToString(this.i.e6);
    }
    set higherShadeBrush(v) {
        this.i.e6 = stringToBrush(v);
    }
    get higherShadeOutline() {
        return brushToString(this.i.e7);
    }
    set higherShadeOutline(v) {
        this.i.e7 = stringToBrush(v);
    }
    get higherShadeStrokeThickness() {
        return this.i.ba;
    }
    set higherShadeStrokeThickness(v) {
        this.i.ba = +v;
    }
    get barBrush() {
        return brushToString(this.i.e1);
    }
    set barBrush(v) {
        this.i.e1 = stringToBrush(v);
    }
    get barOutline() {
        return brushToString(this.i.e2);
    }
    set barOutline(v) {
        this.i.e2 = stringToBrush(v);
    }
    get barStrokeThickness() {
        return this.i.a7;
    }
    set barStrokeThickness(v) {
        this.i.a7 = +v;
    }
    get rangeThumbBrush() {
        return brushToString(this.i.fj);
    }
    set rangeThumbBrush(v) {
        this.i.fj = stringToBrush(v);
    }
    get rangeThumbOutline() {
        return brushToString(this.i.fk);
    }
    set rangeThumbOutline(v) {
        this.i.fk = stringToBrush(v);
    }
    get rangeThumbStrokeThickness() {
        return this.i.bm;
    }
    set rangeThumbStrokeThickness(v) {
        this.i.bm = +v;
    }
    get rangeThumbRidgesBrush() {
        return brushToString(this.i.fl);
    }
    set rangeThumbRidgesBrush(v) {
        this.i.fl = stringToBrush(v);
    }
    get lowerCalloutBrush() {
        return brushToString(this.i.fb);
    }
    set lowerCalloutBrush(v) {
        this.i.fb = stringToBrush(v);
    }
    get lowerCalloutTextColor() {
        return brushToString(this.i.fd);
    }
    set lowerCalloutTextColor(v) {
        this.i.fd = stringToBrush(v);
    }
    get lowerCalloutOutline() {
        return brushToString(this.i.fc);
    }
    set lowerCalloutOutline(v) {
        this.i.fc = stringToBrush(v);
    }
    get lowerCalloutStrokeThickness() {
        return this.i.be;
    }
    set lowerCalloutStrokeThickness(v) {
        this.i.be = +v;
    }
    get higherCalloutBrush() {
        return brushToString(this.i.e3);
    }
    set higherCalloutBrush(v) {
        this.i.e3 = stringToBrush(v);
    }
    get higherCalloutTextColor() {
        return brushToString(this.i.e5);
    }
    set higherCalloutTextColor(v) {
        this.i.e5 = stringToBrush(v);
    }
    get higherCalloutOutline() {
        return brushToString(this.i.e4);
    }
    set higherCalloutOutline(v) {
        this.i.e4 = stringToBrush(v);
    }
    get higherCalloutStrokeThickness() {
        return this.i.a9;
    }
    set higherCalloutStrokeThickness(v) {
        this.i.a9 = +v;
    }
    get isCustomThumbProvided() {
        return this.i.ac;
    }
    get isCustomRangeThumbProvided() {
        return this.i.aa;
    }
    get isCustomBarProvided() {
        return this.i.z;
    }
    get isCustomShadeProvided() {
        return this.i.ab;
    }
    get areThumbCalloutsEnabled() {
        return this.i.r;
    }
    set areThumbCalloutsEnabled(v) {
        this.i.r = ensureBool(v);
    }
    get ThumbCalloutTextStyle() {
        if (this.i.o == null) {
            return null;
        }
        return this.i.o.fontString;
    }
    set ThumbCalloutTextStyle(v) {
        let fi = new FontInfo();
        fi.fontString = v;
        this.i.o = fi;
    }
    destroy() {
        this.i.destroy();
    }
    provideContainer(container) {
        this.i.provideContainer(container);
    }
    flush() {
        this.i.c9();
    }
    trackDirty() {
        this.i.trackDirty();
    }
    get resolvingAxisValue() {
        return this._resolvingAxisValue;
    }
    set resolvingAxisValue(ev) {
        if (this._resolvingAxisValue !== null) {
            this.i.resolvingAxisValue = delegateRemove(this.i.resolvingAxisValue, this._resolvingAxisValue_wrapped);
            this._resolvingAxisValue_wrapped = null;
            this._resolvingAxisValue = null;
        }
        this._resolvingAxisValue = ev;
        this._resolvingAxisValue_wrapped = (o, e) => {
            let outerArgs = new ZoomSliderResolvingAxisValueEventArgs();
            outerArgs._provideImplementation(e);
            this._resolvingAxisValue(this, outerArgs);
        };
        this.i.resolvingAxisValue = delegateCombine(this.i.resolvingAxisValue, this._resolvingAxisValue_wrapped);
    }
    get windowRectChanged() {
        return this._windowRectChanged;
    }
    set windowRectChanged(ev) {
        if (this._windowRectChanged !== null) {
            this.i.windowRectChanged = delegateRemove(this.i.windowRectChanged, this._windowRectChanged_wrapped);
            this._windowRectChanged_wrapped = null;
            this._windowRectChanged = null;
        }
        this._windowRectChanged = ev;
        this._windowRectChanged_wrapped = (o, e) => {
            let outerArgs = new RectChangedEventArgs();
            outerArgs._provideImplementation(e);
            this._windowRectChanged(this, outerArgs);
        };
        this.i.windowRectChanged = delegateCombine(this.i.windowRectChanged, this._windowRectChanged_wrapped);
    }
}
