RadDock Collapsed

2 posts, 0 answers
  1. shimon
    shimon avatar
    37 posts
    Member since:
    Apr 2007

    Posted 02 May 2007 Link to this post

    Hello,

    I have 3 dockzones in first one I have couple of raddocks witch are collapsed, I need them to expend when I drop them on one of the other 2 zones.

    I set the collapsed property to false when it changed position but nothing is happening and it still stays collapsed.

    Can you please tell me how to do it?

    Thank you,

    Shimon

  2. Petio Petkov
    Admin
    Petio Petkov avatar
    825 posts

    Posted 03 May 2007 Link to this post

    Hi shimon,

    Unfortunately, there is bug in the current RadDock version in set_Collapsed function,  which will be fixed in the next update.

    The following example illustrates a simple workaround for it:
    <html xmlns="http://www.w3.org/1999/xhtml">  
    <head id="Head1" runat="server">  
        <title>Untitled Page</title> 
        <script type="text/javascript">  
            function OnClientDockPositionChanged(obj,args)  
            {  
               var dockZoneID = obj.get_DockZoneID();      
               if(dockZoneID == "RadDockZone2")  
               {  
                if(obj.get_Collapsed())  
                {  
                    obj.set_Collapsed(true);               
                }              
               }  
               else  
               {  
                   if(obj.get_Collapsed())  
                    {  
                        obj.set_Collapsed(false);               
                    }   
               }  
            }  
        </script> 
    </head> 
    <body> 
        <form id="form1" runat="server">  
            <asp:ScriptManager ID="ScriptManager1" runat="server">  
            </asp:ScriptManager> 
            <div>              
                    <telerik:RadDockLayout ID="RadDockLayout1" runat="server">  
                        <telerik:RadDockZone ID="RadDockZone1" runat="server" MinHeight="10px" MinWidth="20px">  
                                <telerik:RadDock ID="RadDock1" runat="server" Text="RadDock1"   
                                Title="RadDock1" OnClientDockPositionChanged="OnClientDockPositionChanged">                                                              
                                </telerik:RadDock>       
                                 <telerik:RadDock ID="RadDock2" runat="server" Text="RadDock2" 
                                Title="RadDock2" OnClientDockPositionChanged="OnClientDockPositionChanged">                                                               
                                </telerik:RadDock>         
                        </telerik:RadDockZone>                
                        <telerik:RadDockZone ID="RadDockZone2" runat="server" MinHeight="10px" MinWidth="20px">  
                                       
                        </telerik:RadDockZone> 
                    </telerik:RadDockLayout> 
                 
                  
                 
                  
            </div> 
        </form> 
    </body> 
    </html> 

    I hope it will help you to resolve your issue.


    Greetings,
    Petio Petkov
    the telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top