locked
How to disable Window Auto Gestures for PropertySheet / PropertyPage RRS feed

  • Question

  • Hi,

    I have an MFC Windows Mobile application, where I'd like to turn off WAG for a dialog.
    This dialog is derived from CPropertySheet.

    I tried to disable WAG for the PropertySheet and for individual PropertyPage-s, but WAG is still on.

    Any ideas?


    BalintN
    Friday, April 16, 2010 2:55 PM

Answers

  • Hi BalintN,

    For the dialog, please try to capture WM_Geture message and block the message, like the code below:
    case WM_GESTURE:
                {

                   //block it here

                }

     

    For more information:
    http://msdn.microsoft.com/en-us/library/ee220936.aspx

    WM6.5 DTK provide the sample about WM_Gesture message.

    C:\Program Files\Windows Mobile 6 SDK\Windows Mobile 6.5 Developer Tool Kit\Samples\PocketPC

    Best regards,
    Guang-Ming Bian - MSFT


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Tuesday, April 20, 2010 9:43 AM
  • I tried. It did not work.

    Here is the final verdict: TO ____ WITH WINDOW AUTO GESTURES! In File Explorer, it even prevents you from selecting multiple files. In my application it prevents combo boxes from scrolling. It's flawed, its wrong, DISABLE IT!

    Heres how:
    [HKEY_CURRENT_USER\ControlPanel\Gestures\Touch]
    "Disabled"=dword:1

    BR,
    B


    BalintN
    • Marked as answer by BalintN Tuesday, April 27, 2010 8:45 PM
    Tuesday, April 27, 2010 8:45 PM

All replies

  • Hi BalintN,

    For the dialog, please try to capture WM_Geture message and block the message, like the code below:
    case WM_GESTURE:
                {

                   //block it here

                }

     

    For more information:
    http://msdn.microsoft.com/en-us/library/ee220936.aspx

    WM6.5 DTK provide the sample about WM_Gesture message.

    C:\Program Files\Windows Mobile 6 SDK\Windows Mobile 6.5 Developer Tool Kit\Samples\PocketPC

    Best regards,
    Guang-Ming Bian - MSFT


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Tuesday, April 20, 2010 9:43 AM
  • Hi Guang,

    Can you tell me how to do that in MFC? I tried

    // Message ID for gestures. It complies with the definition in WM6 SDK gestures.h.
    #define WM_GESTURE 0x0119

     

    ON_MESSAGE(WM_GESTURE, OnGesture)

    LRESULT CSfaForm::OnGesture( WPARAM wParam, LPARAM lParam )
    {
      LRESULT ret = 0;

      return ret;
    }

    But OnGesture is never called.


    BalintN
    Thursday, April 22, 2010 7:24 AM
  • Hi BalintN,

    In MFC, we can also capture the message in call back method:

    LRESULT CShDoneButtonTestDlg::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
    {
     // TODO: Add your specialized code here and/or call the base class


     switch(message)
     {
     case WM_Gesture:
      AfxMessageBox(L"closing",0,0);
     }

     return CDialog::WindowProc(message, wParam, lParam);
    }

    Best regards,
    Guang-Ming Bian - MSFT

     


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Thursday, April 22, 2010 10:40 AM
  • I tried. It did not work.

    Here is the final verdict: TO ____ WITH WINDOW AUTO GESTURES! In File Explorer, it even prevents you from selecting multiple files. In my application it prevents combo boxes from scrolling. It's flawed, its wrong, DISABLE IT!

    Heres how:
    [HKEY_CURRENT_USER\ControlPanel\Gestures\Touch]
    "Disabled"=dword:1

    BR,
    B


    BalintN
    • Marked as answer by BalintN Tuesday, April 27, 2010 8:45 PM
    Tuesday, April 27, 2010 8:45 PM