Commit 20276da9 authored by John Klehm's avatar John Klehm Committed by Alexandre Julliard

wintab32: Support overlap statuses in WTEnable.

parent 212488d8
...@@ -622,15 +622,27 @@ BOOL WINAPI WTEnable(HCTX hCtx, BOOL fEnable) ...@@ -622,15 +622,27 @@ BOOL WINAPI WTEnable(HCTX hCtx, BOOL fEnable)
{ {
LPOPENCONTEXT context; LPOPENCONTEXT context;
TRACE("(%p, %u)\n", hCtx, fEnable); TRACE("hCtx=%p, fEnable=%u\n", hCtx, fEnable);
if (!hCtx) return 0; if (!hCtx) return FALSE;
EnterCriticalSection(&csTablet); EnterCriticalSection(&csTablet);
context = TABLET_FindOpenContext(hCtx); context = TABLET_FindOpenContext(hCtx);
if(!fEnable) /* if we want to enable and it is not enabled then */
if(fEnable && !context->enabled)
{
context->enabled = TRUE;
/* TODO: Add to top of overlap order */
context->context.lcStatus = CXS_ONTOP;
}
/* if we want to disable and it is not disabled then */
else if (!fEnable && context->enabled)
{
context->enabled = FALSE;
/* TODO: Remove from overlap order?? needs a test */
context->context.lcStatus = CXS_DISABLED;
TABLET_FlushQueue(context); TABLET_FlushQueue(context);
context->enabled = fEnable; }
LeaveCriticalSection(&csTablet); LeaveCriticalSection(&csTablet);
return TRUE; return TRUE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment