Loading ...
Sorry, an error occurred while loading the content.
 

Re: Occurence of drag elements hiding behind the target element

Expand Messages
  • pris_tcp
    Hi Dav, Thank you for replying promptly. Really appreciate your attention in this matter. Checking out your example, upon dragging two elements to the same
    Message 1 of 3 , Nov 2, 2006
      Hi Dav,

      Thank you for replying promptly. Really appreciate your attention in
      this matter.

      Checking out your example, upon dragging two elements to the same slot
      on the top, the last element dragged will hide behind the first element.
      However this is not my objective.

      My objective is to swap the images. For example, assume if there is an
      element "Pink" in the target slot "SlotA". Another element "Yellow" was
      in "SlotB". If I dragged the element "Yellow" to "SlotA", then "Pink"
      should be remove from "SlotA" and be place in "SlotB". "Yellow" will now
      occupied "SlotA".

      In short, once "Yellow" is dragged to "SlotA" where "Pink" is, then
      "Yellow" and "Pink" should swap position. In my examples, most of the
      time, the swapping was done correctly. However there are times where it
      does not swap position, rather it hides behind the target element.

      I have attached my script in the url stated below. You will see the
      issue if you move the pink element to the purple element in the bottom
      slot. I noticed that after dragging and dropping a few elements, the
      issues does not occur anymore.


      http://vocanic.dnsalias.net/~cptan/test/examples/yui-test/targetable.htm\
      l

      Thanks!


      Regards,
      Pris


      --- In ydn-javascript@yahoogroups.com, Dav Glass <dav.glass@...> wrote:
      >
      > Pris --
      >
      > Here's an example of how you could do it 8-)
      >
      > http://blog.davglass.com/files/yui/dd6/
      >
      > Hope that helps...
      >
      > Dav Glass
      > dav.glass@...
      > davglass.com
      > 618.694.3476
      >
      > + Windows: n. - The most successful computer virus, ever. +
      > + A computer without a Microsoft operating system is like a dog
      > without bricks tied to its head +
      > + A Microsoft Certified Systems Engineer is to computing what a
      > McDonalds Certified Food Specialist is to fine cuisine +
      >
      > ----- Original Message ----
      > From: pris_tcp cptan@...
      > To: ydn-javascript@yahoogroups.com
      > Sent: Thursday, November 2, 2006 7:47:27 PM
      > Subject: [ydn-javascript] Occurence of drag elements hiding behind the
      target element
      >
      > Hi,
      >
      > I am trying to create application that has two group of slots, one
      group
      > is for unselected elements and the other is for selected elements.
      > Initially, the elements are shown in the unselected slots and there
      are
      > two textfields to keep track of the order in which the elements are
      > displayed (from left to right).
      >
      > I suppose that when I drag an element to a slot that contains another
      > element, the element in the target slot should move to the slot in
      which
      > the drag element was previously. In short, the target and the drag
      > element should swap. However I encountered the problem whereby the
      > target element does not swapped with the drag element, this only
      occurs
      > occasionally.
      >
      > I have attached my script in the url stated below. You will see the
      > issue if you move the pink element to the purple element in the bottom
      > slot.
      >
      >
      http://vocanic.dnsalias.net/~cptan/test/examples/yui-test/targetable.htm\
      \
      > l
      >
      > Can anyone advice me on how I should approach this issues?
      > Is it scripting problems on my side or Yahoo bugs?
      > Does anyone encountered this issues before?
      >
      > Thank you for the attention in this matter. I will appreciate the help
      > given.
      >
      >
      > Regards,
      > Pris
      >
      >
      >
      >
      >
      >
      >
      >
      > Yahoo! Groups Links
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.