upgraded for jquery widgets