public boolean removeStickyEvent ( Object event ) { synchronized ( stickyEvents ) { Class < ? > eventType = event . getClass ( ) ; Object existingEvent = stickyEvents . get ( eventType ) ; if ( event . equals ( existingEvent ) ) { stickyEvents . remove ( eventType ) ; return true ; } else { return false ; } } }
Removes the sticky event if it equals to the given event .