[CLOSED] BeforeNodeDrop listener in Treepanel

  1. #1

    [CLOSED] BeforeNodeDrop listener in Treepanel

    Hi,

    How we can use before node drop function in treepanel listener ?.

    Earlier we used the following source,
    
    <ext:ColumnLayout ID="ColumnLayout1" runat="server" FitHeight="true">
        <Columns>
            <ext:LayoutColumn ColumnWidth="0.400">
                <ext:TreePanel ID="treePanelSource" runat="server" RootVisible="false" EnableDD="true"
                    Mode="Local" AllowLeafDrop="true" AutoScroll="true" Header="false">
                    <Listeners>
                        <BeforeNodeDrop Fn="X.beforeDrop" />
                    </Listeners>
                </ext:TreePanel>
            </ext:LayoutColumn>
            <ext:LayoutColumn ColumnWidth="0.200">
                <ext:Panel ID="Panel2" runat="server" Width="40" BodyStyle="background-color: transparent;"
                    Border="false" Layout="AnchorLayout" Height="340">
                    <Items>
                        <ext:Panel ID="Panel3" runat="server" Border="false" BodyStyle="background-color: transparent;"
                            AnchorVertical="39%" AnchorHorizontal="39%" />
                        <ext:Panel ID="Panel4" runat="server" Border="false" BodyStyle="padding:5px;background-color: transparent;"
                            AnchorVertical="61%">
                            <Items>
                                <ext:Button ID="btn_moveright" runat="server" IconCls="move-right" StyleSpec="margin-bottom:2px;"
                                    Width="90">
                                    <Listeners>
                                        <Click Delay="1" Handler="X.add(treePanelSource, treePanelDestination);" />
                                    </Listeners>
                                </ext:Button>
                                <ext:Button ID="btn_moveleft" runat="server" IconCls="move-left" StyleSpec="margin-bottom:2px;"
                                    Width="90">
                                    <Listeners>
                                        <Click Delay="1" Handler="X.remove(treePanelSource, treePanelDestination);" />
                                    </Listeners>
                                </ext:Button>
                            </Items>
                        </ext:Panel>
                    </Items>
                </ext:Panel>
            </ext:LayoutColumn>
            <ext:LayoutColumn ColumnWidth="0.400">
                <ext:TreePanel ID="treePanelDestination" runat="server" RootVisible="false" UseArrows="true"
                    AutoScroll="true" Animate="false" EnableDD="true" Mode="Local" AllowLeafDrop="true"
                    ContainerScroll="true" Header="false">
                    <Listeners>
                        <BeforeNodeDrop Fn="X.beforeDrop" />
                        <Click Delay="1" Handler="if(editFlag) imgEditProp.setDisabled(false);" />
                    </Listeners>
                </ext:TreePanel>
            </ext:LayoutColumn>
        </Columns>
    </ext:ColumnLayout>
    Note: Most of the breaking changes are missed in changes log and breaking changes log. is there any updated document available?
    Last edited by Daniil; Oct 18, 2013 at 4:38 AM. Reason: [CLOSED]
  2. #2
    Hi @speedstepmem4,

    The breaking change #81 is related to the problem.
    81. The TreePanel's drag@drop related properties have been removed: EnableDD, EnableDrag, EnableDrop, AllowLeafDrop, DDAppendOnly, DDGroup, DDScroll, ContainerScroll. Configure a TreeViewDragDrop plugin for a TreePanel's View.
    https://examples2.ext.net/#/TreePanel/Basic/Reorder_Nodes/

    http://docs.sencha.com/ext-js/4-1/#!/api/Ext.tree.plugin.TreeViewDragDrop
    I updated it with a new sentence:
    BeforeDrop and Drop events are available in a TreeView.
    I think you can use the BeforeDrop event instead of the BeforeNodeDrop in v1.

    Quote Originally Posted by speedstepmem4 View Post
    Note: Most of the breaking changes are missed in changes log and breaking changes log. is there any updated document available?
    Yes, unfortunately, many ones have been missed. No other document is available.

    Here are my best thoughts regarding migration.
    http://forums.ext.net/showthread.php...ll=1#post79239
  3. #3
    Quote Originally Posted by Daniil View Post
    Hi @speedstepmem4,

    The breaking change #81 is related to the problem.


    I updated it with a new sentence:


    I think you can use the BeforeDrop event instead of the BeforeNodeDrop in v1.



    Yes, unfortunately, many ones have been missed. No other document is available.

    Here are my best thoughts regarding migration.
    http://forums.ext.net/showthread.php...ll=1#post79239
    Hi Daniil,

    Drop and BeforeDrop event is not available in Treepanel listener.

    How can we use the drop event in TreePanel?
  4. #4
    They are a TreeView's events.
    <ext:TreePanel runat="server">
        <View>
            <ext:TreeView>
                <Listeners>
                    <BeforeDrop Handler="" />
                    <Drop Handler="" />
                </Listeners>
            </ext:TreeView>
        </View>
    </ext:TreePanel>

Similar Threads

  1. [CLOSED] Custom atributes of Treepanel's nodes on Itemclick listener
    By profitsistemas in forum 2.x Legacy Premium Help
    Replies: 2
    Last Post: Jan 23, 2013, 11:12 AM
  2. [CLOSED] TreePanel BeforeNodeDrop Event
    By sailendra in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: Apr 04, 2012, 9:21 AM
  3. Replies: 7
    Last Post: Jun 15, 2011, 7:34 PM
  4. [CLOSED] DropDownfield TreePanel Click Listener
    By amitpareek in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Dec 26, 2009, 2:56 AM
  5. Replies: 1
    Last Post: Feb 23, 2009, 5:24 PM

Tags for this Thread

Posting Permissions