Qt添加右键菜单

    QAction *hideAction = new QAction(tr(" 隐藏"),this);
    addAction(hideAction);
    setContextMenuPolicy(Qt::ActionsContextMenu);

 

posted @ 2017-12-09 12:31  风来风往风伤(TiAmo)  阅读(511)  评论(0编辑  收藏  举报