[Scummvm-cvs-logs] SF.net SVN: scummvm: [21984] scummvm/trunk/gui
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Mon Apr 17 11:51:04 CEST 2006
Revision: 21984
Author: lordhoto
Date: 2006-04-17 11:50:33 -0700 (Mon, 17 Apr 2006)
ViewCVS: http://svn.sourceforge.net/scummvm/?rev=21984&view=rev
Log Message:
-----------
Fixes bug with wrong colors in the logo after a screen change. (this time it works!)
Modified Paths:
--------------
scummvm/trunk/gui/launcher.cpp
scummvm/trunk/gui/launcher.h
Modified: scummvm/trunk/gui/launcher.cpp
===================================================================
--- scummvm/trunk/gui/launcher.cpp 2006-04-17 18:28:19 UTC (rev 21983)
+++ scummvm/trunk/gui/launcher.cpp 2006-04-17 18:50:33 UTC (rev 21984)
@@ -444,13 +444,14 @@
_w = screenW;
_h = screenH;
+ _logo = 0;
#ifndef DISABLE_FANCY_THEMES
if (g_gui.evaluator()->getVar("launcher_logo.visible") == 1) {
- GraphicsWidget *logo = new GraphicsWidget(this, "launcher_logo");
+ _logo = new GraphicsWidget(this, "launcher_logo");
ThemeNew *th = (ThemeNew *)g_gui.theme();
- logo->useTransparency(true);
+ _logo->useTransparency(true);
- logo->setGfx(th->getImageSurface(th->kThemeLogo));
+ _logo->setGfx(th->getImageSurface(th->kThemeLogo));
new StaticTextWidget(this, "launcher_version", gScummVMVersionDate);
} else
@@ -766,13 +767,14 @@
void LauncherDialog::handleScreenChanged() {
#ifndef DISABLE_FANCY_THEMES
if (g_gui.evaluator()->getVar("launcher_logo.visible") == 1) {
- GraphicsWidget *logo = new GraphicsWidget(this, "launcher_logo");
+ if (!_logo)
+ _logo = new GraphicsWidget(this, "launcher_logo");
ThemeNew *th = (ThemeNew *)g_gui.theme();
- logo->useTransparency(true);
+ _logo->useTransparency(true);
- logo->setGfx(th->getImageSurface(th->kThemeLogo));
-
- new StaticTextWidget(this, "launcher_version", gScummVMVersionDate);
+ _logo->setGfx(th->getImageSurface(th->kThemeLogo));
+ } else {
+ delete _logo;
}
#endif
Dialog::handleScreenChanged();
Modified: scummvm/trunk/gui/launcher.h
===================================================================
--- scummvm/trunk/gui/launcher.h 2006-04-17 18:28:19 UTC (rev 21983)
+++ scummvm/trunk/gui/launcher.h 2006-04-17 18:50:33 UTC (rev 21984)
@@ -31,6 +31,7 @@
class BrowserDialog;
class ListWidget;
+class GraphicsWidget;
class LauncherDialog : public Dialog {
typedef Common::String String;
@@ -46,6 +47,9 @@
Widget *_startButton;
Widget *_editButton;
Widget *_removeButton;
+#ifndef DISABLE_FANCY_THEMES
+ GraphicsWidget *_logo;
+#endif
StringList _domains;
GameDetector &_detector;
BrowserDialog *_browser;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list