Bug 741 - GUI doesn't have an exit button
Summary: GUI doesn't have an exit button
Status: RESOLVED FIXED
Alias: None
Product: Chess Game - Group 24
Classification: Unclassified
Component: GUI (show other bugs)
Version: unspecified
Hardware: PC Mac OS
: --- enhancement
Assignee: gsalter2-c
URL:
Depends on:
Blocks:
 
Reported: 2022-11-28 02:37 HKT by gsalter2-c
Modified: 2022-11-28 14:35 HKT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gsalter2-c 2022-11-28 02:37:33 HKT
Steps to reproduce:
1. Run App.java

Expected results:
There should be an exit button to close the game.

Actual results:
Currently, we have to interrupt the game through the terminal.
Comment 1 gsalter2-c 2022-11-28 02:40:35 HKT
Reason:
frame.setUndecorated is set to true.

Resolution:
Set frame.setUndecorated to false.
Another issue arises when frame.setUndecorated is set to false, pieces on the board are shifted about 12 pixels down, we need to add this offset when handling mouse click event on the GUI.

https://github.com/glennsalter/cs3343-chess/commit/b21243b28d9fdad55400f419b2f12655e468e151