An actual example online would help. Your ascii graphics are a nice try, but
don't really communicate your issue very well.

--Erik


On 5/22/07, chrs <[EMAIL PROTECTED]> wrote:


Hello,

I am new to the jquery library (used prototype before) and this group,
so if I am not posting this question at the rigth list, please tell me
where to post it.

I am building a page where the user has to drag items from a list to
the right boxes. Right now I have a div with two boxes below each
other, and below those four items (see Fig 1.). When the user drags
the item to a box and releases it, it has to stay in the box (aligned
to the box).

Fig 1. init. state                 Fig 2. ghost. false
Fig 3. ghost false

+-----------------------------+      +-----------------------------
+      +-----------------------------+
+-----------------------------+
|  Box 1                     |      |  Box 1
|       |   Box 1                   |       |   Box
1                   |
|                               |       |              Item 1
|       |   Item 1                  |       |                    Item
1  |
+-----------------------------+      +-------------------^---------
+      +-----------------------------+      +----------------------
^------+
+-----------------------------+      +-----------------------------
+      +-----------------------------+
+-----------------------------+
|  Box 2                     |      |  Box 2
|       |   Box 2                   |       |   Box
2                   |
|                               |
|                               |       |
|       |                               |
+-----------------------------+      +-----------------------------
+      +-----------------------------+
+-----------------------------+

  Item 1                               Item
2
Item 1

  Item 2                               Item
3                               Item 2
Item 2

  Item 3                               Item
4                               Item 3
Item 3

  Item
4
Item 4                              Item 4


Now the little problem I have is that if I initialize the draggables
with the option 'ghosting: false' and I start to drag the first item
the position of the others is changed, they move upwards (Fig 2.).
When I release the item in a box, the items move back to their
original position leaving a gap where the dragged item was (Fig 3.).

When ghosting is true, the item is cloned and the other items stay in
line (Fig 4.). But I do not want the item cloned. So I tried setting
the visibility of the item to hidden, did not work (visibility of the
dragged item is set to hidden). Tried to set iDrag.helper to hidden
did not work either.

Has anyone any idea how to solve this? I could set a demo somewhere
online to show what I mean if someone wants that.

Regards, Chris


Reply via email to