user interface - java- why is my "deposit" method not working for my ATM with gui? -
i'm making atm in user must first enter pin (1234), , once pin entered correctly, user can either withdraw 50, 100, or 200 dollars or make deposit under $1000. withdraw methods working, when run program , try make deposit, nothing happens after enter amount , try hit "enter" button. seems if enter button not working. here code used deposit method: if (event.getsource() == deposit) { instructionscreen.settext("enter amount deposit, click enter."); if (event.getsource() == enter) { savescreen = displayinput.gettext(); double add = double.parsedouble(savescreen); if (add <= 1000) { balance += add; instructionscreen.settext("your new balance $" + balance + "."); } else { instructionscreen.settext("the maximum amount can deposit $1000. please enter new amount."); displayinput.settext(""); if (event.getsource() == enter) { ...