当前位置: 首页 > news >正文

京津冀协同发展黑帽seo联系方式

京津冀协同发展,黑帽seo联系方式,专业网上商城开发,用手机制作视频的软件效果 在程序启动后,有时不会进入到工作页面,会进入到产品展示页面。 动画如下: 首页展示 页面操作 当不点击时,一秒自动刷新一次;当点击时,会自动跳转到对应页面;点击上一页、下一页、及跳转页…

效果

在程序启动后,有时不会进入到工作页面,会进入到产品展示页面。
动画如下:

首页展示

页面操作

  • 当不点击时,一秒自动刷新一次;
  • 当点击时,会自动跳转到对应页面;
  • 点击上一页、下一页、及跳转页数,会自动跳转。

UI设计

在这里插入图片描述

示例

注释在代码中,代码可运行。
.h

#ifndef MAINWINDOW_H
#define MAINWINDOW_H#include <QMainWindow>#include <QMap>
#include <QRadioButton>
#include <QButtonGroup>
namespace Ui {
class MainWindow;
}class MainWindow : public QMainWindow
{Q_OBJECTpublic:explicit MainWindow(QWidget *parent = nullptr);~MainWindow();private:Ui::MainWindow *ui;// 用于管理选择按钮QMap<int, QRadioButton*>    m_mapRadios;// 加入组QButtonGroup*               m_pBtnGroup;
};#endif // MAINWINDOW_H

.cpp

#include "mainwindow.h"
#include "ui_mainwindow.h"#include <QDebug>
#include <QLabel>
#include <QFont>#include <QTimer>MainWindow::MainWindow(QWidget *parent) :QMainWindow(parent),ui(new Ui::MainWindow)
{ui->setupUi(this);ui->pushButton->setStyleSheet("QPushButton {background-color: #eeeeee; outline: none;}");ui->pushButton_2->setStyleSheet("QPushButton {background-color: #eeeeee; outline: none;}");m_pBtnGroup = new QButtonGroup(this);ui->horizontalLayout->addStretch();// 循环创建按钮for (int var = 0; var < 5; ++var) {QRadioButton* pR = new QRadioButton(QString::number(var+1));m_mapRadios.insert(var, pR);ui->horizontalLayout->addWidget(pR);// 加入组m_pBtnGroup->addButton(pR, var);}ui->horizontalLayout->addStretch();// 加入mapm_mapRadios.value(m_mapRadios.keys().first())->setChecked(true);// 循环创建展示界面for (int var = 0; var < 5; ++var) {// 设置信息QLabel* pLabel = new QLabel(this);pLabel->setText(QString("第%1页面").arg(var+1));pLabel->resize(150, 100);QFont font = pLabel->font();font.setPointSize(23);font.setBold(true);pLabel->setFont(font);pLabel->setStyleSheet("QLabel{color:#ff0000;}");pLabel->move(width()/2, height()/2);ui->stackedWidget->insertWidget(ui->stackedWidget->count(), pLabel);}ui->stackedWidget->setCurrentIndex(0);// 根据点击按钮,同步展示页面connect(m_pBtnGroup, static_cast<void (QButtonGroup::*)(int)>(&QButtonGroup::buttonClicked), this, [=](int nId){ui->stackedWidget->setCurrentIndex(nId);});// 定时器QTimer* pTimer = new QTimer(this);connect(pTimer, &QTimer::timeout, this, [=](){// 每一秒更新一次int nIndex = ui->stackedWidget->currentIndex();if(nIndex < 4){ui->stackedWidget->setCurrentIndex(nIndex+1);m_mapRadios.value(nIndex+1)->setChecked(true);}else{ui->stackedWidget->setCurrentIndex(0);m_mapRadios.value(0)->setChecked(true);}});connect(ui->pushButton, &QPushButton::clicked, this, [=](){int nIndex = ui->stackedWidget->currentIndex();if(nIndex > 0){ui->stackedWidget->setCurrentIndex(nIndex-1);m_mapRadios.value(nIndex-1)->setChecked(true);}});connect(ui->pushButton_2, &QPushButton::clicked, this, [=](){int nIndex = ui->stackedWidget->currentIndex();if(nIndex < 4){ui->stackedWidget->setCurrentIndex(nIndex+1);m_mapRadios.value(nIndex+1)->setChecked(true);}});pTimer->start(1000);}MainWindow::~MainWindow()
{delete ui;
}

结论

可将每页显示的改为产品或者介绍图,实现业务。

http://www.hkea.cn/news/616875/

相关文章:

  • 网站建设课程简介图片百度官网认证免费
  • 月夜影视在线观看免费完整版韩剧关键词排名优化报价
  • 做网站的工作时间兰州seo公司
  • css怎么嵌入到html直通车关键词优化口诀
  • 虚拟网站php专业型seo网站关键词排名提升
  • 找人合伙做网站平台b2b电商平台
  • 手机网站建设技术方案找网站设计公司
  • 杭州如何设计公司网站惠州seo网站推广
  • 成都网站建设门户大连企业网站建站模板
  • 游戏卡充值可以做网站吗百度竞价关键词出价技巧
  • 建设企业网站就等于开展网络营销网店推广实训报告
  • dede无法更新网站主页到百度联盟注册
  • wordpress支持爱奇艺企业网站seo托管怎么做
  • 永川做网站的武汉百度快速排名提升
  • 做网站的故意给中病毒网络营销广告
  • 关于阅读类网站的建设规划书友情链接系统
  • 专业做幼儿园设计的网站百度小程序关键词优化
  • 腾龙时时彩做号网站整站优化关键词排名
  • 正规的网站制作与推广百度广告运营
  • 网站建设估价引擎搜索有哪些
  • 东莞网站建设选菲凡网络如何制作网站
  • 网站收录系统备案查询官网
  • 临朐县网站建设利用搜索引擎营销成功的案例
  • 利用网盘做视频网站镇江优化推广
  • 视频微网站开发哪个公司网站设计好
  • 品网站建设智能搜索引擎
  • 怎样在百度建网站seo建设者
  • 四海网络网站建设咨询什么叫做网络营销
  • 安徽建设网官方网站优化分析
  • 网站根目录文件名游戏推广员是做什么的