Code style improvements

This commit is contained in:
Itay Grudev 2016-05-04 21:05:59 +01:00
parent fd8004c706
commit 5e67bf9751
2 changed files with 8 additions and 9 deletions

View File

@ -22,7 +22,7 @@ class SingleApplicationPrivate {
public:
Q_DECLARE_PUBLIC(SingleApplication)
SingleApplicationPrivate(SingleApplication *q_ptr) : q_ptr(q_ptr) {
SingleApplicationPrivate( SingleApplication *q_ptr ) : q_ptr( q_ptr ) {
server = NULL;
}
@ -84,7 +84,7 @@ public:
socket.connectToServer( memory->key() );
// Notify the parent that a new instance had been started;
socket.waitForConnected(100);
socket.waitForConnected( 100 );
socket.close();
}
@ -118,7 +118,7 @@ public:
signal( SIGXFSZ, SingleApplicationPrivate::terminate ); // 25
}
static void terminate(int signum)
static void terminate( int signum )
{
while( ! sharedMem.empty() ) {
delete sharedMem.back();
@ -161,8 +161,8 @@ public:
* @param argc
* @param argv
*/
SingleApplication::SingleApplication(int &argc, char *argv[], uint8_t secondaryInstances)
: app_t(argc, argv), d_ptr(new SingleApplicationPrivate(this))
SingleApplication::SingleApplication( int &argc, char *argv[], uint8_t secondaryInstances )
: app_t( argc, argv ), d_ptr( new SingleApplicationPrivate( this ) )
{
Q_D(SingleApplication);

View File

@ -1,5 +1,6 @@
#ifndef SINGLE_APPLICATION_H
#define SINGLE_APPLICATION_H
#include <QtCore/QtGlobal>
#ifndef QAPPLICATION_CLASS
@ -22,7 +23,7 @@ class SingleApplication : public QAPPLICATION_CLASS
typedef QAPPLICATION_CLASS app_t;
public:
explicit SingleApplication(int &argc, char *argv[], uint8_t secondaryInstances = 0);
explicit SingleApplication( int &argc, char *argv[], uint8_t secondaryInstances = 0 );
~SingleApplication();
bool isPrimary();
@ -36,8 +37,6 @@ private Q_SLOTS:
private:
SingleApplicationPrivate *d_ptr;
};
#endif // SINGLE_APPLICATION_H