]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/atomic.h
Extract X11 Display wrapper class in a private header.
[wxWidgets.git] / interface / wx / atomic.h
CommitLineData
23324ae1 1/////////////////////////////////////////////////////////////////////////////
7c913512 2// Name: atomic.h
e54c96f1 3// Purpose: interface of global functions
7c913512
FM
4// Author: wxWidgets team
5// RCS-ID: $Id$
526954c5 6// Licence: wxWindows licence
7c913512
FM
7/////////////////////////////////////////////////////////////////////////////
8
39fb8056
FM
9
10// ============================================================================
11// Global functions/macros
12// ============================================================================
13
b21126db 14/** @addtogroup group_funcmacro_atomic */
39fb8056
FM
15//@{
16
7c913512 17/**
39fb8056 18 This function increments @a value in an atomic manner.
1ba0de2e 19
42124e68
VZ
20 Whenever possible wxWidgets provides an efficient, CPU-specific,
21 implementation of this function. If such implementation is available, the
22 symbol wxHAS_ATOMIC_OPS is defined. Otherwise this function still exists
23 but is implemented in a generic way using a critical section which can be
24 prohibitively expensive for use in performance-sensitive code.
25
1ba0de2e 26 @header{wx/atomic.h}
23324ae1
FM
27*/
28void wxAtomicInc(wxAtomicInt& value);
29
39fb8056 30/**
42124e68
VZ
31 This function decrements value in an atomic manner.
32
33 Returns 0 if value is 0 after decrement or any non-zero value (not
34 necessarily equal to the value of the variable) otherwise.
35
36 @see wxAtomicInc
1ba0de2e
BP
37
38 @header{wx/atomic.h}
39fb8056
FM
39*/
40wxInt32 wxAtomicDec(wxAtomicInt& value);
23324ae1 41
39fb8056 42//@}
1ba0de2e 43