Fix adding functions to invoke in UiButton

This commit is contained in:
Michał Czekański 2020-04-04 21:37:42 +02:00
parent 65c9171428
commit 8b126f636b

View File

@ -24,7 +24,9 @@ class UiButton(UiElement):
self.beingClicked = False
self.image = self._images[0]
self.functionsToInvokeWhenClicked = functionsToInvokeWhenClicked
self.functionsToInvokeWhenClicked = []
self.functionsToInvokeWhenClicked.extend(functionsToInvokeWhenClicked)
def eventHandler(self, event):
# change selected color if rectangle clicked