home / blog

Tag Archives: dev

Android dev: handling touch events on custom views

Embarrassingly this tripped me up for a while. In a custom view there were only single “click” events being called when a finger was dragged across the screen. This was due to the return value from the method being false … Continue reading

Posted in geek | Tagged , , , | Leave a comment

Android dev: app navigation using back button

The back button can be used to navigate within an application. The easiest way to do this is to define multiple activities. Activities can be moved into using action buttons etc, and then can be exited using the back button. … Continue reading

Posted in geek | Tagged , , | Leave a comment

Java look and feel class loading with OSGI

First some background… Java look and feels can be specified on the command line using the property “swing.defaultlaf”. This property gives the fully qualified classname of the look and feel to load. java -Dswing.defaultlaf=com.example.foo.FooLookAndFeel -jar app.jar This class is loaded … Continue reading

Posted in geek | Tagged , | Leave a comment

ToolTips not shown over JWindows

Tooltips not shown on components placed in JWindows. The fix/workaround is the following line somewhere in your application startup. UIManager.getDefaults().put(“ToolTipManager.enableToolTipMode”, “”); ToolTipManager only requires keyboard focus to show tooltips when the property ToolTipManager.enableToolTipMode is set to “activeApplication”. JWindow widgets do … Continue reading

Posted in geek | Tagged , | Comments Off on ToolTips not shown over JWindows