Automatic registration of Java widget listeners