Skip to content

Clean up state management in Sprites as well as the main scene #26

@yangsu

Description

@yangsu

So this doesn't happen

  public boolean onMouseDown(float x, float y) {
    if (fControlVisible) {
      fControlActive = false;
      for (Control c : fControls) {
        fControlActive = c.onMouseDown(x, y);
        if (fControlActive) {
          fSelected = true;
          return true;
        }
      }
    }
    // for (Path p : fAxons)
    //   if (p.onMouseDown(x, y))
    //     return true;
    // for (Path p : fDendrites)
    //   if (p.onMouseDown(x, y))
    //     return true;
    return super.onMouseDown(x, y);
  }

Won't paste the code here but the main controller / object collection is a mess

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions