How to add JPanel by clicking JButton?

前端 未结 2 1626
没有蜡笔的小新
没有蜡笔的小新 2020-11-29 08:39

I\'m trying to create a small GUI, it has 2 JButtons, and 2 JPanels with some drawing animation on each of them. By default it must show first JPanel, and by clicking on sec

2条回答
  •  一生所求
    2020-11-29 09:29

    I think you can just use CardLayout to implement your function. Please refer to here

提交回复
热议问题