summaryrefslogtreecommitdiff
path: root/setup.c
diff options
context:
space:
mode:
authorkamel5 <vdr.kamel5 (at) gmx (dot) net>2021-02-16 13:57:27 +0100
committerkamel5 <vdr.kamel5 (at) gmx (dot) net>2021-03-10 16:42:52 +0100
commit03337e57fdd83344d9b24ffcad394e76d5f92007 (patch)
tree45076068b910c2269bd14764b923b0391af4253b /setup.c
parentdaf3245de7437d287dc101db1d262848b2e4ad50 (diff)
downloadskin-nopacity-03337e57fdd83344d9b24ffcad394e76d5f92007.tar.gz
skin-nopacity-03337e57fdd83344d9b24ffcad394e76d5f92007.tar.bz2
Make imgCache global
Make imgcache global so that it doesn't always have to be passed explicitly to other functions.
Diffstat (limited to 'setup.c')
-rw-r--r--setup.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/setup.c b/setup.c
index 169e698..5258051 100644
--- a/setup.c
+++ b/setup.c
@@ -1,7 +1,6 @@
#include "setup.h"
-cNopacitySetup::cNopacitySetup(cImageCache *imgCache) {
- this->imgCache = imgCache;
+cNopacitySetup::cNopacitySetup(void) {
tmpConf = config;
cFont::GetAvailableFontNames(&fontNames);
fontNames.Insert(strdup(config.fontDefaultName));
@@ -73,7 +72,7 @@ eOSState cNopacitySetup::ProcessKey(eKeys Key) {
if (strcmp(ItemText, tr("Volume")) == 0)
state = AddSubMenu(new cNopacitySetupVolumeDisplay(&tmpConf));
if (strcmp(ItemText, tr("Image Caching")) == 0)
- state = AddSubMenu(new cNopacitySetupCaching(&tmpConf, imgCache));
+ state = AddSubMenu(new cNopacitySetupCaching(&tmpConf));
}
}
return state;
@@ -505,8 +504,7 @@ void cNopacitySetupVolumeDisplay::Set(void) {
//-----Image Caching-------------------------------------------------------------------------------------------------------------
-cNopacitySetupCaching::cNopacitySetupCaching(cNopacityConfig* data, cImageCache *imgCache) : cMenuSetupSubMenu(tr("Image Caching"), data) {
- this->imgCache = imgCache;
+cNopacitySetupCaching::cNopacitySetupCaching(cNopacityConfig* data) : cMenuSetupSubMenu(tr("Image Caching"), data) {
Set();
}
@@ -530,4 +528,4 @@ void cNopacitySetupCaching::Set(void) {
SetCurrent(Get(currentItem));
Display();
-} \ No newline at end of file
+}