kevingo
Fri Oct 31 16:41:26 CST 2003
You did not state if you wished to change this behaviour in your own
application or across the entire operating system. If you wish to change
the behaviour in your own application this can be done when you call
SHRecognizeGesture. If you wish the longer delay across all the common
controls on your device, you can set the
HKEY_LOCAL_MACHINE\System\GWE\Commctrl\UseLongDelayForGestures registry key
to DWORD: 1.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceui40/htm
l/_cerefcommoncontrolregistrysettings.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceui40/htm
l/_cerefshrecognizegesture.asp
Unfortunately the delay times are not settable, you can only choose between
400ms and 800ms.
Kevin
--------------------------
From: "skyblue" <skyblue@atriumcni.com>
Subject: Re: How to set the ativity time of mouse right button in AYGSHELL
API SET?
Date: Thu, 30 Oct 2003 16:43:21 +0900
Newsgroups: microsoft.public.windowsce.platbuilder
Dear Kevin
Thanks much for your support.
We are developing a web pad and build the ce image included AYGSHELL API
SET.
When we pressed the stylus in the same spot for some short period of time(ce
default about 1 sec),
It was displayed the pressed Right button message box.
I want to take long time(2 seconds) for pressed the stylus in the same spot
for some short period of time.
I found the SHRecognizeGesture function at
Wince420\others\MFC\SRC\wincore.cpp
If we add "SHRG_LONGDELAY" at the shrgi.dwflags at thi sfile, can we solve
this issue?
How can we solve this issue?
;--------------------------------------------------
BOOL CWnd::SHRecognizeGesture(CPoint point, BOOL bSendNotification /* = TRUE
*/)
{
SHRGINFO shrgi = {0};
shrgi.cbSize = sizeof(SHRGINFO);
shrgi.hwndClient = m_hWnd;
shrgi.ptDown.x = point.x;
shrgi.ptDown.y = point.y;
shrgi.dwFlags = SHRG_RETURNCMD;
if(GN_CONTEXTMENU == ::SHRecognizeGesture(&shrgi))
{
if(bSendNotification)
{
shrgi.dwFlags = SHRG_NOTIFYPARENT;
::SHRecognizeGesture(&shrgi);
}
return TRUE;
}
else
return FALSE;
}
;;---------------------------------
Our system spec:
CPU : X86
OS : Win CE.NET 4.2
Thanks.,
SKyblue Ahn
"Kevin Goldsmith" <kevingo@online.microsoft.com> wrote in message
news:jCKXO5MmDHA.2088@cpmsftngxa06.phx.gbl...
> Is this in a control that you created or is this in a shell control?
>
> The behaviour that you are describing comes from the Aygshell call
> "SHRecognizeGesture" which is usually placed in the WM_LBUTTONDOWN handler
> of your window. That call takes a SHRGINFO structure, whose dwFlags
member
> can be or'd with a SHRG_LONGDELAY flag to double the amount of time that
it
> will spend before it will recognize a gesture. If you give me some more
> details about how you are using this API, I can give you some more
specific
> advice.
>
> Kevin Goldsmith
>
>
> kevingo@online.microsoft.com (remove "online" from reply-to address)
> _____________________________________________________________
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> _____________________________________________________________
>
kevingo@online.microsoft.com (remove "online" from reply-to address)
_____________________________________________________________
This posting is provided "AS IS" with no warranties, and confers no rights.
_____________________________________________________________