~mterry/+junk/u8

« back to all changes in this revision

Viewing changes to plugins/Dash/CardCreatorCache.qml

Merge

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
 
24
24
    property var cache: new Object();
25
25
 
26
 
    function getCardComponent(template, components, isCardTool, artShapeStyle) {
 
26
    function getCardComponent(template, components, isCardTool, artShapeStyle, categoryLayout) {
27
27
        if (template === undefined || components === undefined)
28
28
            return undefined;
29
29
 
30
30
        var tString = JSON.stringify(template);
31
31
        var cString = JSON.stringify(components);
32
 
        var allString = tString + cString + isCardTool;
 
32
        var allString = tString + cString + isCardTool + artShapeStyle + categoryLayout;
33
33
        var component = cache[allString];
34
34
        if (component === undefined) {
35
 
            component = CardCreator.createCardComponent(root, template, components, isCardTool, artShapeStyle, allString);
 
35
            component = CardCreator.createCardComponent(root, template, components, isCardTool, artShapeStyle, categoryLayout, allString);
36
36
            cache[allString] = component;
37
37
        }
38
38
        return component;