File: ZBasicDefaultWidgetManager.rst

package info (click to toggle)
tuiwidgets 0.2-1.1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 14,940 kB
  • sloc: cpp: 54,583; python: 495; sh: 83; makefile: 8
file content (21 lines) | stat: -rw-r--r-- 921 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
.. _ZBasicDefaultWindowManager:

ZBasicDefaultWindowManager
==========================

.. rst-class:: tw-facet-impl
.. cpp:class:: Tui::ZBasicDefaultWindowManager : public Tui::ZDefaultWidgetManager

   This class is a basic implementation of :cpp:class:`Tui::ZDefaultWidgetManager`.

   For a given :cpp:class:`Tui::ZWidget` -- the dialog -- passed in the constructor,
   it stores one decendent of the dialog as default widget.

   :cpp:func:`bool Tui::ZDefaultWidgetManager::isDefaultWidgetActive() const` is reimplemented to
   return :cpp:expr:`true` iff there is a default widget and the widgets in the path of the currently focused
   widget to the dialog don't accept :kbd:`Enter`.

   If a widget accepts :kbd:`Enter` is determined by sending a ZEventType::queryAcceptsEnter event
   to it and it the event is accepted the widget is assumed to accept :kbd:`Enter` and thus the default
   window is not active.