Jan 24

Yep, another problem with the future bits! If you try to use this class from xml-script, you”ll get an error that says something like this:

Error: Sys.ArgumentTypeException: Use isDomElement with a null type for element properties
e.g., for descriptor use { name: ”foo, isDomElement: true, type: null }

Now, you can”t get a more explicit error message than this one. So the real question is why the future bits have the following descriptor for DraggableListItem

Sys.Preview.UI.DraggableListItem.descriptor = {
  properties: [ {name: ”data”, type: Object},
                     {name: ”handle”, type: Sys.UI.DomElement},
                     {name: ”dragVisualTemplate”, type: Sys.Preview.UI.ITemplate} ]

Replacing the bold line with this makes everythign work again:

{name: ”handle”,type: null,isDomElement: true},

Oh, and since you”re at the previewdragdrop.js file, you should also make the following changes:

  • the descriptor for the handle property of the floatingBehavior is wrong (you need to make the some changes as the one you”ve made to the DraggableListItem”s handle property)
  • the checkCanDrag method has a bug where it tests the undraggableTagNames variable. You should change the line undraggableTagNames.indexOf( tagName.toLowerCase() ) to Array.indexOf( undraggableTagNames, tagName.toLowerCase() )

I”m starting to get upset! Can anyone please tell me why you”ve decided to start breaking the future bits? I know that they aren”t supported but if you”re going to break it in purpose, then it would probably be better to just remove them! don”t you runt tests? for the love of god…I”ve just sepnt a morning running some simple tests and fixing you code! this really shouldn”t be happening, should it?

2 comments so far

  1. Paul.Vencill
    11:49 am - 2-22-2007


    Have you managed to get the draggableListItem behavior to work w/o using xml-script? If so, do you have a code sample? I”ve been beating my head against it for a while now, and it”s getting more than frustrating. THe problem seems to be that I can”t figure out how to create the templates correctly.

    Thanks in advance!
    paul (from forums)

  2. nvhhnvq
    12:31 am - 10-31-2009

    P614oq cjdvajwpyfgj, [url=]gjfmtbliflvu[/url], [link=]pxijusjjygjb[/link],