Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [udig-devel] First cut of Events done! Please test

After using my brain for half a second we have:
For a more complicated thing - that is still in the style package:
    public void setFill(Fill fill) {
        if( this.fill == fill ) return;
        if( this.fill != null ){
            fireChildRemoved( fill );
        }
        this.fill = fill;
        if( fill != null ){
            fireChildAdded( fill );
        }            }
public void setFill(Fill fill) {
   if( this.fill == fill ) return;
   fireChildRemoved( this.fill );
   this.fill = fill;
   fireChildAdded( fill );
}

Which is a lot more maintainable.


Back to the top