OnNodeEdit triggers OnNodeClick

4 posts, 0 answers
  1. John
    John avatar
    4 posts
    Member since:
    May 2008

    Posted 09 Oct 2008 Link to this post

    Hello all,

    On my tree I have the OnNodeEdit and OnNodeClick events but every second time I double click on a node the OnNodeClick event fires, anyone else expereince this?

    Thanks
  2. Veselin Vasilev
    Admin
    Veselin Vasilev avatar
    2992 posts

    Posted 10 Oct 2008 Link to this post

    Hello John,

    Indeed, this is the expected behavior. If you click once on a node - the NodeClick event is fired.
    You can click on F2 button to edit the node as well.

    All the best,
    Veselin Vasilev
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. John
    John avatar
    4 posts
    Member since:
    May 2008

    Posted 10 Oct 2008 Link to this post

    Hello and thanks for the reply.  Shouldn't double clicking only fire the edit trigger and not the single click trigger?
  4. Veselin Vasilev
    Admin
    Veselin Vasilev avatar
    2992 posts

    Posted 10 Oct 2008 Link to this post

    Hello John,

    The browser throws first the click and then the doubleclick events. That is why when the treeview receives the click event and you have subscribed to the NodeClick event - a postback occurs.

    The treeview cannot know that a doubleclick event is coming after the click event.

    Best wishes,
    Veselin Vasilev
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top