Directory

← Back

Balling

The ultimate practical joke extension

Author

Rating

Popularity

<100

Using this extension, you can kick around lots of components in random ways (test out the demo, to see what I mean ;))

Just extend any component you wish and then enable fun mode. For each hit, an event is fired (this might be an issue on slow connections, for which it may be better not using the hit events). NOTE! The demo requires you to click the "Fun mode" button to enable the extension :)

Sample code

        Baller bExt = new Baller();
        bExt.addWickedWidgetType(AllowedWidgets.BUTTON);
        bExt.addWickedWidgetType(AllowedWidgets.TEXTFIELD);
        bExt.addWickedWidgetType(AllowedWidgets.PASSWORDFIELD);
        bExt.addWickedWidgetType(AllowedWidgets.CAPTION);
        bExt.addWickedWidgetType(AllowedWidgets.LABEL);
        bExt.extendComponent(mainLayout); // Extending mainLayout means that all widgets inside it will be wicked
        bExt.addBallerRecordListener(new BallerRecordListener() {

            @Override
            public void onNewRecord(BallerRecordEvent event) {
                recordLabel.setValue("record: " + event.getRecord());
            }
        });

        bExt.addBallerTouchListener(new BallerTouchListener() {

            @Override
            public void objectTouched(BallerTouchEvent event) {
                hitLabel.setValue("hits: " + event.getTouches());

            }
        });
        bExt.allowBallerHitEvents(true); // If false, client side won't send any events to the server
        bExt.allowBallerRecordEvents(true); // If false, client side won't send any events to the server
        bExt.setWicked(false); // use this flag to turn the wickedness on/off

Compatibility

(Loading compatibility data...)

Was this helpful? Need more help?
Leave a comment or a question below. You can also join the chat on Discord or ask questions on StackOverflow.

Version

Released
2013-03-27
Maturity
EXPERIMENTAL
License
Apache License 2.0

Compatibility

Framework
Vaadin 7.0+
Browser
Internet Explorer
Firefox
Opera
Safari
Google Chrome
Internet Explorer

Balling - Vaadin Add-on Directory

The ultimate practical joke extension Balling - Vaadin Add-on Directory
Using this extension, you can kick around lots of components in random ways (test out the demo, to see what I mean ;)) Just extend any component you wish and then enable fun mode. For each hit, an event is fired (this might be an issue on slow connections, for which it may be better not using the hit events). NOTE! The demo requires you to click the "Fun mode" button to enable the extension :)
Online