Results 1 to 2 of 2

Thread: How to dynamically remove draggable element in the Drag and Drop exampldrop listener?

  1. #1
    Sencha User
    Join Date
    Jan 2012
    Posts
    3
    Vote Rating
    0
      0  

    Default Unanswered: How to dynamically remove draggable element in the Drag and Drop exampldrop listener?

    I've been experimenting with Sencha Touch's Drag and Drop functionality (http://dev.sencha.com/deploy/touch/examples/dragdrop/), and although I've searched both official documentations and online sources, it isn't clear how a dropped draggable element can be dynamically removed from the screen (and from the memory):
    listeners: { drop: function(droppable, draggable, e) { // how to remove 'draggable' that was just dropped? // this.remove(draggable, true); <-- doesn't work }}
    Does anyone have any ideas?

  2. #2
    Sencha User
    Join Date
    Jan 2012
    Posts
    3
    Vote Rating
    0
      0  

    Default

    Ah, I think the answer is:


    Ext.destroy(draggable);


    Can anyone confirm if this is the "best" way to do so?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •