代码拉取完成,页面将自动刷新
/************************************************************************************
<GoSlowDetection> Copyright (C) <2021> <Tao Kiang>
This program comes with ABSOLUTELY NO WARRANTY;
This is free software, and you are welcome to redistribute it
under certain conditions;
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
************************************************************************************/
#include "mainwindow.h"
#include <QApplication>
#include <QSharedMemory>
#include <QMessageBox>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QSharedMemory shared_memory("onlyOneGoslowDetection");//禁止躲开
if(shared_memory.attach())
{
QMessageBox::warning(nullptr, "警告","小伙子,你想干嘛\n软件不是已经打开了吗!", QMessageBox::Ok);
return 0;
}
if(!shared_memory.create(1))
return 0;
MainWindow w;
w.show();
return a.exec();
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。