You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I found an issue #34 which tells how to activate the transform by default, but how you would keep it active all the time?
If I click besides the feature it looses the transforminteraction. I would like too keep it all the time active. Is there an option I can set to achieve that?
thx
The text was updated successfully, but these errors were encountered:
Hi,
Actually, the transform interaction contains a select interaction that means clicking outside the feature will deselect it and thus lose the transformation.
You have to listen to the "select" event to prevent from deselection:
interaction.on("select", function(e)
{ if (!e.feature) interaction.select(theFeature);
});
If you want to control the set of features you want to be selectable on click you also have to define the 'features' parameters on creation. To avoid selection, just define an empty collection:
var interaction = new ol.interaction.Transform (
{ features: new ol.Collection()
});
Hi, I found an issue #34 which tells how to activate the transform by default, but how you would keep it active all the time?
If I click besides the feature it looses the transforminteraction. I would like too keep it all the time active. Is there an option I can set to achieve that?
thx
The text was updated successfully, but these errors were encountered: