On Fri, Oct 7, 2011 at 5:08 PM, Simon Schampijer <si...@schampijer.de> wrote: > The WirelessNetworkView listens on the State signal of the device, so it is > true that all the icons are updated when the device state changes. This > could be optimized in general.
Yes, I agree with this. The design is strange, but this is how the neighborhood view has worked for as long as I have been involved with the project. Each icon subscribes to all of its possible event sources (the search box, the network device it is associated with, etc), massively redundantly. In response to Sascha's question "Why?", I guess this is code that has grown up from something small and simple and has been pending improvement for a long time. The more sensible design is of course to have some kind of arbiter class that only passes on the relevant events to the relevant icons, but thats not how it works at the moment. I'm prepared to fix/improve this when moving us to introspection with libnm-util and hence redesigning much of our NM interaction, and the first step in that direction is the NM-0.9 patch pending review. For now Gonzalo's patch looks reasonable to me as well. Thanks Daniel _______________________________________________ Sugar-devel mailing list Sugar-devel@lists.sugarlabs.org http://lists.sugarlabs.org/listinfo/sugar-devel