/////////////////////////////////////////////////////////////////////////////
// Name: snglinst.h
-// Purpose: documentation for wxSingleInstanceChecker class
+// Purpose: interface of wxSingleInstanceChecker
// Author: wxWidgets team
// RCS-ID: $Id$
// Licence: wxWindows license
}
@endcode
- Note using wxGetUserId to construct the name: this
+ Note using wxGetUserId() to construct the name: this
allows different user to run the application concurrently which is usually the
intended goal. If you don't use the user name in the wxSingleInstanceChecker
name, only one user would be able to run the application at a time.
Note that you can't call Create() more than once, so calling it if the
@ref wxsingleinstancechecker() "non default ctor"
had been used is an error.
-
+
@param name
must be given and be as unique as possible. It is used as the
mutex name under Win32 and the lock file name under Unix.
is optional and is ignored under Win32 and used as the directory to
create the lock file in under Unix (default is
wxGetHomeDir())
-
+
@returns Returns @false if initialization failed, it doesn't mean that
another instance is running - use IsAnotherRunning()
to check for it.
Returns @true if another copy of this program is already running, @false
otherwise.
*/
- bool IsAnotherRunning();
+ bool IsAnotherRunning() const;
};
+