summaryrefslogtreecommitdiff
path: root/src/gui/widgets/progressindicator.h
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2010-02-07 19:07:04 +0100
committerThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2010-02-07 19:07:04 +0100
commita3157908d23fd711ea96797dffce064953cb8fb6 (patch)
tree2f237b21118461a9948f3ccb829f62038564dedf /src/gui/widgets/progressindicator.h
parent1208d5383a9bfd03f338ccf71fb9764790b2e1a9 (diff)
downloadMana-a3157908d23fd711ea96797dffce064953cb8fb6.tar.gz
Mana-a3157908d23fd711ea96797dffce064953cb8fb6.tar.bz2
Mana-a3157908d23fd711ea96797dffce064953cb8fb6.tar.xz
Mana-a3157908d23fd711ea96797dffce064953cb8fb6.zip
Nicer way of indicating that we're waiting on the server
No longer a dialog with an annoying progress bar (due to going back and forth), but rather a progress indicator that integrates better with the background.
Diffstat (limited to 'src/gui/widgets/progressindicator.h')
-rw-r--r--src/gui/widgets/progressindicator.h46
1 files changed, 46 insertions, 0 deletions
diff --git a/src/gui/widgets/progressindicator.h b/src/gui/widgets/progressindicator.h
new file mode 100644
index 00000000..91a44a28
--- /dev/null
+++ b/src/gui/widgets/progressindicator.h
@@ -0,0 +1,46 @@
+/*
+ * The Mana World
+ * Copyright (C) 2010 The Mana World Development Team
+ *
+ * This file is part of The Mana World.
+ *
+ * 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, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef PROGRESSINDICATOR_H
+#define PROGRESSINDICATOR_H
+
+#include <guichan/widget.hpp>
+
+class SimpleAnimation;
+
+/**
+ * A widget that indicates progress. Suitable to use instead of a progress bar
+ * in cases where it is unknown how long something is going to take.
+ */
+class ProgressIndicator : public gcn::Widget
+{
+public:
+ ProgressIndicator();
+ ~ProgressIndicator();
+
+ void logic();
+ void draw(gcn::Graphics *graphics);
+
+private:
+ SimpleAnimation *mIndicator;
+};
+
+#endif // PROGRESSINDICATOR_H