Hi Tim On Wed, Jun 4, 2014 at 11:06 PM, Tim Sutton <[email protected]> wrote: > Hi > > > Another regression / change in behaviour between legend in 2.x and master is > that layers added in python are not focussed in the legend. This breaks some > of our InaSAFE stuff that expects this behaviour. > > Good: > > http://storage8.static.itmages.com/i/14/0604/h_1401898037_8549074_84a270face.png > > Bad: > > http://storage9.static.itmages.com/i/14/0604/h_1401898084_4943485_004d455ff0.png
I think this behaviour can be added, but maybe it is not a good idea to rely on the fact that newly added layer is set as current. The behaviour wasn't documented anywhere, so it could be changed without any prior notice. Also, there could be various circumstances when this assumption may be wrong - e.g. plugins doing changes to the current layer. Finally, even in 2.2, if the user enables "Add new layers to selected or current group" and the selection is on a group, there will be no change of selection, so likely breaking that part of InaSAFE code too. Martin _______________________________________________ Qgis-developer mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/qgis-developer
