Fixed button bug with area interaction.

This commit is contained in:
2019-09-17 15:14:57 +02:00
parent 42afa3e7ab
commit 71e5ce8b8e
4 changed files with 16 additions and 25 deletions
+4 -4
View File
@@ -632,10 +632,10 @@ export default class Button extends PIXI.Container {
* @return {Button} A reference to the button for chaining.
*/
hide() {
this.opts.strokeAlpha = 0
this.opts.strokeActiveAlpha = 0
this.opts.fillAlpha = 0
this.opts.fillActiveAlpha = 0
this.opts.strokeAlpha = 0.0
this.opts.strokeActiveAlpha = 0.0
this.opts.fillAlpha = 0.0000000001 // WORKAROUND: See https://github.com/pixijs/pixi.js/wiki/v5-Migration-Guide#graphics-interaction
this.opts.fillActiveAlpha = 0.0000000001
this.layout()