Added an example of how to create non-blocking widget code