This project is read-only.
1

Resolved

Updating positions in control

description

Hi
 
I have made my own child of VEShape and I want to change its look each time a new frame is painted. I tought that the place to do it was the VEShape.UpdatePosistion by this method is only invoked to elemets of type VEPushPin instead of VEShape. Why?
 
The actual code:<font size="2" color="#0000ff"><font size="2" color="#0000ff">
 
private
 
 
 
</font></font><font size="2" color="#0000ff">
 

 
 
 
</font>
 
 
void RaiseViewChanged(){<font size="2">

 
</font>
 

 
foreach (object o in this.Items){ if (o is VEPushPin) {<font size="2">

 
</font>

 
   VEPushPin pin = o as VEPushPin;<font size="2">
   pin.UpdatePosition(
 
</font>
this);
 
 }}//More code
 
}
 
The proposal:
 
 
 
privatevoid RaiseViewChanged(){<font size="2">

 
</font>
 

 
foreach (object o in this.Items){ if (o is VEShape) { <font size="2">

 
</font>
 

 
   VEShape pin = o as VEShape; <font size="2">
   pin.UpdatePosition(
 
</font>
 
this);
 
 }}//More code
 
}
 
 
Huge thanks

comments