Qt 引导
最编程
2024-09-29 22:38:20
...
#include <QDir>
#include <QStandardPaths>
void MainWindow::regAppBoot(bool bIs)
{
#ifdef WIN32
QString exePath = qApp->applicationFilePath();
QString exeName = qApp->applicationName();
QString startupPath = QStandardPaths::writableLocation(QStandardPaths::ApplicationsLocation).
append("/").append("Startup");
if (bIs)
{
QDir dir(startupPath);
if (!dir.exists())
{
dir.mkdir(startupPath);
}
if (dir.exists())
{
QString exeLocation = startupPath + "/" + exeName + ".lnk";
QFile::link(exePath, exeLocation);
}
}
else
{
QDir dir(startupPath);
上一篇: Http - 浏览器发出请求和接收响应的步骤是什么?
下一篇: 设计模式面试题
推荐阅读
-
Qt --- 系统相关 --- 事件、文件操作、多线程编程、网络编程、多媒体
-
QT 开发 - Pyside]使用 Pycharm 和 conda 配置 Pyside 环境和新项目
-
Qt 多线程和数据库
-
Qt6.7 开发 Android 程序间接连接 MySQL 的方法
-
Qt 引导
-
QT 5 调试软件 + Linux 调用脚本 shell - 无法调度 + 目录拼写 + 找不到目录 + sudo 权限 (2) + 问题解决 + 后续补充] QT 5 调试软件 + Linux 调用脚本 shell - 无法调度 + 目录拼写 + 找不到目录 + sudo 权限 (2) + 问题解决 + 后续补充
-
重新审视 QT 界面开发 - 获取 QT 的社区版本 - 2024-09
-
Qt QML VideoOutput 显示自定义的 YUV420P 数据流
-
使用Qt开发音视频应用:通过FFmpeg解码本地摄像头并转换yuv422为yuv420
-
Qt编写ffmpeg本地摄像头显示(16路本地摄像头CPU占用率为3.2%)