Browse Source

Move enums into anonymous namespace

adaptive-webui-19844
Chocobo1 4 years ago
parent
commit
0bf76723f1
No known key found for this signature in database
GPG Key ID: 210D9C873253A68C
  1. 141
      src/gui/advancedsettings.cpp

141
src/gui/advancedsettings.cpp

@ -49,92 +49,93 @@ namespace
{ {
return QStringLiteral("<a href=\"%1\">%2</a>").arg(url, linkLabel); return QStringLiteral("<a href=\"%1\">%2</a>").arg(url, linkLabel);
} }
}
enum AdvSettingsCols enum AdvSettingsCols
{ {
PROPERTY, PROPERTY,
VALUE, VALUE,
COL_COUNT COL_COUNT
}; };
enum AdvSettingsRows
{ enum AdvSettingsRows
// qBittorrent section {
QBITTORRENT_HEADER, // qBittorrent section
QBITTORRENT_HEADER,
#if defined(Q_OS_WIN) #if defined(Q_OS_WIN)
OS_MEMORY_PRIORITY, OS_MEMORY_PRIORITY,
#endif #endif
// network interface // network interface
NETWORK_IFACE, NETWORK_IFACE,
//Optional network address //Optional network address
NETWORK_IFACE_ADDRESS, NETWORK_IFACE_ADDRESS,
// behavior // behavior
SAVE_RESUME_DATA_INTERVAL, SAVE_RESUME_DATA_INTERVAL,
CONFIRM_RECHECK_TORRENT, CONFIRM_RECHECK_TORRENT,
RECHECK_COMPLETED, RECHECK_COMPLETED,
// UI related // UI related
LIST_REFRESH, LIST_REFRESH,
RESOLVE_HOSTS, RESOLVE_HOSTS,
RESOLVE_COUNTRIES, RESOLVE_COUNTRIES,
PROGRAM_NOTIFICATIONS, PROGRAM_NOTIFICATIONS,
TORRENT_ADDED_NOTIFICATIONS, TORRENT_ADDED_NOTIFICATIONS,
CONFIRM_REMOVE_ALL_TAGS, CONFIRM_REMOVE_ALL_TAGS,
DOWNLOAD_TRACKER_FAVICON, DOWNLOAD_TRACKER_FAVICON,
SAVE_PATH_HISTORY_LENGTH, SAVE_PATH_HISTORY_LENGTH,
ENABLE_SPEED_WIDGET, ENABLE_SPEED_WIDGET,
// libtorrent section // libtorrent section
LIBTORRENT_HEADER, LIBTORRENT_HEADER,
ASYNC_IO_THREADS, ASYNC_IO_THREADS,
FILE_POOL_SIZE, FILE_POOL_SIZE,
CHECKING_MEM_USAGE, CHECKING_MEM_USAGE,
#if (LIBTORRENT_VERSION_NUM < 20000) #if (LIBTORRENT_VERSION_NUM < 20000)
// cache // cache
DISK_CACHE, DISK_CACHE,
DISK_CACHE_TTL, DISK_CACHE_TTL,
#endif #endif
OS_CACHE, OS_CACHE,
#if (LIBTORRENT_VERSION_NUM < 20000) #if (LIBTORRENT_VERSION_NUM < 20000)
COALESCE_RW, COALESCE_RW,
#endif #endif
#if (LIBTORRENT_VERSION_NUM >= 10202) #if (LIBTORRENT_VERSION_NUM >= 10202)
PIECE_EXTENT_AFFINITY, PIECE_EXTENT_AFFINITY,
#endif #endif
SUGGEST_MODE, SUGGEST_MODE,
SEND_BUF_WATERMARK, SEND_BUF_WATERMARK,
SEND_BUF_LOW_WATERMARK, SEND_BUF_LOW_WATERMARK,
SEND_BUF_WATERMARK_FACTOR, SEND_BUF_WATERMARK_FACTOR,
// networking & ports // networking & ports
SOCKET_BACKLOG_SIZE, SOCKET_BACKLOG_SIZE,
OUTGOING_PORT_MIN, OUTGOING_PORT_MIN,
OUTGOING_PORT_MAX, OUTGOING_PORT_MAX,
#if (LIBTORRENT_VERSION_NUM >= 10206) #if (LIBTORRENT_VERSION_NUM >= 10206)
UPNP_LEASE_DURATION, UPNP_LEASE_DURATION,
#endif #endif
UTP_MIX_MODE, UTP_MIX_MODE,
MULTI_CONNECTIONS_PER_IP, MULTI_CONNECTIONS_PER_IP,
#ifdef HAS_HTTPS_TRACKER_VALIDATION #ifdef HAS_HTTPS_TRACKER_VALIDATION
VALIDATE_HTTPS_TRACKER_CERTIFICATE, VALIDATE_HTTPS_TRACKER_CERTIFICATE,
#endif #endif
// embedded tracker // embedded tracker
TRACKER_STATUS, TRACKER_STATUS,
TRACKER_PORT, TRACKER_PORT,
// seeding // seeding
CHOKING_ALGORITHM, CHOKING_ALGORITHM,
SEED_CHOKING_ALGORITHM, SEED_CHOKING_ALGORITHM,
// tracker // tracker
ANNOUNCE_ALL_TRACKERS, ANNOUNCE_ALL_TRACKERS,
ANNOUNCE_ALL_TIERS, ANNOUNCE_ALL_TIERS,
ANNOUNCE_IP, ANNOUNCE_IP,
#if (LIBTORRENT_VERSION_NUM >= 10207) #if (LIBTORRENT_VERSION_NUM >= 10207)
MAX_CONCURRENT_HTTP_ANNOUNCES, MAX_CONCURRENT_HTTP_ANNOUNCES,
#endif #endif
STOP_TRACKER_TIMEOUT, STOP_TRACKER_TIMEOUT,
PEER_TURNOVER, PEER_TURNOVER,
PEER_TURNOVER_CUTOFF, PEER_TURNOVER_CUTOFF,
PEER_TURNOVER_INTERVAL, PEER_TURNOVER_INTERVAL,
ROW_COUNT ROW_COUNT
}; };
}
AdvancedSettings::AdvancedSettings(QWidget *parent) AdvancedSettings::AdvancedSettings(QWidget *parent)
: QTableWidget(parent) : QTableWidget(parent)

Loading…
Cancel
Save