Change widget ID generation to be compatible with 32bit systems.