|
View:
New views
10 Messages
—
Rating Filter:
Alert me
|
|
|
Grid Reordererhttp://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer
Could I get a better example of the Grid Reorderer usage? The page above seems to be inconsistent: "jQuery(document).ready(function () { fluid.reorderGrid(".reorderer_container"); }); In this example, two parameters are passed to the fluid.reorderGrid() initialization: * a container selector based on the class of the container (".reorderer_container") * an item selector based on the class of the divs (".orderable")" But there is only ONE parameter passed to fluid.reorderGrid() - Damian _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
Re: Grid ReordererThe "new" Fluid standard is for argument 2 to be an "options structure". Where there
is no 2nd argument, all the component options revert to their defaults - you can consider the 2nd argument is "undefined". A good way to see the configuration space for "Grid Reorderer" shown off is to look at the pages for the "Image Reorderer" http://wiki.fluidproject.org/display/fluid/Image+Reorderer (formely known as "Lightbox"). The Image Reorderer is simply the base reorderer attached to the "GridLayout", with a bit of wrapping for its options. Everything ultimately feeds into the base Reorderer API, at http://wiki.fluidproject.org/display/fluid/Advanced+Reorderer+API the "options" structure is the same structure for every Reorderer variant, the only difference between the different initialisation styles is that some of the options are filled in for you. Cheers, A. Sobieralski, Damian Michael wrote: > > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > Could I get a better example of the Grid Reorderer usage? The page above seems to be inconsistent: > > "jQuery(document).ready(function () { > fluid.reorderGrid(".reorderer_container"); > }); > > In this example, two parameters are passed to the fluid.reorderGrid() initialization: > > * a container selector based on the class of the container (".reorderer_container") > * an item selector based on the class of the divs (".orderable")" > > But there is only ONE parameter passed to fluid.reorderGrid() > > - Damian > > _______________________________________________ > fluid-talk mailing list > fluid-talk@... > http://fluidproject.org/mailman/listinfo/fluid-talk fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
Re: Grid ReordererOn 8-Oct-08, at 2:28 PM, Sobieralski, Damian Michael wrote: > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > In this example, two parameters are passed to the > fluid.reorderGrid() initialization: > > * a container selector based on the class of the container > (".reorderer_container") > * an item selector based on the class of the divs (".orderable")" > > But there is only ONE parameter passed to fluid.reorderGrid() Damian, thanks for catching this!! It seems this page was not properly updated to reflect the new API. I will address this asap, but in the meantime: The first parameter to fluid.reorderGrid() is indeed the container selector. A second parameter is an optional set of configuration parameters, as described on the API page: http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 If you are using the default selector for the 'movable' items (which is a class of "movable"), then you don't need the second parameter. If you'd like to use a different selector, the 'selectors' option parameter can be used to specify it, for example: var mySelectors = { movables: ".my-movable-class" // or whatever selector you need }; var opts = { selectors: mySelectors } fluid.reorderGrid(".reorderer_container", opts); Does this make sense? -- Anastasia Cheetham a.cheetham@... Software Designer, Fluid Project Adaptive Technology Resource Centre / University of Toronto "When we remember we are all mad, the mysteries disappear and life stands explained." -- Mark Twain _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
RE: Grid ReordererYup yup! Concrete examples do a world of good for me. Thanks!
> -----Original Message----- > From: Anastasia Cheetham [mailto:a.cheetham@...] > Sent: Wednesday, October 08, 2008 2:56 PM > To: Sobieralski, Damian Michael > Cc: fluid-talk@... > Subject: Re: Grid Reorderer > > > On 8-Oct-08, at 2:28 PM, Sobieralski, Damian Michael wrote: > > > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > > > In this example, two parameters are passed to the > > fluid.reorderGrid() initialization: > > > > * a container selector based on the class of the container > > (".reorderer_container") > > * an item selector based on the class of the divs (".orderable")" > > > > But there is only ONE parameter passed to fluid.reorderGrid() > > > Damian, thanks for catching this!! It seems this page was not properly > updated to reflect the new API. I will address this asap, but in the > meantime: > > The first parameter to fluid.reorderGrid() is indeed the container > selector. A second parameter is an optional set of configuration > parameters, as described on the API page: > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 > > If you are using the default selector for the 'movable' items (which > is a class of "movable"), then you don't need the second parameter. If > you'd like to use a different selector, the 'selectors' option > parameter can be used to specify it, for example: > > var mySelectors = { > movables: ".my-movable-class" // or whatever > selector you need > }; > var opts = { > selectors: mySelectors > } > fluid.reorderGrid(".reorderer_container", opts); > > Does this make sense? > > > -- > Anastasia Cheetham a.cheetham@... > Software Designer, Fluid Project > Adaptive Technology Resource Centre / University of Toronto > > "When we remember we are all mad, the mysteries > disappear and life stands explained." > -- Mark Twain > _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
RE: Grid ReordererCan you help me understand the listeners better?
I found this: http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 listeners: { onShowKeyboardDropWarning: null, onMove: null, afterMove: null } Could you describe (or point me to a link) of what events these listeners ... uhhh..... listen for? Also, is this list complete? I was hoping to have a listener that fired off of a ...ummm......... "just picked up" event. Thanks. - Damian > -----Original Message----- > From: Anastasia Cheetham [mailto:a.cheetham@...] > Sent: Wednesday, October 08, 2008 2:56 PM > To: Sobieralski, Damian Michael > Cc: fluid-talk@... > Subject: Re: Grid Reorderer > > > On 8-Oct-08, at 2:28 PM, Sobieralski, Damian Michael wrote: > > > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > > > In this example, two parameters are passed to the > > fluid.reorderGrid() initialization: > > > > * a container selector based on the class of the container > > (".reorderer_container") > > * an item selector based on the class of the divs (".orderable")" > > > > But there is only ONE parameter passed to fluid.reorderGrid() > > > Damian, thanks for catching this!! It seems this page was not properly > updated to reflect the new API. I will address this asap, but in the > meantime: > > The first parameter to fluid.reorderGrid() is indeed the container > selector. A second parameter is an optional set of configuration > parameters, as described on the API page: > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 > > If you are using the default selector for the 'movable' items (which > is a class of "movable"), then you don't need the second parameter. If > you'd like to use a different selector, the 'selectors' option > parameter can be used to specify it, for example: > > var mySelectors = { > movables: ".my-movable-class" // or whatever > selector you need > }; > var opts = { > selectors: mySelectors > } > fluid.reorderGrid(".reorderer_container", opts); > > Does this make sense? > > > -- > Anastasia Cheetham a.cheetham@... > Software Designer, Fluid Project > Adaptive Technology Resource Centre / University of Toronto > > "When we remember we are all mad, the mysteries > disappear and life stands explained." > -- Mark Twain > _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
Re: Grid ReordererHi Damian. The complete list of events for a component is declared
in its "defaults" structure - which for the Reorderer consists of events: { onShowKeyboardDropWarning: null, onSelect: null, onBeginMove: "preventable", onMove: null, afterMove: null, onHover: null }, (Reorderer.js line 614). I suspect that the "just picked up" event you are after is either onBeginMove or onMove. What is your event handler going to do? Cheers, A. Sobieralski, Damian Michael wrote: > > Can you help me understand the listeners better? > > I found this: > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 > > listeners: { > onShowKeyboardDropWarning: null, > onMove: null, > afterMove: null > } > > Could you describe (or point me to a link) of what events these listeners ... uhhh..... listen for? > > Also, is this list complete? I was hoping to have a listener that fired off of a ...ummm......... "just picked up" event. > > Thanks. > > - Damian > > > -----Original Message----- > > From: Anastasia Cheetham [mailto:a.cheetham@...] > > Sent: Wednesday, October 08, 2008 2:56 PM > > To: Sobieralski, Damian Michael > > Cc: fluid-talk@... > > Subject: Re: Grid Reorderer > > > > > > On 8-Oct-08, at 2:28 PM, Sobieralski, Damian Michael wrote: > > > > > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > > > > > In this example, two parameters are passed to the > > > fluid.reorderGrid() initialization: > > > > > > * a container selector based on the class of the container > > > (".reorderer_container") > > > * an item selector based on the class of the divs (".orderable")" > > > > > > But there is only ONE parameter passed to fluid.reorderGrid() > > > > > > Damian, thanks for catching this!! It seems this page was not properly > > updated to reflect the new API. I will address this asap, but in the > > meantime: > > > > The first parameter to fluid.reorderGrid() is indeed the container > > selector. A second parameter is an optional set of configuration > > parameters, as described on the API page: > > > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 > > > > If you are using the default selector for the 'movable' items (which > > is a class of "movable"), then you don't need the second parameter. If > > you'd like to use a different selector, the 'selectors' option > > parameter can be used to specify it, for example: > > > > var mySelectors = { > > movables: ".my-movable-class" // or whatever > > selector you need > > }; > > var opts = { > > selectors: mySelectors > > } > > fluid.reorderGrid(".reorderer_container", opts); > > > > Does this make sense? > > > > > > -- > > Anastasia Cheetham a.cheetham@... > > Software Designer, Fluid Project > > Adaptive Technology Resource Centre / University of Toronto > > > > "When we remember we are all mad, the mysteries > > disappear and life stands explained." > > -- Mark Twain > > > > _______________________________________________ > fluid-talk mailing list > fluid-talk@... > http://fluidproject.org/mailman/listinfo/fluid-talk fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
|
|
|
RE: Grid ReordererOnBeginMove did what I wanted. Thanks!
This may be a silly question. But after seeing the list of events I can figure out, based on the name, when the events happen. But when do onShowKeyboardDropWarning and onSelect fire? - Damian > -----Original Message----- > From: Antranig Basman [mailto:antranig@...] > Sent: Thursday, October 09, 2008 1:39 PM > To: Sobieralski, Damian Michael > Cc: fluid-talk@... > Subject: Re: Grid Reorderer > > Hi Damian. The complete list of events for a component is declared > in its "defaults" structure - which for the Reorderer consists of > > events: { > onShowKeyboardDropWarning: null, > onSelect: null, > onBeginMove: "preventable", > onMove: null, > afterMove: null, > onHover: null > }, > > (Reorderer.js line 614). > I suspect that the "just picked up" event you are after is either > onBeginMove or onMove. What is your event handler going to do? > > Cheers, > A. > > Sobieralski, Damian Michael wrote: > > > > Can you help me understand the listeners better? > > > > I found this: > > > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+-+v0.5 > > > > listeners: { > > onShowKeyboardDropWarning: null, > > onMove: null, > > afterMove: null > > } > > > > Could you describe (or point me to a link) of what events these > listeners ... uhhh..... listen for? > > > > Also, is this list complete? I was hoping to have a listener that > fired off of a ...ummm......... "just picked up" event. > > > > Thanks. > > > > - Damian > > > > > -----Original Message----- > > > From: Anastasia Cheetham [mailto:a.cheetham@...] > > > Sent: Wednesday, October 08, 2008 2:56 PM > > > To: Sobieralski, Damian Michael > > > Cc: fluid-talk@... > > > Subject: Re: Grid Reorderer > > > > > > > > > On 8-Oct-08, at 2:28 PM, Sobieralski, Damian Michael wrote: > > > > > > > > http://wiki.fluidproject.org/display/fluid/Integrating+the+Reorderer > > > > > > > > In this example, two parameters are passed to the > > > > fluid.reorderGrid() initialization: > > > > > > > > * a container selector based on the class of the container > > > > (".reorderer_container") > > > > * an item selector based on the class of the divs > (".orderable")" > > > > > > > > But there is only ONE parameter passed to fluid.reorderGrid() > > > > > > > > > Damian, thanks for catching this!! It seems this page was not > properly > > > updated to reflect the new API. I will address this asap, but in > the > > > meantime: > > > > > > The first parameter to fluid.reorderGrid() is indeed the container > > > selector. A second parameter is an optional set of configuration > > > parameters, as described on the API page: > > > > > > http://wiki.fluidproject.org/display/fluid/Grid+Reorderer+API+- > +v0.5 > > > > > > If you are using the default selector for the 'movable' items > (which > > > is a class of "movable"), then you don't need the second parameter. > If > > > you'd like to use a different selector, the 'selectors' option > > > parameter can be used to specify it, for example: > > > > > > var mySelectors = { > > > movables: ".my-movable-class" // or > whatever > > > selector you need > > > }; > > > var opts = { > > > selectors: mySelectors > > > } > > > fluid.reorderGrid(".reorderer_container", opts); > > > > > > Does this make sense? > > > > > > > > > -- > > > Anastasia Cheetham a.cheetham@... > > > Software Designer, Fluid Project > > > Adaptive Technology Resource Centre / University of Toronto > > > > > > "When we remember we are all mad, the mysteries > > > disappear and life stands explained." > > > -- Mark Twain > > > > > > > _______________________________________________ > > fluid-talk mailing list > > fluid-talk@... > > http://fluidproject.org/mailman/listinfo/fluid-talk fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
Re: Grid Reorderer>
> Sobieralski, Damian Michael wrote: >> >> Can you help me understand the listeners better? >> Damian, the listeners are admittedly sorely under-documented. They are a relatively new addition to the Framework, and our documentation has not quite kept up with our code. Creating some explanation of the events, when they occur, and what you'd use them for is high on our list of priorities! -- Anastasia Cheetham a.cheetham@... Software Designer, Fluid Project Adaptive Technology Resource Centre / University of Toronto "People like us, who believe in physics, know that the distinction between past, present, and future is only stubbornly persistent a illusion." -- Albert Einstein _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
|
|
Re: Grid ReordererHey Damian,
On 9-Oct-08, at 1:54 PM, Sobieralski, Damian Michael wrote: > This may be a silly question. But after seeing the list of events I > can figure out, based on the name, when the events happen. But when > do onShowKeyboardDropWarning and onSelect fire? Not a silly question at all. onShowKeyboardDropWarning gets fired by the Layout Reorderer whenever a drop warning appears above invalid targets. So, for example, if you've got a locked portlet where stuff can't be moved in front of it, this event will fire if the user tries to move something to a position that is invalid. onSelect is fired whenever an item is selected with the keyboard, and when it has been grabbed by the mouse. In other words, whenever a reorderable element gets focus. Colin --- Colin Clark Technical Lead, Fluid Project Adaptive Technology Resource Centre, University of Toronto http://fluidproject.org _______________________________________________ fluid-talk mailing list fluid-talk@... http://fluidproject.org/mailman/listinfo/fluid-talk |
| Free embeddable forum powered by Nabble | Forum Help |