mirror of
https://gitee.com/spark-store-project/spark-store
synced 2025-09-03 01:42:20 +08:00
菜单中加入投稿按钮,拉起默认浏览器进入投稿
https://gitee.com/deepin-community-store/spark-store/issues/I1VD2Q
This commit is contained in:
parent
c23e816017
commit
bd8f660fe9
@ -148,12 +148,19 @@ void Widget::initUI()
|
|||||||
// titlebar->setAutoHideOnFullscreen(true);
|
// titlebar->setAutoHideOnFullscreen(true);
|
||||||
|
|
||||||
// 添加菜单项
|
// 添加菜单项
|
||||||
|
QAction *actionSubmission = new QAction("软件投稿", this);
|
||||||
QAction *setting=new QAction("设置");
|
QAction *setting=new QAction("设置");
|
||||||
|
|
||||||
QMenu *menu=new QMenu;
|
QMenu *menu=new QMenu;
|
||||||
|
|
||||||
menu->addAction(setting);
|
menu->addAction(setting);
|
||||||
|
menu->addAction(actionSubmission);
|
||||||
titlebar->setMenu(menu);
|
titlebar->setMenu(menu);
|
||||||
|
connect(actionSubmission, &QAction::triggered, this,
|
||||||
|
[=](){QDesktopServices::openUrl(QUrl("https://upload.spark-app.store/"));});
|
||||||
connect(setting,&QAction::triggered,this,&Widget::opensetting);
|
connect(setting,&QAction::triggered,this,&Widget::opensetting);
|
||||||
|
|
||||||
|
|
||||||
// 初始化菜单数组
|
// 初始化菜单数组
|
||||||
left_list[0]=ui->menu_main;
|
left_list[0]=ui->menu_main;
|
||||||
left_list[1]=ui->menu_network;
|
left_list[1]=ui->menu_network;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user