Carsten,
You might be on to something. Until now, I hadn't considered that I was making two consecutive. calls that would fire a ProjectionChangedEvent.
Before trying your idea of placing a sleep between the setCenter() and setScale() calls, I decided to reverse the order they were called in to see if it would have any effect. It did! The behavior I described before stopped happening. It's the most scientific solution, but it seems to work in this case.
If anyone has a more concrete reason this happens, or a more definitive way to solve this problem, I am all ears.
-Kennedy
oland wrote:
Sounds like a threading problem then. Each of the projection change
events triggers doPrepare that launches a new thread that calls prepare
so it is very likely that your prepare method etc could be run
simultaneously (e.g., multi core box). Try putting in a small sleep
between setCenter & setScale to verify this. If that works fix the
threading problem in your layer.
BR
Carsten