Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
ee21c443
Commit
ee21c443
authored
Jan 15, 2001
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replaced X11DRV_CritSection references by wine_tsx11_(un)lock.
parent
8efd4540
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
21 deletions
+18
-21
brush.c
graphics/x11drv/brush.c
+2
-2
wine_gl.h
include/wine_gl.h
+3
-2
clipboard.c
windows/x11drv/clipboard.c
+7
-10
event.c
windows/x11drv/event.c
+6
-7
No files found.
graphics/x11drv/brush.c
View file @
ee21c443
...
...
@@ -112,7 +112,7 @@ static Pixmap BRUSH_DitherColor( DC *dc, COLORREF color )
unsigned
int
x
,
y
;
Pixmap
pixmap
;
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
(
);
if
(
color
!=
prevColor
)
{
int
r
=
GetRValue
(
color
)
*
DITHER_LEVELS
;
...
...
@@ -138,7 +138,7 @@ static Pixmap BRUSH_DitherColor( DC *dc, COLORREF color )
MATRIX_SIZE
,
MATRIX_SIZE
,
X11DRV_GetDepth
()
);
XPutImage
(
display
,
pixmap
,
BITMAP_colorGC
,
ditherImage
,
0
,
0
,
0
,
0
,
MATRIX_SIZE
,
MATRIX_SIZE
);
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
(
);
return
pixmap
;
}
...
...
include/wine_gl.h
View file @
ee21c443
...
...
@@ -11,11 +11,12 @@
#if defined(HAVE_OPENGL)
#include "ts_xlib.h"
#include "x11drv.h"
/* As GLX relies on X, this is needed */
#define ENTER_GL()
EnterCriticalSection( &X11DRV_CritSection
)
#define LEAVE_GL()
LeaveCriticalSection( &X11DRV_CritSection
)
#define ENTER_GL()
wine_tsx11_lock(
)
#define LEAVE_GL()
wine_tsx11_unlock(
)
#undef APIENTRY
#undef CALLBACK
...
...
windows/x11drv/clipboard.c
View file @
ee21c443
...
...
@@ -359,8 +359,7 @@ int X11DRV_CLIPBOARD_CacheDataFormats( Atom SelectionName )
TRACE
(
"Requesting TARGETS selection for '%s' (owner=%08x)...
\n
"
,
TSXGetAtomName
(
display
,
selectionCacheSrc
),
(
unsigned
)
ownerSelection
);
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
();
XConvertSelection
(
display
,
selectionCacheSrc
,
aTargets
,
TSXInternAtom
(
display
,
"SELECTION_DATA"
,
False
),
w
,
CurrentTime
);
...
...
@@ -374,7 +373,7 @@ int X11DRV_CLIPBOARD_CacheDataFormats( Atom SelectionName )
if
(
xe
.
xselection
.
selection
==
selectionCacheSrc
)
break
;
}
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
(
);
/* Verify that the selection returned a valid TARGETS property */
if
(
(
xe
.
xselection
.
target
!=
aTargets
)
...
...
@@ -797,7 +796,7 @@ void X11DRV_ReleaseClipboard(void)
TRACE
(
"
\t
giving up selection (spw = %08x)
\n
"
,
(
unsigned
)
selectionPrevWindow
);
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
(
);
TRACE
(
"Releasing CLIPBOARD selection
\n
"
);
XSetSelectionOwner
(
display
,
xaClipboard
,
None
,
CurrentTime
);
...
...
@@ -815,8 +814,7 @@ void X11DRV_ReleaseClipboard(void)
while
(
!
XCheckTypedWindowEvent
(
display
,
selectionPrevWindow
,
SelectionClear
,
&
xe
)
);
}
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
();
}
/* Get rid of any Pixmap resources we may still have */
...
...
@@ -1028,8 +1026,7 @@ BOOL X11DRV_GetClipboardData(UINT wFormat)
TRACE
(
"Requesting %s selection from %s...
\n
"
,
TSXGetAtomName
(
display
,
propRequest
),
TSXGetAtomName
(
display
,
selectionCacheSrc
)
);
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
();
XConvertSelection
(
display
,
selectionCacheSrc
,
propRequest
,
TSXInternAtom
(
display
,
"SELECTION_DATA"
,
False
),
w
,
CurrentTime
);
...
...
@@ -1042,8 +1039,8 @@ BOOL X11DRV_GetClipboardData(UINT wFormat)
if
(
xe
.
xselection
.
selection
==
selectionCacheSrc
)
break
;
}
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
(
);
/*
* Read the contents of the X selection property into WINE's
* clipboard cache converting the selection to be compatible if possible.
...
...
windows/x11drv/event.c
View file @
ee21c443
...
...
@@ -191,16 +191,15 @@ static void CALLBACK EVENT_ProcessAllEvents( ULONG_PTR arg )
TRACE
(
"called (thread %lx).
\n
"
,
GetCurrentThreadId
()
);
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
(
);
while
(
XPending
(
display
)
)
{
XNextEvent
(
display
,
&
event
);
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
();
EVENT_ProcessEvent
(
&
event
);
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
(
);
}
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
(
);
}
/***********************************************************************
...
...
@@ -894,7 +893,7 @@ static void EVENT_GetGeometry( Window win, int *px, int *py,
Window
root
,
top
;
int
x
,
y
,
width
,
height
,
border
,
depth
;
EnterCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_lock
(
);
/* Get the geometry of the window */
XGetGeometry
(
display
,
win
,
&
root
,
&
x
,
&
y
,
&
width
,
&
height
,
...
...
@@ -903,7 +902,7 @@ static void EVENT_GetGeometry( Window win, int *px, int *py,
/* Translate the window origin to root coordinates */
XTranslateCoordinates
(
display
,
win
,
root
,
0
,
0
,
&
x
,
&
y
,
&
top
);
LeaveCriticalSection
(
&
X11DRV_CritSection
);
wine_tsx11_unlock
(
);
*
px
=
x
;
*
py
=
y
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment