summaryrefslogtreecommitdiff
path: root/src/gui/widgets/tabs
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-03-16 14:14:29 +0300
committerAndrei Karas <akaras@inbox.ru>2014-03-16 14:14:29 +0300
commit46087564d4184b28740b0c45c1bac199ab1942ec (patch)
tree0591b36aba2ae392eb569828930f030850cbc769 /src/gui/widgets/tabs
parentcf9b1182f06b1336f0d1071c267ea36c990430fa (diff)
downloadmv-46087564d4184b28740b0c45c1bac199ab1942ec.tar.gz
mv-46087564d4184b28740b0c45c1bac199ab1942ec.tar.bz2
mv-46087564d4184b28740b0c45c1bac199ab1942ec.tar.xz
mv-46087564d4184b28740b0c45c1bac199ab1942ec.zip
Improve theme usage.
Removed instance method.
Diffstat (limited to 'src/gui/widgets/tabs')
-rw-r--r--src/gui/widgets/tabs/tab.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/gui/widgets/tabs/tab.cpp b/src/gui/widgets/tabs/tab.cpp
index ede69619e..1e5733a2b 100644
--- a/src/gui/widgets/tabs/tab.cpp
+++ b/src/gui/widgets/tabs/tab.cpp
@@ -123,9 +123,8 @@ Tab::~Tab()
gui->removeDragged(this);
mInstances--;
- if (mInstances == 0 && Theme::instance())
+ if (mInstances == 0 && theme)
{
- Theme *const theme = Theme::instance();
for (int mode = 0; mode < TAB_COUNT; mode ++)
theme->unload(tabImg[mode]);
}
@@ -154,7 +153,6 @@ void Tab::init()
if (mInstances == 0)
{
// Load the skin
- Theme *const theme = Theme::instance();
if (theme)
{
for (int mode = 0; mode < TAB_COUNT; mode ++)
@@ -177,7 +175,7 @@ void Tab::init()
void Tab::updateAlpha()
{
const float alpha = std::max(client->getGuiAlpha(),
- Theme::instance()->getMinimumOpacity());
+ theme->getMinimumOpacity());
if (alpha != mAlpha)
{