ToolStripDropDown shown from autohidden tool window

2 posts, 0 answers
  1. Luc
    Luc avatar
    4 posts
    Member since:
    Jul 2013

    Posted 06 Mar 2014 Link to this post

    Here is a tricky case.

    I am showing a ToolStripDrowDown "from" a ToolWindow. I am aware ToolStripDropDowns are actually forms, not subcontrols, so that showing them from a control is loosely defined from a technical point of view. What I mean is that in reaction to a user action in a control inside the toolwindow, I display the toolstripdropdown next to this control.

    The ToolStripDropDown contains a focusable control.

    Here is the problematic scenario:
    - the tool window is in autohide mode
    - the user selects the toolwindow
    - the user causes the toolstripdropdown to be displayed
    - the user clicks inside the focusable control in the toolstripdropdown
    - logically, the toolwindow loses focus and is hidden.

    I am aware this is a perfectly logical behaviour by RadDock, but I am looking for a workaround. Any idea would be greatly appreciated.

    PS: I am opened to giving up on ToolStripDropDowns. I am using it to provide a kind of light, unintrusive, dialog box, meaning it's not modal and automatically disappears whenever the user clicks somewhere else in the application. It's kind of a kludge, but it's been mostly satisfactory till now.
  2. George
    George avatar
    500 posts

    Posted 11 Mar 2014 Link to this post

    Hello Luc,

    Thank you for contacting us.

    You can use the AutoHideWindowHiding event of RadDock and cancel it, this way the window will not auto-hide:
    this.RadDock.AutoHideWindowHiding += new Telerik.WinControls.UI.Docking.DockWindowCancelEventHandler(RadDock_AutoHideWindowHiding);
    void RadDock_AutoHideWindowHiding(object sender, Telerik.WinControls.UI.Docking.DockWindowCancelEventArgs e)
        e.Cancel = true;

    Let me know if you have further questions.


    DevCraft Q1'14 is here! Watch the online conference to see how this release solves your top-5 .NET challenges. Watch on demand now.

  3. DevCraft R3 2016 release webinar banner
Back to Top