File indexing completed on 2024-03-24 17:22:04
0001 /*************************************************************************** 0002 * Copyright (C) 2008-2011 by Daniel Nicoletti * 0003 * dantti12@gmail.com * 0004 * * 0005 * This program is free software; you can redistribute it and/or modify * 0006 * it under the terms of the GNU General Public License as published by * 0007 * the Free Software Foundation; either version 2 of the License, or * 0008 * (at your option) any later version. * 0009 * * 0010 * This program is distributed in the hope that it will be useful, * 0011 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 0012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 0013 * GNU General Public License for more details. * 0014 * * 0015 * You should have received a copy of the GNU General Public License * 0016 * along with this program; see the file COPYING. If not, write to * 0017 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, * 0018 * Boston, MA 02110-1301, USA. * 0019 ***************************************************************************/ 0020 0021 #ifndef ENUM_H 0022 #define ENUM_H 0023 0024 #include <config.h> 0025 0026 #ifdef HAVE_AUTOREMOVE 0027 #define AUTOREMOVE true 0028 #else 0029 #define AUTOREMOVE false 0030 #endif // HAVE_AUTOREMOVE 0031 0032 #define CFG_CHECK_UP_BATTERY "checkUpdatesOnBattery" 0033 #define CFG_CHECK_UP_MOBILE "checkUpdatesOnMobile" 0034 #define CFG_INSTALL_UP_BATTERY "installUpdatesOnBattery" 0035 #define CFG_INSTALL_UP_MOBILE "installUpdatesOnMobile" 0036 #define CFG_AUTO_UP "autoUpdate" 0037 #define CFG_INTERVAL "interval" 0038 #define CFG_DISTRO_UPGRADE "distroUpgrade" 0039 0040 #define DEFAULT_CHECK_UP_BATTERY false 0041 #define DEFAULT_CHECK_UP_MOBILE false 0042 #define DEFAULT_INSTALL_UP_BATTERY false 0043 #define DEFAULT_INSTALL_UP_MOBILE false 0044 0045 namespace Enum { 0046 0047 typedef enum { 0048 DistroNever, 0049 DistroDevelopment, 0050 DistroStable 0051 } DistroUpdate; 0052 const int DistroUpgradeDefault = DistroStable; 0053 0054 typedef enum { 0055 None, 0056 Security, 0057 All, 0058 DownloadOnly 0059 } AutoUpdate; 0060 const int AutoUpdateDefault = None; 0061 0062 typedef enum { 0063 Never = 0, 0064 Hourly = 3600, 0065 Daily = 86400, 0066 Weekly = 604800, 0067 Monthly = 2592000 // 30 days 0068 } TimeInterval; 0069 const int TimeIntervalDefault = Daily; 0070 0071 } 0072 0073 #endif