jQuery UI Widgets Forums Layouts Docking Spawning dockable windows outside of dock

This topic contains 6 replies, has 3 voices, and was last updated by  christian.folie@oebb.at 6 years, 11 months ago.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author

  • bentwonk
    Participant

    I am interested in using the docking features (as in the demo jquery-docking-settings.htm), but would like to initially spawn the window outside of the docking area, and have it dock when the user drags it into the docking area (imagine the user sorting random windows into different docking panels), using chrome.

    I can spawn outside if I set the windows mode to floating, but then it will not dock.
    I tried spawning the window as default, and then moving it, but it did not move.
    I have tried to change the widows mode from floating to default upon detecting the drag event, but this didn’t work (I don’t think floating detect the drag start event), and I suspect my jquery may not be right, $(this).find(‘#docking’).jqxDocking(‘setWindowMode’, this,’default’);

    Can you please tell me what I am doing wrong, and give me an example where docking can be used for windows spawned outside the docking area.


    Dimitar
    Participant

    Hello bentwonk,

    You are correct – the dragStart event does not fire for windows in “floating” mode and you cannot use the setWindowPosition method (to spawn a window outside the docking area) on a window that is not “floating”. Unfortunately, your requirement cannot be achieved. We will consider improving this functionality in the future.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

    Hey,

    We have the same requirement for our product:
    Open a window outside of the dock but be able to dock it afterwards.

    Bentwonk said

    I tried spawning the window as default, and then moving it, but it did not move.

    We made a jsFiddle where we managed to spawn and then move the window, however it appears to stay in the “drag-mode”.
    After manually moving it, everything behaves as expected.
    Can we fix this behaviour or is there another way to do this by now?

    Best Regards,
    Christian


    Dimitar
    Participant

    Hello Christian,

    We experience no issues after clicking the openFloating button. But do not expect the div with id window3 to appear as a window before that because it is outside the docking.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

    Hello Dimitar,

    We do not expect the div to appear as window before clicking openFloating.
    Our issue is the oppacity of the window after spawning and moving it. It looks just like it should when you drag the window, but the DragEnd seems to be missing, so the opacity stays.

    The events are not needed, but we would like to open dockable windows outside of the docking area.

    Best Regards


    Dimitar
    Participant

    Hi Christian,

    Calling a jqxWindow method on a window in a docking is actually not supported so there might be some unexpected behaviour. There is a jqxDocking move method, but, as stated in previous posts, it cannot be called on docked windows.

    As a workaround, you may change the window’s opacity manually, i.e.:

    $('#openFloating').on('click', function () {
        $('#jqxDocking').jqxDocking('addWindow', 'window3', 'docked');
        $('#window3').jqxWindow('move', 100, 230);
        $("#window3").css("opacity", 1);
    });

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

    Thanks a lot, this fixes our problem!

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.