diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-07-08 20:03:16 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-07-13 01:02:40 +0300 |
commit | 36b586e32474e0d21de2383aa106869cfef89902 (patch) | |
tree | 6db1072a500cc63124c3a9a0712eada375605527 /src/gui/widgets/button.cpp | |
parent | 960820b57ecf45a4bf5e337bf36adbe02e668fbf (diff) | |
download | manaverse-36b586e32474e0d21de2383aa106869cfef89902.tar.gz manaverse-36b586e32474e0d21de2383aa106869cfef89902.tar.bz2 manaverse-36b586e32474e0d21de2383aa106869cfef89902.tar.xz manaverse-36b586e32474e0d21de2383aa106869cfef89902.zip |
Change scrollarea theming.
Diffstat (limited to 'src/gui/widgets/button.cpp')
-rw-r--r-- | src/gui/widgets/button.cpp | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/src/gui/widgets/button.cpp b/src/gui/widgets/button.cpp index 990faaaeb..ba789f2c5 100644 --- a/src/gui/widgets/button.cpp +++ b/src/gui/widgets/button.cpp @@ -173,30 +173,10 @@ void Button::init() if (mInstances == 0) { - // Load the skin - Image *btn[BUTTON_COUNT]; - if (Theme::instance()) { for (int mode = 0; mode < BUTTON_COUNT; mode ++) - { - Skin *skin = Theme::instance()->load(data[mode]); - if (skin) - { - const ImageRect &rect = skin->getBorder(); - - for (int f = 0; f < 9; f ++) - { - if (rect.grid[f]) - { - rect.grid[f]->incRef(); - button[mode].grid[f] = rect.grid[f]; - } - } - - Theme::instance()->unload(skin); - } - } + Theme::instance()->loadRect(button[mode], data[mode]); } updateAlpha(); |