File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
packages/webamp-modern-2/src Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -170,7 +170,6 @@ export class UIRoot {
170170 }
171171 const url = imgCache . get ( groupId ) ;
172172 // TODO: Techincally we only need one per image/gammagroup.
173- console . log ( "Setting css var" ) ;
174173 this . _div . style . setProperty ( bitmap . getCSSVar ( ) , `url(${ url } )` ) ;
175174 }
176175 }
Original file line number Diff line number Diff line change @@ -29,9 +29,6 @@ export default class GuiObj extends XmlObj {
2929
3030 constructor ( ) {
3131 super ( ) ;
32- this . _div . addEventListener ( "mouseup" , ( e ) => {
33- this . onLeftButtonUp ( e . clientX , e . clientY ) ;
34- } ) ;
3532
3633 this . _div . addEventListener ( "mousedown" , ( e ) => {
3734 /*
@@ -59,6 +56,12 @@ export default class GuiObj extends XmlObj {
5956 }
6057 */
6158 this . onLeftButtonDown ( e . clientX , e . clientY ) ;
59+
60+ const mouseUpHandler = ( e ) => {
61+ this . onLeftButtonUp ( e . clientX , e . clientY ) ;
62+ this . _div . removeEventListener ( "mouseup" , mouseUpHandler ) ;
63+ } ;
64+ this . _div . addEventListener ( "mouseup" , mouseUpHandler ) ;
6265 } ) ;
6366 this . _div . addEventListener ( "mouseenter" , ( e ) => {
6467 this . onEnterArea ( ) ;
You can’t perform that action at this time.
0 commit comments