diff options
author | John Mayhew | 2012-04-02 16:28:39 -0700 |
---|---|---|
committer | John Mayhew | 2012-04-02 16:28:39 -0700 |
commit | b4155fb4c33675a8a7cd37473513718043fdf0ba (patch) | |
tree | 3d8c802473f2395d53d599ec9d8b70b60a4db50c /js/components/gradientpicker.reel/gradientpicker.js | |
parent | 5ba9aeac94c86049423fd5d4b37b277263939c13 (diff) | |
parent | c6de22bf42be90b403491b5f87b1818d9020310c (diff) | |
download | ninja-b4155fb4c33675a8a7cd37473513718043fdf0ba.tar.gz |
Merge branch 'master' of github.com:Motorola-Mobility/ninja-internal into WorkingBranch
Conflicts:
js/helper-classes/RDGE/rdge-compiled.js
js/helper-classes/RDGE/runtime/GLRuntime.js
js/helper-classes/RDGE/src/core/script/MeshManager.js
js/helper-classes/RDGE/src/core/script/engine.js
js/helper-classes/RDGE/src/core/script/fx/ssao.js
js/helper-classes/RDGE/src/core/script/init_state.js
js/helper-classes/RDGE/src/core/script/run_state.js
js/helper-classes/RDGE/src/core/script/scenegraphNodes.js
js/helper-classes/RDGE/src/core/script/utilities.js
js/helper-classes/RDGE/src/tools/compile-rdge-core.bat
js/helper-classes/RDGE/src/tools/compile-rdge-core.sh
js/helper-classes/RDGE/src/tools/rdge-compiled.js
js/lib/drawing/world.js
js/lib/rdge/materials/bump-metal-material.js
js/lib/rdge/materials/deform-material.js
js/lib/rdge/materials/flat-material.js
js/lib/rdge/materials/fly-material.js
js/lib/rdge/materials/julia-material.js
js/lib/rdge/materials/keleidoscope-material.js
js/lib/rdge/materials/linear-gradient-material.js
js/lib/rdge/materials/mandel-material.js
js/lib/rdge/materials/plasma-material.js
js/lib/rdge/materials/pulse-material.js
js/lib/rdge/materials/radial-blur-material.js
js/lib/rdge/materials/radial-gradient-material.js
js/lib/rdge/materials/relief-tunnel-material.js
js/lib/rdge/materials/square-tunnel-material.js
js/lib/rdge/materials/star-material.js
js/lib/rdge/materials/taper-material.js
js/lib/rdge/materials/tunnel-material.js
js/lib/rdge/materials/twist-material.js
js/lib/rdge/materials/twist-vert-material.js
js/lib/rdge/materials/uber-material.js
js/lib/rdge/materials/water-material.js
js/lib/rdge/materials/z-invert-material.js
js/preloader/Preloader.js
Diffstat (limited to 'js/components/gradientpicker.reel/gradientpicker.js')
-rwxr-xr-x | js/components/gradientpicker.reel/gradientpicker.js | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/js/components/gradientpicker.reel/gradientpicker.js b/js/components/gradientpicker.reel/gradientpicker.js index da4e8c0f..b10f6624 100755 --- a/js/components/gradientpicker.reel/gradientpicker.js +++ b/js/components/gradientpicker.reel/gradientpicker.js | |||
@@ -213,21 +213,13 @@ exports.GradientPicker = Montage.create(Component, { | |||
213 | removeStop: { | 213 | removeStop: { |
214 | enumerable: false, | 214 | enumerable: false, |
215 | value: function(stop) { | 215 | value: function(stop) { |
216 | //Removing stops | ||
217 | this.element._components.stopsContainer.removeChild(stop); | ||
218 | //Stopping events related to this current stop | ||
219 | this.removeStopMoving(); | ||
220 | //Resetting stops if less than 2 | ||
221 | var i, buttons = this.element._components.stopsContainer.getElementsByTagName('button'); | 216 | var i, buttons = this.element._components.stopsContainer.getElementsByTagName('button'); |
222 | if (buttons.length < 2) { | 217 | // |
223 | //Removing remaining stops prior to resetting | 218 | if (buttons.length > 2) { |
224 | for (i=0; buttons[i]; i++) { | 219 | //Removing stops |
225 | this.element._components.stopsContainer.removeChild(buttons[i].stop); | 220 | this.element._components.stopsContainer.removeChild(stop); |
226 | } | 221 | //Stopping events related to this current stop |
227 | //Nulling then adding defaults | 222 | this.removeStopMoving(); |
228 | this.value = null; | ||
229 | this.addDefaultStops(); | ||
230 | this._dispatchEvent('change', false); | ||
231 | } | 223 | } |
232 | } | 224 | } |
233 | }, | 225 | }, |
@@ -327,7 +319,7 @@ exports.GradientPicker = Montage.create(Component, { | |||
327 | // | 319 | // |
328 | this.application.ninja.colorController.colorPopupManager.hideColorChipPopup(); | 320 | this.application.ninja.colorController.colorPopupManager.hideColorChipPopup(); |
329 | // | 321 | // |
330 | if ((e._event.y+this.hack.y) > this.element._trackY+50 || (e._event.y+this.hack.y) < this.element._trackY) { | 322 | if ((e._event.y+this.hack.y) > this.element._trackY+70 || (e._event.y+this.hack.y) < this.element._trackY) { |
331 | this.removeStop(this.currentStop); | 323 | this.removeStop(this.currentStop); |
332 | } | 324 | } |
333 | // | 325 | // |