Пример #1
0
        private void OnEnable()
        {
            zoom = target as SimpleZoom;

            #region Serialized Properties
            defaultZoom          = serializedObject.FindProperty("defaultZoom");
            minMaxZoom           = serializedObject.FindProperty("minMaxZoom");
            zoomTarget           = serializedObject.FindProperty("zoomTarget");
            customPosition       = serializedObject.FindProperty("customPosition");
            zoomType             = serializedObject.FindProperty("zoomType");
            elasticLimit         = serializedObject.FindProperty("elasticLimit");
            elasticDamping       = serializedObject.FindProperty("elasticDamping");
            zoomMode             = serializedObject.FindProperty("zoomMode");
            zoomInButton         = serializedObject.FindProperty("zoomInButton");
            zoomInPosition       = serializedObject.FindProperty("zoomInPosition");
            zoomInIncrement      = serializedObject.FindProperty("zoomInIncrement");
            zoomInSmoothing      = serializedObject.FindProperty("zoomInSmoothing");
            zoomOutButton        = serializedObject.FindProperty("zoomOutButton");
            zoomOutPosition      = serializedObject.FindProperty("zoomOutPosition");
            zoomOutIncrement     = serializedObject.FindProperty("zoomOutIncrement");
            zoomOutSmoothing     = serializedObject.FindProperty("zoomOutSmoothing");
            zoomSlider           = serializedObject.FindProperty("zoomSlider");
            zoomView             = serializedObject.FindProperty("zoomView");
            restrictZoomMovement = serializedObject.FindProperty("restrictZoomMovement");
            useDoubleTap         = serializedObject.FindProperty("useDoubleTap");
            doubleTapTargetTime  = serializedObject.FindProperty("doubleTapTargetTime");
            scrollWheelIncrement = serializedObject.FindProperty("scrollWheelIncrement");
            scrollWheelSmoothing = serializedObject.FindProperty("scrollWheelSmoothing");
            #endregion
        }
Пример #2
0
        private void OnEnable()
        {
            simpleZoom = target as SimpleZoom;

            // Basic Settings.
            currentZoom    = serializedObject.FindProperty("currentZoom");
            minZoom        = serializedObject.FindProperty("minZoom");
            maxZoom        = serializedObject.FindProperty("maxZoom");
            zoomTarget     = serializedObject.FindProperty("zoomTarget");
            customPosition = serializedObject.FindProperty("customPosition");
            zoomType       = serializedObject.FindProperty("zoomType");
            elasticLimit   = serializedObject.FindProperty("elasticLimit");
            elasticDamping = serializedObject.FindProperty("elasticDamping");
            zoomMode       = serializedObject.FindProperty("zoomMode");

            // Control Settings.
            zoomIn           = serializedObject.FindProperty("zoomIn");
            zoomInPosition   = serializedObject.FindProperty("zoomInPosition");
            zoomInIncrement  = serializedObject.FindProperty("zoomInIncrement");
            zoomInSmoothing  = serializedObject.FindProperty("zoomInSmoothing");
            zoomOut          = serializedObject.FindProperty("zoomOut");
            zoomOutPosition  = serializedObject.FindProperty("zoomOutPosition");
            zoomOutIncrement = serializedObject.FindProperty("zoomOutIncrement");
            zoomOutSmoothing = serializedObject.FindProperty("zoomOutSmoothing");
            zoomSlider       = serializedObject.FindProperty("zoomSlider");
            zoomView         = serializedObject.FindProperty("zoomView");

            // Other Settings.
            zoomMovement         = serializedObject.FindProperty("zoomMovement");
            doubleTap            = serializedObject.FindProperty("doubleTap");
            doubleTapTargetTime  = serializedObject.FindProperty("doubleTapTargetTime");
            scrollWheelIncrement = serializedObject.FindProperty("scrollWheelIncrement");
            scrollWheelSmoothing = serializedObject.FindProperty("scrollWheelSmoothing");
        }