QtPass
1.4.0
Multi-platform GUI for pass, the standard unix password manager.
Loading...
Searching...
No Matches
src
singleapplication.h
Go to the documentation of this file.
1
#ifndef SINGLEAPPLICATION_H_
2
#define SINGLEAPPLICATION_H_
3
4
#include <QApplication>
5
#include <QLocalServer>
6
#include <QSharedMemory>
7
14
class
SingleApplication
:
public
QApplication {
15
Q_OBJECT
16
public
:
17
SingleApplication
(
int
&argc,
char
*argv[], QString uniqueKey);
18
bool
isRunning
();
19
bool
sendMessage
(
const
QString &message);
20
21
public
slots:
22
void
receiveMessage
();
23
24
signals:
29
void
messageAvailable
(QString message);
30
31
private
:
32
bool
_isRunning;
33
QString _uniqueKey;
34
QSharedMemory sharedMemory;
35
QScopedPointer<QLocalServer> localServer;
36
37
static
const
int
timeout = 1000;
38
};
39
40
#endif
// SINGLEAPPLICATION_H_
SingleApplication
The SingleApplication class is used for commandline intergration.
Definition:
singleapplication.h:14
SingleApplication::isRunning
bool isRunning()
SingleApplication::isRunning is there already a QtPass instance running, to check wether to be server...
Definition:
singleapplication.cpp:64
SingleApplication::receiveMessage
void receiveMessage()
SingleApplication::receiveMessage we have received (a command line) message.
Definition:
singleapplication.cpp:44
SingleApplication::sendMessage
bool sendMessage(const QString &message)
SingleApplication::sendMessage send a message (from commandline) to an already running QtPass instanc...
Definition:
singleapplication.cpp:72
SingleApplication::messageAvailable
void messageAvailable(QString message)
messageAvailable notification from commandline
SingleApplication
#define SingleApplication
Definition:
mainwindow.h:15
Generated by
1.9.6