This is a migrated thread and some comments may be shown as answers.

Filter / Group Delay Animation

6 Answers 75 Views
JumpList
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
ManniAT
Top achievements
Rank 2
ManniAT asked on 03 May 2012, 12:33 PM
Hi,

I build an application where the user can change filtering / grouping.
It works very well, but when the user changes filter / group it takes some time (from half a second to about 3 seconds) till the UI is responsible again.
What I want to achieve is a kind of Hourglass reflecting that something lengthy is going on in the background.
I think about you BusyIndicator - but my problems are:
1.) I found no event for "filtering / grouping done"
2.) I'm not sure if changing the filter- / GroupDescriptors will freeze the UI
3.) I guess changing those descriptors must be done on the UI thread

So my questions - is something like this possible - or do you have any idea how this could be done.

Regards
Manfred

6 Answers, 1 is accepted

Sort by
0
Accepted
Deyan
Telerik team
answered on 07 May 2012, 07:49 AM
Hi Manfred,

The data operations are done synchronously on the UI thread. Therefore, when you reset the data descriptors for your RadJumpList, you can be sure that they have completed after the code you are using to reset them. So, in this case, you can use the Busy Indicator in the following way:

this.radBusyIndicator.IsRunning = true;
this.Dispatcher.BeginInvoke(() =>
    {
        GenericGroupDescriptor<int, char> gd = new GenericGroupDescriptor<int, char>();
        gd.KeySelector = p => p.ToString()[p.ToString().Length - 1];
        this.radJumpList.BeginDataUpdate();
        this.radJumpList.GroupDescriptors.Clear();
        this.radJumpList.GroupDescriptors.Add(gd);
        this.radJumpList.EndDataUpdate();
        this.radBusyIndicator.IsRunning = false;
    });

As you can see, before calling the code that resets my group descriptors, I start the Busy Indicator. After that, in a Dispatcher, I am resetting the group descriptors and stop the busy indicator at the end.

This works as expected on my side.

I hope this helps.

Greetings,
Deyan
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
ManniAT
Top achievements
Rank 2
answered on 07 May 2012, 07:55 AM
Hi Deyan,

such a simple approach - I love this (should have found it myself) :)

Event though my solution is a bit more complex (My group / filter descriptors are bound to the view model)
it helps me to solve my problem.

Thanks a lot for the answer
Manfred
0
Vitalii
Top achievements
Rank 2
answered on 11 Oct 2013, 07:49 PM
Hi,

is there a possibility to dynamically change grouping from viewmodel? Or should i just move this to codebehind?
0
Deyan
Telerik team
answered on 14 Oct 2013, 12:36 PM
Hi Vitalii,

Thanks for writing.

Yes, it is possible to dynamically change the GroupDescriptors by binding them to an observable collection exposed by your ViewModel. You can read more about this here:

http://www.telerik.com/help/windows-phone/radjumplist-features-group-descriptors.html

Regards,
Deyan
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINDOWS PHONE 7.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Vitalii
Top achievements
Rank 2
answered on 14 Oct 2013, 02:07 PM
Thanks, guys, your support is awesome!

PS: in the sample, it is a List, not Observable. But i got the idea about GroupDescriptorsSource  :)
0
Deyan
Telerik team
answered on 15 Oct 2013, 07:36 AM
Hi Vitalii,

Thanks for getting back to us.

We will make sure to update the examples accordingly.

We will consider this thread closed for now.

Let us know should you have further questions or need assistance.

Regards,
Deyan
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINDOWS PHONE 7.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
JumpList
Asked by
ManniAT
Top achievements
Rank 2
Answers by
Deyan
Telerik team
ManniAT
Top achievements
Rank 2
Vitalii
Top achievements
Rank 2
Share this question
or