Depends on how you do it, but if you always know the height then no,
the rows would just appear.. You could use a ajax indicator to tell
the user that the page are loading.

2010/5/20 Martin Makundi <martin.maku...@koodaripalvelut.com>:
> Would this not flicker a lot?
>
> **
> Martin
>
> 2010/5/20 nino martinez wael <nino.martinez.w...@gmail.com>:
>> ok the idea are this:
>>
>> First render the page with out the grid.
>> Then add the empty grid
>> Then add row 1 to grid
>> Adding row 1 triggers a new request adding row 2 and so on until all
>> rows are loaded..
>>
>> All done with ajax.
>>
>> It's just an idea, but I think it should help. However it causes more
>> load on the server I think.
>>
>> 2010/5/20 Martin Makundi <martin.maku...@koodaripalvelut.com>:
>>> Yes.. what you mean cascade load?
>>>
>>> **
>>> Martin
>>>
>>> 2010/5/20 nino martinez wael <nino.martinez.w...@gmail.com>:
>>>> No havent had the problem myself. But I guess you should start by
>>>> loading the page without the listview enabled, and then add the
>>>> listview afterwards and see if that helps. Next step would be to
>>>> cascade load the rows...
>>>>
>>>> 2010/5/19 Martin Makundi <martin.maku...@koodaripalvelut.com>:
>>>>> Hmm.. can you show me an example of something like that, how is it done?
>>>>>
>>>>> **
>>>>> Martin
>>>>>
>>>>> 2010/5/19 nino martinez wael <nino.martinez.w...@gmail.com>:
>>>>>> about the lazyloading, I was thinking to cascade load the rows after
>>>>>> page render, it should perform better in theory:)...
>>>>>>
>>>>>> 2010/5/19 Martin Makundi <martin.maku...@koodaripalvelut.com>:
>>>>>>> Hi!
>>>>>>>
>>>>>>>> hmm could'nt just use a custom ajax decorator? Or override the js part
>>>>>>>> of the onchangeajaxbehaviour?
>>>>>>>
>>>>>>> Hmm.. sounds like a good starting point...  thanks.
>>>>>>>
>>>>>>> BTW: I totally lost you on that lazy loading thing... the user would
>>>>>>> like the page to load in a snap and using it to be like a snap. How
>>>>>>> would your proposed lazy loading be implemented?
>>>>>>>
>>>>>>> **
>>>>>>> Martin
>>>>>>>>
>>>>>>>> 2010/5/19 Jeremy Thomerson <jer...@wickettraining.com>:
>>>>>>>>> Well, if the rendering of all that extra JS is what's causing the 
>>>>>>>>> problem,
>>>>>>>>> I'd try to limit it to one rendering of the (slightly-modified) 
>>>>>>>>> behavior.
>>>>>>>>>
>>>>>>>>> You can basically render something like this:
>>>>>>>>>
>>>>>>>>> function somethingInMyTableChanged(rowInd) {
>>>>>>>>>  return wicketAjaxGet('{standardBehaviorUrl}&rowIndex=' + rowInd);
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> Then, you add a simple behavior to your row items like:
>>>>>>>>>
>>>>>>>>> new SimpleAttributeModifier("onchange", true, new 
>>>>>>>>> Model<String>("return
>>>>>>>>> somethingInMyTableChanged(" + item.getRowIndex() + ");");
>>>>>>>>>
>>>>>>>>> In your behavior, now you have to do a little extra work (don't use an
>>>>>>>>> onchangeajaxbehavior, just use a custom defaultajaxbehavior or 
>>>>>>>>> something
>>>>>>>>> like that).  You'll need to call
>>>>>>>>> RequestCycle.get().getRequest().getServletRequest().getQueryParameters().get("rowIndex")
>>>>>>>>> and use that to see which row changed.
>>>>>>>>>
>>>>>>>>> Anyway, it should work, but it's a little less "clean" than you 
>>>>>>>>> normally
>>>>>>>>> would do in Wicket.  BUT - if you have proven that it's the rendering 
>>>>>>>>> of all
>>>>>>>>> that extra AJAX string stuff that's slowing you down, then it's worth 
>>>>>>>>> doing.
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Jeremy Thomerson
>>>>>>>>> http://www.wickettraining.com
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, May 19, 2010 at 11:09 AM, Martin Makundi <
>>>>>>>>> martin.maku...@koodaripalvelut.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi!
>>>>>>>>>>
>>>>>>>>>> Yes.. my question now is: how to easily extract the JS? It is from
>>>>>>>>>> onchangeajaxbehavior etc.
>>>>>>>>>>
>>>>>>>>>> I would like to continue using wicket standard onchangeajaxbehavior
>>>>>>>>>> but somehow override the way it injects the js into the component 
>>>>>>>>>> tag.
>>>>>>>>>> Suggestions to accomplish this?
>>>>>>>>>>
>>>>>>>>>> **
>>>>>>>>>> Martin
>>>>>>>>>>
>>>>>>>>>> 2010/5/19 Jeremy Thomerson <jer...@wickettraining.com>:
>>>>>>>>>> > If you've already proven that removing the AJAX removes the 
>>>>>>>>>> > contention,
>>>>>>>>>> I'd
>>>>>>>>>> > go with Nino's "otherwise" route.  That was my first guess.  
>>>>>>>>>> > Depending on
>>>>>>>>>> > what you're doing with those AJAX calls, you could probably make 
>>>>>>>>>> > it so
>>>>>>>>>> that
>>>>>>>>>> > you have one to three of them for the entire table, wrapped in a 
>>>>>>>>>> > custom
>>>>>>>>>> > function.  (You don't have to extract them to a separate JS).  
>>>>>>>>>> > Then each
>>>>>>>>>> row
>>>>>>>>>> > would shorten it's JavaScript output to 
>>>>>>>>>> > myCustomFunction(rowIndex).  If
>>>>>>>>>> you
>>>>>>>>>> > need some help, let us know.  I posted a message on this list a 
>>>>>>>>>> > week or
>>>>>>>>>> so
>>>>>>>>>> > ago showing how to wrap existing AJAX in a custom function.  That 
>>>>>>>>>> > might
>>>>>>>>>> > help, too.
>>>>>>>>>> >
>>>>>>>>>> > --
>>>>>>>>>> > Jeremy Thomerson
>>>>>>>>>> > http://www.wickettraining.com
>>>>>>>>>> >
>>>>>>>>>> >
>>>>>>>>>> >
>>>>>>>>>> > On Wed, May 19, 2010 at 10:51 AM, nino martinez wael <
>>>>>>>>>> > nino.martinez.w...@gmail.com> wrote:
>>>>>>>>>> >
>>>>>>>>>> >> The easiest thing would probably to lazy load the rows somehow, 
>>>>>>>>>> >> how
>>>>>>>>>> >> are load time pr row?.. Otherwise you could extract the long 
>>>>>>>>>> >> inline
>>>>>>>>>> >> code into a seperate js and wrap them into induvidual methods,
>>>>>>>>>> >> although I do not know if it makes page load faster or there 
>>>>>>>>>> >> could be
>>>>>>>>>> >> other issues.
>>>>>>>>>> >>
>>>>>>>>>> >> 2010/5/19 Martin Makundi <martin.maku...@koodaripalvelut.com>:
>>>>>>>>>> >> > Hi!
>>>>>>>>>> >> >
>>>>>>>>>> >> > HELP!
>>>>>>>>>> >> >
>>>>>>>>>> >> > I have a problem. I have a table with 20 columns and 30 rows
>>>>>>>>>> >> ("calendar").
>>>>>>>>>> >> >
>>>>>>>>>> >> > The problem is that it renders very slowly in browsers.
>>>>>>>>>> >> >
>>>>>>>>>> >> > The reason is not directly network speed but it is the VERY 
>>>>>>>>>> >> > heavy
>>>>>>>>>> >> > markup. Each table cell has 3 ajax components and the ajax call
>>>>>>>>>> >> > functions are loooooooooong.
>>>>>>>>>> >> >
>>>>>>>>>> >> > I have tested to strip away all ajax calls and it renders 
>>>>>>>>>> >> > pretty OK.
>>>>>>>>>> >> > Now what I am thinking is that is there a way to shorten the 
>>>>>>>>>> >> > wicket
>>>>>>>>>> >> > ajax call urls?
>>>>>>>>>> >> >
>>>>>>>>>> >> > Any practical suggestions? I tried also shortening the 
>>>>>>>>>> >> > wicket-id names
>>>>>>>>>> >> > but there still remains quite some blob of excess markup that 
>>>>>>>>>> >> > could
>>>>>>>>>> >> > brobably be in some reusable function??
>>>>>>>>>> >> >
>>>>>>>>>> >> > Here is a sample markup of just one single cell and you can 
>>>>>>>>>> >> > immagine
>>>>>>>>>> >> > how big of a blob it is when having 20x30 cells (copy-pasted 
>>>>>>>>>> >> > from
>>>>>>>>>> >> > firebug):
>>>>>>>>>> >> >
>>>>>>>>>> >> > <td class="order_confirmed" id="id84be1"><span style="position:
>>>>>>>>>> >> > relative; float: left;"><select onchange="var 
>>>>>>>>>> >> > wcall=wicketAjaxPost('',
>>>>>>>>>> >> > wicketSerialize(Wicket.$('memo-8-3')),function() {
>>>>>>>>>> >> > }.bind(this),function() { }.bind(this), function() {return
>>>>>>>>>> >> > Wicket.$('memo-8-3') != null;}.bind(this));" id="memo-8-3"
>>>>>>>>>> >> > name="p:f:ss:s:t:w:3:m:8:o" style="position: absolute; display: 
>>>>>>>>>> >> > none;
>>>>>>>>>> >> > z-index: 2;" class="show-hide">
>>>>>>>>>> >> > <option value=""></option>
>>>>>>>>>> >> > <option value="99255" selected="selected">Option</option>
>>>>>>>>>> >> > <option value="200345">Another option</option>
>>>>>>>>>> >> > </select></span>
>>>>>>>>>> >> >              <div id="c4be2">
>>>>>>>>>> >> >      <input type="text" onchange="if (!wicketAjaxBusy()) {
>>>>>>>>>> >> > overrideShow = true;var wcall=wicketAjaxPost('',
>>>>>>>>>> >> > wicketSerialize(Wicket.$('s4714')),function() { overrideShow =
>>>>>>>>>> >> > false;}.bind(this),function() { overrideShow = 
>>>>>>>>>> >> > false;}.bind(this),
>>>>>>>>>> >> > function() {return Wicket.$('s4714') != null;}.bind(this));}"
>>>>>>>>>> >> > tabindex="008003" maxlength="1024" id="s4714"
>>>>>>>>>> >> > name="p:f:ss:s:t:w:3:m:8:c:s" value="10-18" style="border: 1px 
>>>>>>>>>> >> > solid
>>>>>>>>>> >> > rgb(0, 255, 0);"><select onchange="var wcall=wicketAjaxPost('',
>>>>>>>>>> >> > wicketSerialize(Wicket.$('r4715')),function() {
>>>>>>>>>> >> > }.bind(this),function() { }.bind(this), function() {return
>>>>>>>>>> >> > Wicket.$('r4715') != null;}.bind(this));" id="r4715"
>>>>>>>>>> >> > name="p:f:ss:s:t:w:3:m:8:c:r" style="position: absolute; 
>>>>>>>>>> >> > display:
>>>>>>>>>> >> > none;" class="colors show-hide" size="1">
>>>>>>>>>> >> > <option value="">new stuff</option>
>>>>>>>>>> >> > <option value="B">Option</option>
>>>>>>>>>> >> > </select><script
>>>>>>>>>> >> > type="text/javascript">&lt;!--/*--&gt;&lt;![CDATA[/*&gt;&lt;!--*/
>>>>>>>>>> >> > initializeShowHide('s4714','#r4715');
>>>>>>>>>> >> > /*--&gt;]]&gt;*/</script>
>>>>>>>>>> >> >
>>>>>>>>>> >> > <div class="right-side"><a id="i4716" href="#">Info</a><script
>>>>>>>>>> >> > type="text/javascript">&lt;!--/*--&gt;&lt;![CDATA[/*&gt;&lt;!--*/
>>>>>>>>>> >> > initializeShowHide('i4716','#memo-8-3', true);
>>>>>>>>>> >> > /*--&gt;]]&gt;*/</script>
>>>>>>>>>> >> >
>>>>>>>>>> >> > </div><a onclick="var wcall=wicketSubmitFormById('f4b6d', '',
>>>>>>>>>> >> > 'p:f:ss:s:t:w:3:m:8:c:c' ,function() { }.bind(this),function() {
>>>>>>>>>> >> > }.bind(this), function() {return
>>>>>>>>>> >> > Wicket.$$(this)&amp;&amp;Wicket.$$('f4b6d')}.bind(this));;; 
>>>>>>>>>> >> > return
>>>>>>>>>> >> > false;" id="c4be3" name="p:f:ss:s:t:w:3:m:8:c:c" style="margin: 
>>>>>>>>>> >> > 0pt
>>>>>>>>>> >> > 1px;"><img border="0" title="Tyhjennä" alt="x"
>>>>>>>>>> >> > src="/images/redcross.png"></a>
>>>>>>>>>> >> >    </div></td>
>>>>>>>>>> >> >
>>>>>>>>>> >> >
>>>>>>>>>> >> > **
>>>>>>>>>> >> > Martin
>>>>>>>>>> >> >
>>>>>>>>>> >> > ---------------------------------------------------------------------
>>>>>>>>>> >> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>>>>>> >> > For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>>>>> >> >
>>>>>>>>>> >> >
>>>>>>>>>> >>
>>>>>>>>>> >> ---------------------------------------------------------------------
>>>>>>>>>> >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>>>>>> >> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>>>>> >>
>>>>>>>>>> >>
>>>>>>>>>> >
>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>>
>>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>>
>>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to