1. Anders Ruud
  2. love

Issues

Issue #117 resolved

add love.graphics.hasFocus()

Anonymous created an issue

love now has a love.focus() callback. It makes sense to be able to query whether the window has focus or not.

Comments (3)

  1. Kosie van der Merwe

    On second thoughts, isFocused() is likely a better idea.

    Attached is a diff file (against r447:4deb61ae7d2c) implementing the feature. Like the event module this only checks SDL_APPINPUTFOCUS. My only worry is that it doesn't check whether isCreated() is true. Should it do this?

    Note: the diff does not update the changes.txt file.

  2. Log in to comment