Uploaded image for project: 'Click'
  1. Click
  2. CLK-369

Investigate adding ActionListener objet to Controls

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.5 M2
    • Fix Version/s: 1.5 M2
    • Component/s: core
    • Labels:
      None

      Description

      Currently the listener registered on Controls is string based.

      While simple to create it is harder to maintain as refactoring cannot be applied when renaming the method.

      An alternative to the string based listener is to introduce a ActionListener object that encapsulates the callback, and a method, AbstractControl.setListener(ActionListener) which registers the listener on the control.

      public class ActionListener {
      public boolean onAction(Control control)

      { return true; }

      }

        Attachments

          Activity

            People

            • Assignee:
              sabob Bob Schellink
              Reporter:
              sabob Bob Schellink
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: