Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Property Grid
  New Posts New Posts RSS Feed - Handling Keyboard input....
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Handling Keyboard input....

 Post Reply Post Reply
Author
Message Reverse Sort Order
Kevin6 View Drop Down
Groupie
Groupie


Joined: 13 May 2005
Location: United Kingdom
Status: Offline
Points: 30
Post Options Post Options   Thanks (0) Thanks(0)   Quote Kevin6 Quote  Post ReplyReply Direct Link To This Post Topic: Handling Keyboard input....
    Posted: 19 September 2005 at 10:22am

Well....as this forum was SO budding with ideas - I thought I would post back the result.

Subclassing the control didn't work as my code for expanding and collapsing the grid contents were held at the pane level.

The easiest solution was to track all keyboard presses that were handled by the Pane and then instruct the grid to Expand or Contract.

Using PreTranslate Message seems really robust... WM_CHAR was useless - OnCharToItem sort of worked (Expanded the grid but then when it lost focus you couldn't Collapse it)....

Rich

Kevin.
Back to Top
Kevin6 View Drop Down
Groupie
Groupie


Joined: 13 May 2005
Location: United Kingdom
Status: Offline
Points: 30
Post Options Post Options   Thanks (0) Thanks(0)   Quote Kevin6 Quote  Post ReplyReply Direct Link To This Post Posted: 19 September 2005 at 4:39am

Dear All,

I want to be able to have my control expand and collapse its contents on the key press by the user. Cntrl A and Cntrl D.

This is working fine if the CXTPPropertyGridView is collapsed as the top level window is getting the messages.

Once the contents of the CXTPPropertyGridView control are expanded it no longer gets the messages co-herently. It seems that all keyboard events are not directed to the CXTPPropertyGridView.

Other than subclassing - can anyone suggest a reasonable solution for catching keyboard events?

(Specifically - can I re-wire keyboard events to the parent class?)

regards

Richard.

 

Kevin.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.094 seconds.