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

Resource dictionary caching option?

3 Answers 163 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Andrew
Top achievements
Rank 1
Andrew asked on 02 Apr 2013, 05:54 PM
Guys - I've run a profile on an app where we're only using your GridView, and are completely overriding your styles (based on your metro themes, bringing it back even more) and have noticed thousands of ResourceDictionaries instantiated which identify as internal to your DLLs - are you using hard-coded references, and do you have some form of resourcedictionary caching I might be missing? dll versions are 2013.1.220.40

Cheers, 
AC

3 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 08 Apr 2013, 07:12 AM
Hello,

If you mean that you have noticed thousands of ResourceDictionaries for all the available Themes, then this would be expected as they are all included in a regular assembly. If you believe I have misunderstood your question, then would you please be more specific?
 

Regards,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Andrew
Top achievements
Rank 1
answered on 17 May 2013, 08:49 PM
No, they're all loaded & in memory (noted via profiling). We use a shared resource dictionary, so our 30/40 resource dictionaries are each only loaded once, then we reference your libraries and its all out the window as you load 1000s of instances of yours! Any thoughts? 


0
Hristo
Telerik team
answered on 23 May 2013, 06:51 AM
Hello Andrew,

I'm sorry for the late reply.
We have two types of assemblies – normal and NoXAML.

Normal assemblies include XAML for ALL themes. If you use several of our assemblies the framework will load all ResourceDictinoaries in our assemblies (even when no theme is changed). There is no need to cache them because WPF loads them once (and cache them).

They are a lot because we have a lot of XAML to cover all theme (still not thousands). So if you are using custom theme based on windows 8 then you could use our NoXAML assemblies.

Our NoXAML assemblies contains only code (no XAML) which leads to smaller assembly size, faster application start-up and will reduce memory footprint.

Is this an acceptable solution?

Regards,

Hristo
Telerik

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
GridView
Asked by
Andrew
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Andrew
Top achievements
Rank 1
Hristo
Telerik team
Share this question
or