Treeview Hittest Info

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • =?Utf-8?B?cG1jZ3VpcmU=?=

    #1

    Treeview Hittest Info

    I'm trying to use the Hittest to determine where on a node my mouse is. Only
    I want to know stuff for which there isn't a flag -- eg "Is the hit in the
    upper part, the center, or the bottom part of the treenode?"

    How do I do this? Must I somehow override TVM_HITTEST? Is there an easy
    way to get a treenode's location and then figure out where my hit happened on
    my own?

    Help. Thanks
    --
    Pat
  • =?Utf-8?B?cG1jZ3VpcmU=?=

    #2
    RE: Treeview Hittest Info

    Well, I'm not sure if this is the BEST way, but, duhhh, the treenode class
    exposes the .Bounds property, so comparing the mouse pt.y to the .Bounds.Top
    gives the location within the treenode of the mouse .....
    --
    Pat


    "pmcguire" wrote:
    I'm trying to use the Hittest to determine where on a node my mouse is. Only
    I want to know stuff for which there isn't a flag -- eg "Is the hit in the
    upper part, the center, or the bottom part of the treenode?"
    >
    How do I do this? Must I somehow override TVM_HITTEST? Is there an easy
    way to get a treenode's location and then figure out where my hit happened on
    my own?
    >
    Help. Thanks
    --
    Pat

    Comment

    Working...