aboutsummaryrefslogtreecommitdiff
path: root/x11.cpp
diff options
context:
space:
mode:
authorLionel Ulmer2002-03-17 13:00:11 +0000
committerLionel Ulmer2002-03-17 13:00:11 +0000
commit80c57531413c927b3763ba7ab20c7a19131b0c69 (patch)
tree08afbd68dcfeb7287ae716ba0d697b9cb49a3d5c /x11.cpp
parent932973f8fa2f77b680e8eac6fa5bd773ff0f062d (diff)
downloadscummvm-rg350-80c57531413c927b3763ba7ab20c7a19131b0c69.tar.gz
scummvm-rg350-80c57531413c927b3763ba7ab20c7a19131b0c69.tar.bz2
scummvm-rg350-80c57531413c927b3763ba7ab20c7a19131b0c69.zip
Fixed the 'window title' problem for the SDL and X11 ports. Other 'porters' should fix their front-ends (sorry :-) ).
svn-id: r3776
Diffstat (limited to 'x11.cpp')
-rw-r--r--x11.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/x11.cpp b/x11.cpp
index ecb60fad4b..af8f5192fd 100644
--- a/x11.cpp
+++ b/x11.cpp
@@ -208,7 +208,7 @@ void initGraphics(Scumm *s, bool fullScreen, unsigned int scaleFactor) {
XTextProperty window_name;
char *name = (char *) &buf;
- scale = scaleFactor; // not implemented yet! ignored.
+ scale = scaleFactor; // not implemented yet! ignored.
/* For the window title */
sprintf(buf, "ScummVM - %s", gameName = s->getGameName());
@@ -278,6 +278,20 @@ void initGraphics(Scumm *s, bool fullScreen, unsigned int scaleFactor) {
local_fb = (unsigned char *) malloc(320 * 200 * sizeof(unsigned char));
}
+void setWindowName(Scumm *s) {
+ char buf[512], *gameName;
+ XTextProperty window_name;
+ char *name = (char *) &buf;
+
+ /* For the window title */
+ sprintf(buf, "ScummVM - %s", gameName = s->getGameName());
+ free(gameName);
+
+ XStringListToTextProperty( &name, 1, &window_name );
+ XSetWMProperties(display, window, &window_name, &window_name,
+ NULL /* argv */, 0 /* argc */, NULL /* size hints */, NULL /* WM hints */, NULL /* class hints */ );
+}
+
void setShakePos(Scumm *s, int shake_pos) {
warning("Unimplemented shaking !");
}