Fixed widget code to work with show num events