Opened 8 years ago

Closed 8 years ago

#180 closed defect (fixed)

check change event is fired twice

Reported by: bartvde Owned by: ahocevar
Priority: major Milestone: 0.7
Component: GeoExt.tree.LayerNode Version: trunk
Keywords: Cc:
State: Commit

Description

the check change event is fired twice when changing a layer's visibility.

Attachments (1)

geoext-180.patch (4.4 KB) - added by ahocevar 8 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 8 years ago by bartvde

I can see this is caused by the call to GeoExt.tree.LayerNodeUI.superclass.toggleCheck.call(this, value); but simply removing this breaks a test for checkedGroup in LayerNode. Not sure how to handle this properly.

comment:2 Changed 8 years ago by ahocevar

  • Owner set to ahocevar

I will have a look. Thanks for the investigations so far.

Changed 8 years ago by ahocevar

comment:3 Changed 8 years ago by ahocevar

  • State changed from None to Review

Wow. There were some things badly wrong that I hadn't realized when I wrote the enforceOneVisible patch. Back then I just wondered about the need to manually set the checkbox state. And now finally I was able to resolve all this.

Tests still pass. Please review.

comment:4 Changed 8 years ago by tschaub

  • State changed from Review to Commit

This is a very nice looking patch. Please commit.

comment:5 Changed 8 years ago by ahocevar

  • Resolution set to fixed
  • Status changed from new to closed

(In [1492]) Fixed an issue that manifested itself by the checkchange event being fired twice, along with some weirdness of having to set the checkbox state manually. All of this is now resolved. r=tschaub (closes #180)

Note: See TracTickets for help on using tickets.