From 6f585973dc2989d1a8e9fb8e443e78a3de7845d0 Mon Sep 17 00:00:00 2001 From: Itay Grudev Date: Wed, 10 Aug 2016 02:43:30 +0100 Subject: Added a basic usage example --- examples/basic/basic.pro | 5 +++++ examples/basic/main.cpp | 9 +++++++++ 2 files changed, 14 insertions(+) create mode 100755 examples/basic/basic.pro create mode 100755 examples/basic/main.cpp (limited to 'examples') diff --git a/examples/basic/basic.pro b/examples/basic/basic.pro new file mode 100755 index 0000000..b7af16c --- /dev/null +++ b/examples/basic/basic.pro @@ -0,0 +1,5 @@ +# Single Application implementation +include(../../singleapplication.pri) +DEFINES += QAPPLICATION_CLASS=QCoreApplication + +SOURCES += main.cpp diff --git a/examples/basic/main.cpp b/examples/basic/main.cpp new file mode 100755 index 0000000..4787d1c --- /dev/null +++ b/examples/basic/main.cpp @@ -0,0 +1,9 @@ +#include + +int main(int argc, char *argv[]) +{ + // Allow secondary instances + SingleApplication app( argc, argv ); + + return app.exec(); +} -- cgit v1.2.1