Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Qlik® Product Spotlight: Discover what’s possible. Get more from our products.
See for yourself. Register today.
Not applicable

no re-paint on selection

Dear Qlik Sense developers,

I need some advice on the following problem.

I've built an extension, which higlights a certain part of a map when I click on it.

My next step was to filter on the clicked part, and I succeeded, my extension now filters on data when I click on a certain part of my map.

However, when I click on a part, of my map, it now filters data, but then it forces a redraw of the map and the selected part is no longer highlighted.

I want the extension to filter, but I do not want it to redraw and loose the highlighted values.

Is there a way I can force the extension not to redraw, or is there a way I can retrieve my selected value and force the extension to highlight the selected value?

Hope you guys can help.

1 Solution

Accepted Solutions
erik_wetterberg
Honored Contributor

Re: no re-paint on selection

Well the paint method will be called, but you don't need to actually repaint the contents.You could do something like

paint : function($element, layout) {

    if(this.painted) return;

    this.painted = true;

    //your rendering here, will be called only once

}

Erik

Erik Wetterberg
https://extendingqlik.upper88.com/
1 Reply
erik_wetterberg
Honored Contributor

Re: no re-paint on selection

Well the paint method will be called, but you don't need to actually repaint the contents.You could do something like

paint : function($element, layout) {

    if(this.painted) return;

    this.painted = true;

    //your rendering here, will be called only once

}

Erik

Erik Wetterberg
https://extendingqlik.upper88.com/