Hello Alen,
WPM ability to measure statistics for applications that are not Web based (using HTTP protocol and rendering in HTML) is quite limited. As you discovered, WPM can interact with Java applications in browser only using coordinate system. It's because WPM does not have access to individual elements such as buttons in Java application, it can just blindly click on whatever coordinates you clicked on. Because of this WPM is also not able to measure any specific activity inside Java application.
However, you can measure time that it takes until something appears in the application using "Image match" functionality. When recording and when you are going to click on a button that sometimes does not appear fast enough, instead of clicking on it record an image match action and select that button as an image to look for. Then click on an image. This ensures that playback waits for the button (or more precisely part of application windows that looks like that button) and only after it appears it continues with the "click' action. Time that it takes to get the button is also counted to particular step duration.
If you play with this a little it should be able to give you reasonable results.