GNOME Bugzilla – Bug 733617
Don't deselect all markers when a marker got deselected
Last modified: 2014-07-27 16:20:11 UTC
This causes all markers deselection when a deselected marker "selected" property is resetted to FALSE. Thanks!
Created attachment 281495 [details] [review] Don't deselect all markers when a marker got deselected This causes all markers deselection when a deselected marker "selected" property is resetted to FALSE.
Hi Damian, could you please describe in more detail what the problem is - I don't completely understand. When using CHAMPLAIN_SELECTION_SINGLE, at most one marker is selected so I don't quite understand the "all markers deselection" part ("all" should be at most 1 with SINGLE). If you need multiple markers selected, you can use the CHAMPLAIN_SELECTION_MULTIPLE mode.
The problem occurs when a marker which has it "selected" property in FALSE is deselected, I mean, application calls "champlain_marker_set_selected(marker, FALSE)" in an already deselected marker. This causes that any selected marker becomes deselected just because we "deselect an already deselected marker". To illustrate it: I have: marker1->selected = true marker2->selected = false marker3->selected = false Then I execute: champlain_marker_set_selected(marker2, FALSE); Then I have marker1->selected = false marker2->selected = false marker3->selected = false I'm expecting the same as above: marker1->selected = true marker2->selected = false marker3->selected = false I hope I have explained correctly :)
Thanks, I understand now. The patch looks fine so I've just pushed it to master.