Skip to content

Commit

Permalink
Add toga.App.app to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
rmartin16 committed Feb 20, 2024
1 parent a5782ba commit 3e34b0c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions changes/2413.doc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The class property ``toga.App.app`` was added as the currently running app to the reference API for ``App``.
2 changes: 2 additions & 0 deletions core/src/toga/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,8 @@ def _default_title(self) -> str:


class App:
#: The currently running :class:`~toga.App`. Since there can only be one running
#: Toga app in a process, this is available as a class property via ``toga.App.app``.
app = None

def __init__(
Expand Down
1 change: 0 additions & 1 deletion docs/reference/api/app.rst
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ Reference
---------

.. autoclass:: toga.App
:exclude-members: app

.. autoprotocol:: toga.app.AppStartupMethod
.. autoprotocol:: toga.app.BackgroundTask
Expand Down

0 comments on commit 3e34b0c

Please sign in to comment.