jQWidgets Forums

jQuery UI Widgets Forums Grid Toggling grid to cardview events

This topic contains 2 replies, has 2 voices, and was last updated by  robf 1 year, 11 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • Toggling grid to cardview events #133385

    robf
    Participant

    Hi,
    I recently followed your example for implementing the cardview and then toggling from Grid view to Card view. Works well.

    I notice when I have a lot of rows (e.g. 1000) it takes some time to re-render the view – at least a few seconds. Whether it’s from grid-to-card or vice-versa. I looked at your demo and appears very fast but I think it has more to do with the various cell rendering that slows mine down.

    So my question is, I’d like to know if there is an event I can trap when the new view starts and ends so I can put up a progress dialog.

    bindingcomplete only fires when the view is initially loaded and not when I change the view. So, is there such an event I can trap?

    Thank you!
    Rob

    Toggling grid to cardview events #133386

    ivanpeevski
    Participant

    Hi Rob,

    The grid “rendered” property will be called twice – at the beginning and at the end of each view refresh.
    Here is an example how to use it: https://jsfiddle.net/rt3ov4nf/3/

    
      rendered: function(call){
      	if(call == 'rows'){
        	console.log('refresh start');
            debugger;
        }
        else if(call == 'full'){
        	console.log('refresh end');
            debugger;
        }
      }

    Best Regards,
    Ivan Peevski
    jQWidgets Support
    http://www.jqwidgets.com

    Toggling grid to cardview events #133390

    robf
    Participant

    Hi Ivan,

    I was actually using “rendered” as an on event and it was not working.

    Your solution worked as expected.

    Thanks very much!

    Rob

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.