diff options
author | Christoph Cullmann <christoph@cullmann.io> | 2022-04-05 22:46:42 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-05 23:46:42 +0300 |
commit | 611e48abbbcaea7e59352c277db0ca2c24369eb8 (patch) | |
tree | af45f4ddced1b25c125ce2a440a830c8fe9dcef0 /singleapplication.cpp | |
parent | Merge pull request #153 from itay-grudev/lts-only (diff) | |
download | singleapplication-611e48abbbcaea7e59352c277db0ca2c24369eb8.tar.xz |
Provide API for blocking sendMessage (#154)
Diffstat (limited to 'singleapplication.cpp')
-rw-r--r-- | singleapplication.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/singleapplication.cpp b/singleapplication.cpp index 09e264e..1234ff9 100644 --- a/singleapplication.cpp +++ b/singleapplication.cpp @@ -235,9 +235,10 @@ QString SingleApplication::currentUser() const * Sends message to the Primary Instance. * @param message The message to send. * @param timeout the maximum timeout in milliseconds for blocking functions. + * @param sendMode mode of operation * @return true if the message was sent successfuly, false otherwise. */ -bool SingleApplication::sendMessage( const QByteArray &message, int timeout ) +bool SingleApplication::sendMessage( const QByteArray &message, int timeout, SendMode sendMode ) { Q_D( SingleApplication ); @@ -248,7 +249,7 @@ bool SingleApplication::sendMessage( const QByteArray &message, int timeout ) if( ! d->connectToPrimary( timeout, SingleApplicationPrivate::Reconnect ) ) return false; - return d->writeConfirmedMessage( timeout, message ); + return d->writeConfirmedMessage( timeout, message, sendMode ); } /** |