From c42e55363dddb8f5b1876af7991355b011f04fcc Mon Sep 17 00:00:00 2001 From: Z Snow Date: Wed, 17 Aug 2016 14:02:14 +1000 Subject: [PATCH] Fire onFinishChange if onChange isn't set. This allows 'revert' to function in that case. --- src/dat/controllers/Controller.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dat/controllers/Controller.js b/src/dat/controllers/Controller.js index 3a44df3..63aeea1 100644 --- a/src/dat/controllers/Controller.js +++ b/src/dat/controllers/Controller.js @@ -105,6 +105,9 @@ define([ if (this.__onChange) { this.__onChange.call(this, newValue); } + else if (this.__onFinishChange) { + this.__onFinishChange.call(this, newValue); + } this.updateDisplay(); return this; },