资讯
A much better solution is to add the MouseListener to the Panel or Canvas to which you are drawing all these squares. Then, in that MouseListener, do calculation to determine which square was clicked.
当前正在显示可能无法访问的结果。
隐藏无法访问的结果当前正在显示可能无法访问的结果。
隐藏无法访问的结果