From 953101de6e60cf849c73e1109268b88c34062833 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 6 Jan 2015 17:30:10 +0300 Subject: Move downloadstatus.h into enums directory. --- src/CMakeLists.txt | 2 +- src/Makefile.am | 2 +- src/enums/net/downloadstatus.h | 38 ++++++++++++++++++++++++++++++++++++++ src/gui/windows/serverdialog.h | 3 ++- src/gui/windows/updaterwindow.h | 4 ++-- src/net/download.h | 2 +- src/net/downloadstatus.h | 38 -------------------------------------- 7 files changed, 45 insertions(+), 44 deletions(-) create mode 100644 src/enums/net/downloadstatus.h delete mode 100644 src/net/downloadstatus.h diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 0ca1648ee..a234347aa 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -538,7 +538,7 @@ SET(SRCS net/elementalhandler.h net/download.cpp net/download.h - net/downloadstatus.h + enums/net/downloadstatus.h net/gamehandler.h net/generalhandler.h net/guildhandler.h diff --git a/src/Makefile.am b/src/Makefile.am index f63ebdb90..21fe8b12e 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -668,7 +668,7 @@ manaplus_SOURCES += gui/widgets/avatarlistbox.cpp \ net/friendshandler.h \ net/download.cpp \ net/download.h \ - net/downloadstatus.h \ + enums/net/downloadstatus.h \ net/gamehandler.h \ net/generalhandler.h \ net/guildhandler.h \ diff --git a/src/enums/net/downloadstatus.h b/src/enums/net/downloadstatus.h new file mode 100644 index 000000000..a217e7a78 --- /dev/null +++ b/src/enums/net/downloadstatus.h @@ -0,0 +1,38 @@ +/* + * The ManaPlus Client + * Copyright (C) 2009-2010 The Mana Developers + * Copyright (C) 2011-2015 The ManaPlus Developers + * + * This file is part of The ManaPlus Client. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#ifndef ENUMS_NET_DOWNLOADSTATUS_H +#define ENUMS_NET_DOWNLOADSTATUS_H + +namespace DownloadStatus +{ + enum Type + { + Cancelled = -3, + ThreadError = -2, + Error = -1, + Starting = 0, + Idle = 1, + Complete = 2 + }; +} // namespace DownloadStatus + +#endif // ENUMS_NET_DOWNLOADSTATUS_H diff --git a/src/gui/windows/serverdialog.h b/src/gui/windows/serverdialog.h index 067993947..f59ff4ab7 100644 --- a/src/gui/windows/serverdialog.h +++ b/src/gui/windows/serverdialog.h @@ -25,7 +25,8 @@ #include "gui/widgets/window.h" -#include "net/downloadstatus.h" +#include "enums/net/downloadstatus.h" + #include "net/serverinfo.h" #include "utils/mutex.h" diff --git a/src/gui/windows/updaterwindow.h b/src/gui/windows/updaterwindow.h index f808d040a..6d3d7f49b 100644 --- a/src/gui/windows/updaterwindow.h +++ b/src/gui/windows/updaterwindow.h @@ -23,6 +23,8 @@ #ifndef GUI_WINDOWS_UPDATERWINDOW_H #define GUI_WINDOWS_UPDATERWINDOW_H +#include "enums/net/downloadstatus.h" + #include "gui/widgets/linkhandler.h" #include "gui/widgets/window.h" @@ -33,8 +35,6 @@ #include "listeners/actionlistener.h" #include "listeners/keylistener.h" -#include "net/downloadstatus.h" - #include #include diff --git a/src/net/download.h b/src/net/download.h index afb3c8d6b..c4cd8bbca 100644 --- a/src/net/download.h +++ b/src/net/download.h @@ -22,7 +22,7 @@ #ifndef NET_DOWNLOAD_H #define NET_DOWNLOAD_H -#include "net/downloadstatus.h" +#include "enums/net/downloadstatus.h" #include #include diff --git a/src/net/downloadstatus.h b/src/net/downloadstatus.h deleted file mode 100644 index 4582c0ae5..000000000 --- a/src/net/downloadstatus.h +++ /dev/null @@ -1,38 +0,0 @@ -/* - * The ManaPlus Client - * Copyright (C) 2009-2010 The Mana Developers - * Copyright (C) 2011-2015 The ManaPlus Developers - * - * This file is part of The ManaPlus Client. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#ifndef NET_DOWNLOADSTATUS_H -#define NET_DOWNLOADSTATUS_H - -namespace DownloadStatus -{ - enum Type - { - Cancelled = -3, - ThreadError = -2, - Error = -1, - Starting = 0, - Idle, - Complete - }; -} // namespace DownloadStatus - -#endif // NET_DOWNLOADSTATUS_H -- cgit v1.2.3-70-g09d2