summaryrefslogtreecommitdiff
path: root/src/gui/widgets/dropdown.cpp
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2010-02-27 21:50:25 -0700
committerJared Adams <jaxad0127@gmail.com>2010-02-28 10:30:45 -0700
commit500ee24e22aae7b457118d152b4480e99969092e (patch)
treeea0e7e3869a80fbc86cffe97136b926cc7149bdd /src/gui/widgets/dropdown.cpp
parent64e742acdb9b0dd9c44bced91766f5ea1aa9de4c (diff)
downloadmana-500ee24e22aae7b457118d152b4480e99969092e.tar.gz
mana-500ee24e22aae7b457118d152b4480e99969092e.tar.bz2
mana-500ee24e22aae7b457118d152b4480e99969092e.tar.xz
mana-500ee24e22aae7b457118d152b4480e99969092e.zip
Make the gui more themeable and distribute two themes
The older gray theme and the new wood theme are available as themes. The gray theme needs some new graphics for hilights. Add a theme option for branding and add path/to/branding/data to the PhysFS search path. Reviewed-by: Thorbjørn Lindeijer Reviewed-by: Chuck Miller
Diffstat (limited to 'src/gui/widgets/dropdown.cpp')
-rw-r--r--src/gui/widgets/dropdown.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/gui/widgets/dropdown.cpp b/src/gui/widgets/dropdown.cpp
index 32b42553..eb0cdef2 100644
--- a/src/gui/widgets/dropdown.cpp
+++ b/src/gui/widgets/dropdown.cpp
@@ -32,7 +32,6 @@
#include "gui/widgets/scrollarea.h"
#include "resources/image.h"
-#include "resources/resourcemanager.h"
#include "utils/dtor.h"
@@ -54,17 +53,16 @@ DropDown::DropDown(gcn::ListModel *listModel):
if (instances == 0)
{
// Load the background skin
- ResourceManager *resman = ResourceManager::getInstance();
// Get the button skin
buttons[1][0] =
- resman->getImage("graphics/gui/vscroll_up_default.png");
+ SkinLoader::getImageFromTheme("vscroll_up_default.png");
buttons[0][0] =
- resman->getImage("graphics/gui/vscroll_down_default.png");
+ SkinLoader::getImageFromTheme("vscroll_down_default.png");
buttons[1][1] =
- resman->getImage("graphics/gui/vscroll_up_pressed.png");
+ SkinLoader::getImageFromTheme("vscroll_up_pressed.png");
buttons[0][1] =
- resman->getImage("graphics/gui/vscroll_down_pressed.png");
+ SkinLoader::getImageFromTheme("vscroll_down_pressed.png");
buttons[0][0]->setAlpha(mAlpha);
buttons[0][1]->setAlpha(mAlpha);
@@ -72,7 +70,7 @@ DropDown::DropDown(gcn::ListModel *listModel):
buttons[1][1]->setAlpha(mAlpha);
// get the border skin
- Image *boxBorder = resman->getImage("graphics/gui/deepbox.png");
+ Image *boxBorder = SkinLoader::getImageFromTheme("deepbox.png");
int gridx[4] = {0, 3, 28, 31};
int gridy[4] = {0, 3, 28, 31};
int a = 0, x, y;