我有显示行许多项目的自定义窗口小部件: void update(){ //this is a SLOT which is connected to a button click
QVBoxLayout *layout = this->layout();
if (layout == NULL){
layout = new QVBoxLayout;
this
为什么下面的代码不起作用?基本上,这是一个更困难的程序的简化版本,我在其中尝试创建一个可运行的初始屏幕,然后将选择按钮链接到不同的可运行的按钮,但这并不像我预期的那样运行。 import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.*;
public class R