4 XCSoar Glide Computer - http://www.xcsoar.org/
5 Copyright (C) 2000-2013 The XCSoar Project
6 A detailed list of copyright holders can be found in the file "AUTHORS".
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 #ifndef XCSOAR_PAGE_STATE_HPP
25 #define XCSOAR_PAGE_STATE_HPP
27 #include "PageSettings.hpp"
29 #include <type_traits>
32 * Keeps track of the state of the "pages" subsystem.
36 * The index of the current page in the list of configured pages,
39 * This setting is only active if #special_page is not defined.
40 * Otherwise, it is the page that we will return to after the user
41 * decides to leave the #special_page.
43 unsigned current_index
;
46 * If this attribute is defined (see PageLayout::IsDefined()), then
47 * the current page is not the one in #PageSettings, specified by
48 * #page_index, but a page that was created automatically. For
49 * example, it could be a page that was created by clicking on the
50 * FLARM radar. Pressing left/right will return to the last
53 PageLayout special_page
;
58 static_assert(std::is_trivial
<PagesState
>::value
, "type is not trivial");