Skip to content

Commit

Permalink
Code style improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
itay-grudev committed May 4, 2016
1 parent fd8004c commit 5e67bf9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
12 changes: 6 additions & 6 deletions singleapplication.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}

Expand Down Expand Up @@ -84,7 +84,7 @@ class SingleApplicationPrivate {
socket.connectToServer( memory->key() );

// Notify the parent that a new instance had been started;
socket.waitForConnected(100);
socket.waitForConnected( 100 );
socket.close();
}

Expand Down Expand Up @@ -118,7 +118,7 @@ class SingleApplicationPrivate {
signal( SIGXFSZ, SingleApplicationPrivate::terminate ); // 25
}

static void terminate(int signum)
static void terminate( int signum )
{
while( ! sharedMem.empty() ) {
delete sharedMem.back();
Expand Down Expand Up @@ -147,7 +147,7 @@ class SingleApplicationPrivate {

QSharedMemory *memory;
SingleApplication *q_ptr;
QLocalServer *server;
QLocalServer *server;
};

#ifdef Q_OS_UNIX
Expand All @@ -161,8 +161,8 @@ class SingleApplicationPrivate {
* @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);

Expand Down
5 changes: 2 additions & 3 deletions singleapplication.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#ifndef SINGLE_APPLICATION_H
#define SINGLE_APPLICATION_H

#include <QtCore/QtGlobal>

#ifndef QAPPLICATION_CLASS
Expand All @@ -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();
Expand All @@ -36,8 +37,6 @@ private Q_SLOTS:

private:
SingleApplicationPrivate *d_ptr;


};

#endif // SINGLE_APPLICATION_H

0 comments on commit 5e67bf9

Please sign in to comment.