Package jltk.testing

Class AppTester


  • public class AppTester
    extends App
    Beschreiben Sie hier die Klasse AppTester.
    Version:
    (eine Versionsnummer oder ein Datum)
    Author:
    (Ihr Name)
    • Field Detail

    • Constructor Detail

      • AppTester

        public AppTester()
        Konstruktor für Objekte der Klasse AppTester
    • Method Detail

      • onMouseMoved

        public void onMouseMoved​(int pX,
                                 int pY)
        Description copied from class: App
        Will be called, if the mouse was moved. You have to overwrite this method in your subclass
        Overrides:
        onMouseMoved in class App
        Parameters:
        pX - The x-coordinate of the mouse position
        pY - The y-coordinate of the mouse position
      • onMouseDoubleClicked

        public void onMouseDoubleClicked​(int pX,
                                         int pY)
        Description copied from class: App
        Will be called, if the mouse was double clicked. You have to overwrite this method in your subclass
        Overrides:
        onMouseDoubleClicked in class App
        Parameters:
        pX - The x-coordinate of the mouse position
        pY - The y-coordinate of the mouse position
      • onMouseClicked

        public void onMouseClicked​(int pX,
                                   int pY)
        Description copied from class: App
        Will be called, if the mouse was clicked. You have to overwrite this method in your subclass
        Overrides:
        onMouseClicked in class App
        Parameters:
        pX - The x-coordinate of the mouse position
        pY - The y-coordinate of the mouse position
      • onKeyPressed

        public void onKeyPressed​(String pKey)
        Description copied from class: App
        Will be called, if a key on the keyboard was pressed. The parameter pKey is the corresponding key name.

        The following key names are recognized:

        • a-z
        • 0-1
        • up, down, left, right (cursor keys)
        • enter, space, tab, escape, backspace
        • F1-F12 (function keys)

        You have to overwrite this method in your subclass.

        Overrides:
        onKeyPressed in class App
        Parameters:
        pKey - The name of the pressed key
      • onKeyReleased

        public void onKeyReleased​(String pKey)
        Description copied from class: App
        Will be called, if a key on the keyboard was released. The parameter pKey is the corresponding key name

        The following key names are recognized:

        • a-z
        • 0-1
        • up, down, left, right (cursor keys)
        • enter, space, tab, escape, backspace
        • F1-F12 (function keys)

        You have to overwrite this method in your subclass.

        Overrides:
        onKeyReleased in class App
        Parameters:
        pKey - The name of the pressed key
      • act

        public void act()
        Description copied from class: App
        This method is called, every time no other eventhandler is called (on idle). You have to overwrite this method in your subclass.
        Overrides:
        act in class App
      • onFocusGained

        public void onFocusGained()
        Description copied from class: App
        This method is called if the window of this app get the focus. You have to overwrite this method in your subclass.
        Overrides:
        onFocusGained in class App
      • onFocusLost

        public void onFocusLost()
        Description copied from class: App
        This method is called if the window of this app lost the focus. You have to overwrite this method in your subclass.
        Overrides:
        onFocusLost in class App