question: private void sync ( ) { int s = state ; if ( ( s & RELOAD_IMAGE_FLAG ) != 0 ) { refreshImage ( ) ; } s = state ; if ( ( s & RELOAD_FLAG ) != 0 ) { synchronized ( this ) { state = ( state | RELOAD_FLAG ) ^ RELOAD_FLAG ; } setPropertiesFromAttributes ( ) ; } }
target:  Makes sure the necessary properties and image is loaded.