RadImageEditor dialogs conflict with RadDocks on the page

3 posts, 1 answers
  1. Ravin
    Ravin avatar
    8 posts
    Member since:
    Dec 2012

    Posted 26 Dec 2012 Link to this post

    I have a RadImageEditor and a RadDockLayout populated with RadDockZone and RadDocks on the same page. RadImageEditor and RadDockLayout reside in two different update panels. RadDocks are used to display a list of draggable images, and the RadImageEditor is used to edit a selected image.

    My problem is while editing an image, if I open an image editor dialog (ex. Image Crop dialog) and drag it around, the dialog snaps into RadDock positions on the image list. I noticed that internal RadImageEditor dialogs are also RadDocks, but shouldn't they be independent from other RadDock controls that exist on the page? How can I make it so that RadImageEditor dialogs won't interfere with other RadDocks on the page?
  2. Answer
    Vessy
    Admin
    Vessy avatar
    2416 posts

    Posted 27 Dec 2012 Link to this post

    Hi Ravin,

    As you have assumed the ImageEditor's dialogs are dock objects and in order to avoid the described behavior you will need to change there dock mode to "floating".

    For example, you could do it in the handler of the ImageEditor's OnClientDialogLoaded event:
    <telerik:RadImageEditor ID="RadImageEditor1" runat="server" OnClientDialogLoaded="OnClientDialogLoaded"
        ImageUrl="~/Images/flowers.jpg">
    </telerik:RadImageEditor>
    <script type="text/javascript">
        function OnClientDialogLoaded(imageEditor, args) {
            $find("<%=RadImageEditor1.ClientID%>" + "_ToolsPanel").set_dockMode(1);
        }
    </script>

    Regards,
    Vesi
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. Ravin
    Ravin avatar
    8 posts
    Member since:
    Dec 2012

    Posted 27 Dec 2012 Link to this post

    Thanks Vesi. This works great!
Back to Top