mapons / QtMainLoopWDT

GNU Lesser General Public License v3.0
22 stars 7 forks source link

Main loop watch dog timer for Qt & QML

When the main loop freezes, this component can kill or restart the current application, just by adding two lines of code.

You can also use the application restart function, for a complete restart of your application.

See in action (video)

Demo in Windows 10

HOW IT WORKS:

USAGE:

create object in main function, just before main loop exec:

mainLoopWdt wdt(true,2000, 5000,0, &app);
wdt.startWdt();
return app.exec();

Tested OS:

Tested main loop locks:

Restart estrategy

Delayed restart estrategy

License

Main loop WDT for Qt & QML is released under the terms of the GNU LGPL v3 License. Full details in license.txt file.