[Scummvm-cvs-logs] SF.net SVN: scummvm: [27608] scummvm/trunk/engines/lure

dreammaster at users.sourceforge.net dreammaster at users.sourceforge.net
Fri Jun 22 14:40:39 CEST 2007


Revision: 27608
          http://scummvm.svn.sourceforge.net/scummvm/?rev=27608&view=rev
Author:   dreammaster
Date:     2007-06-22 05:40:30 -0700 (Fri, 22 Jun 2007)

Log Message:
-----------
Removed old debug input files no longer being used, and the Lure disassembly folder

Removed Paths:
-------------
    scummvm/trunk/engines/lure/debug-input.cpp
    scummvm/trunk/engines/lure/debug-input.h
    scummvm/trunk/engines/lure/debug-methods.cpp
    scummvm/trunk/engines/lure/debug-methods.h
    scummvm/trunk/engines/lure/disassembly/

Deleted: scummvm/trunk/engines/lure/debug-input.cpp
===================================================================
--- scummvm/trunk/engines/lure/debug-input.cpp	2007-06-22 12:36:49 UTC (rev 27607)
+++ scummvm/trunk/engines/lure/debug-input.cpp	2007-06-22 12:40:30 UTC (rev 27608)
@@ -1,136 +0,0 @@
-/* ScummVM - Graphic Adventure Engine
- *
- * ScummVM is the legal property of its developers, whose names
- * are too numerous to list here. Please refer to the COPYRIGHT
- * file distributed with this source distribution.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
-
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
- * GNU General Public License for more details.
-
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * $URL$
- * $Id$
- *
- */
-
-#include "lure/debug-input.h"
-#include "lure/luredefs.h"
-#include "lure/events.h"
-#include "lure/surface.h"
-#include "lure/screen.h"
-
-#ifdef LURE_DEBUG
-
-namespace Lure {
-
-bool get_string(char *buffer, uint32 maxSize, bool isNumeric, uint16 x, uint16 y) {
-	Events &e = Events::getReference();
-	buffer[0] = '\0';
-
-	// Create surface for holding entered text
-	Surface *s = new Surface((maxSize + 1) * FONT_WIDTH, FONT_HEIGHT);
-
-	bool abortFlag = false;
-	bool refreshFlag = true;
-
-	while (!e.quitFlag && !abortFlag) {
-		// Check for refreshing display of text
-		if (refreshFlag) {
-			uint16 strWidth = Surface::textWidth(buffer);
-			s->empty();
-			s->writeString(0, 0, buffer, false, DIALOG_TEXT_COLOUR);
-			s->writeChar(strWidth, 0, '_', false, DIALOG_TEXT_COLOUR);
-			s->copyToScreen(x, y);
-
-			refreshFlag = false;
-		}
-
-		if (e.pollEvent()) {
-			if (e.type() == Common::EVENT_KEYDOWN) {
-				char ch = e.event().kbd.ascii;
-				uint16 keycode = e.event().kbd.keycode;
-
-				if ((ch == 13) || (keycode == 0x10f))
-					break;
-				else if (ch == 27) 
-					abortFlag = true;
-				else if (ch == 8) {
-					if (*buffer != '\0') {
-						*((char *) buffer + strlen(buffer) - 1) = '\0';
-						refreshFlag = true;
-					}
-				} else if ((ch >= ' ') && (strlen(buffer) < maxSize)) {
-					if (((ch >= '0') && (ch <= '9')) || !isNumeric) {
-						char *p = buffer + strlen(buffer);
-						*p++ = ch;
-						*p++ = '\0';
-						refreshFlag = true;
-					}
-				}
-			}
-		}
-	}
-
-	delete s;
-	if (e.quitFlag) abortFlag = true;
-	return !abortFlag;
-}
-
-bool input_integer(Common::String desc, uint32 &value)
-{
-	const int MAX_SIZE = 5;
-	char buffer[MAX_SIZE + 1];
-
-	uint16 width = DIALOG_EDGE_SIZE + Surface::textWidth(desc.c_str()) + FONT_WIDTH;
-	uint16 totalWidth = width + FONT_WIDTH * (MAX_SIZE + 1) + DIALOG_EDGE_SIZE;
-	uint16 totalHeight = FONT_HEIGHT + DIALOG_EDGE_SIZE * 2;
-
-	Surface *s = new Surface(totalWidth, totalHeight);
-	s->createDialog(true);
-	s->writeString(DIALOG_EDGE_SIZE + 3, DIALOG_EDGE_SIZE, desc, false);
-
-	uint16 xs = (FULL_SCREEN_WIDTH-totalWidth) / 2;
-	uint16 ys = (FULL_SCREEN_HEIGHT-totalHeight) / 2;
-	s->copyToScreen(xs, ys);
-
-	bool result = get_string(&buffer[0], MAX_SIZE, true, xs+width, ys+DIALOG_EDGE_SIZE);
-	Screen::getReference().update();
-	if (!result || (buffer[0] == '\0')) 
-		return false;
-
-	value = atoi(buffer);
-	return true;
-}
-
-bool input_string(Common::String desc, char *buffer, uint32 maxSize)
-{
-	uint16 width = Surface::textWidth(desc.c_str());
-	if (width < FONT_WIDTH * maxSize) width = FONT_WIDTH * maxSize;
-
-	Surface *s = new Surface(width + 2 * DIALOG_EDGE_SIZE, 2 * FONT_HEIGHT + 2 * DIALOG_EDGE_SIZE);
-	s->createDialog();
-	s->writeString(DIALOG_EDGE_SIZE, DIALOG_EDGE_SIZE, desc, false, DIALOG_TEXT_COLOUR);
-
-	uint16 xs = (FULL_SCREEN_WIDTH-s->width()) / 2;
-	uint16 ys = (FULL_SCREEN_HEIGHT-s->height()) / 2;
-
-	s->copyToScreen(xs, ys);
-	bool result = get_string(buffer, maxSize, true, xs + width, ys + DIALOG_EDGE_SIZE);
-
-	Screen::getReference().update();
-	return result;
-}
-
-} // end of namespace Lure
-
-#endif

Deleted: scummvm/trunk/engines/lure/debug-input.h
===================================================================
--- scummvm/trunk/engines/lure/debug-input.h	2007-06-22 12:36:49 UTC (rev 27607)
+++ scummvm/trunk/engines/lure/debug-input.h	2007-06-22 12:40:30 UTC (rev 27608)
@@ -1,45 +0,0 @@
-/* ScummVM - Graphic Adventure Engine
- *
- * ScummVM is the legal property of its developers, whose names
- * are too numerous to list here. Please refer to the COPYRIGHT
- * file distributed with this source distribution.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
-
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
- * GNU General Public License for more details.
-
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * $URL$
- * $Id$
- *
- */
-
-#ifdef LURE_DEBUG
-#ifndef LURE_DEBUG_INPUT_H
-#define LURE_DEBUG_INPUT_H
-
-#include "common/stdafx.h"
-#include "common/str.h"
-#include "lure/surface.h"
-
-namespace Lure {
-
-bool get_string(char *buffer, uint32 maxSize, bool isNumeric, uint16 x, uint16 y);
-
-bool input_integer(Common::String desc, uint32 &value);
-
-bool input_string(Common::String desc, char *buffer, uint32 maxSize);
-
-} // End of namespace Lure
-
-#endif
-#endif

Deleted: scummvm/trunk/engines/lure/debug-methods.cpp
===================================================================
--- scummvm/trunk/engines/lure/debug-methods.cpp	2007-06-22 12:36:49 UTC (rev 27607)
+++ scummvm/trunk/engines/lure/debug-methods.cpp	2007-06-22 12:40:30 UTC (rev 27608)
@@ -1,135 +0,0 @@
-/* ScummVM - Graphic Adventure Engine
- *
- * ScummVM is the legal property of its developers, whose names
- * are too numerous to list here. Please refer to the COPYRIGHT
- * file distributed with this source distribution.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
-
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
- * GNU General Public License for more details.
-
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * $URL$
- * $Id$
- *
- */
-
-#include "lure/debug-methods.h"
-#include "lure/luredefs.h"
-
-#include "lure/events.h"
-#include "lure/surface.h"
-#include "lure/screen.h"
-#include "lure/res.h"
-#include "lure/strings.h"
-#include "lure/room.h"
-
-#ifdef LURE_DEBUG
-
-namespace Lure {
-
-void showActiveHotspots() {
-	char buffer[16384];
-	char *lines[100];
-	char *s = buffer;
-	int numLines = 0;
-	lines[0] = s;
-	*s = '\0';
-
-	Resources &resources = Resources::getReference();
-	Mouse &mouse = Mouse::getReference();
-	Events &events = Events::getReference();
-	Screen &screen = Screen::getReference();
-
-	HotspotList::iterator i = resources.activeHotspots().begin();
-	for (; i != resources.activeHotspots().end(); ++i) {
-		Hotspot &h = *i.operator*();
-		lines[numLines++] = s;
-
-		if (numLines == 16) {
-			strcpy(s, "..more..");
-			break;
-		}
-
-		sprintf(s, "%x", h.hotspotId());
-		s += strlen(s);
-
-		sprintf(s, "h pos=(%d,%d,%d) size=(%d,%d) - ",
-			h.roomNumber(), h.x(), h.y(), h.width(), h.height());
-		s += strlen(s);
-
-		uint16 nameId = h.nameId();
-		if (nameId != 0) {
-			StringData::getReference().getString(nameId, s, NULL, NULL);
-			s += strlen(s);
-		}
-		++s;
-	}
-
-	Surface *surface = Surface::newDialog(300, numLines, (const char**)lines);
-	mouse.cursorOff();
-	surface->copyToScreen(10, 40);
-	events.waitForPress();
-	screen.update();
-	mouse.cursorOn();
-	delete surface;
-}
-
-void showRoomHotspots() {
-	char buffer[16384];
-	char *lines[100];
-	char *s = buffer;
-	int numLines = 0;
-	lines[0] = s;
-	*s = '\0';
-
-	Resources &resources = Resources::getReference();
-	Mouse &mouse = Mouse::getReference();
-	Events &events = Events::getReference();
-	Screen &screen = Screen::getReference();
-	uint16 roomNumber = Room::getReference().roomNumber();
-
-	HotspotDataList::iterator i = resources.hotspotData().begin();
-	for (; i != resources.hotspotData().end(); ++i) {
-		HotspotData &h = *i.operator*();
-		if (h.roomNumber == roomNumber) {
-			lines[numLines++] = s;
-
-			sprintf(s, "%x", h.hotspotId);
-			s += strlen(s);
-
-			sprintf(s, "h pos=(%d,%d) size=(%d,%d) - ",
-				h.startX, h.startY, h.width, h.height);
-			s += strlen(s);
-
-			uint16 nameId = h.nameId;
-			if (nameId != 0) {
-				StringData::getReference().getString(nameId, s, NULL, NULL);
-				s += strlen(s);
-			}
-			++s;
-		}
-	}
-
-	Surface *surface = Surface::newDialog(300, numLines, (const char**)lines);
-	mouse.cursorOff();
-	surface->copyToScreen(10, 40);
-	events.waitForPress();
-	screen.update();
-	mouse.cursorOn();
-	delete surface;
-}
-
-
-} // end of namespace Lure
-
-#endif

Deleted: scummvm/trunk/engines/lure/debug-methods.h
===================================================================
--- scummvm/trunk/engines/lure/debug-methods.h	2007-06-22 12:36:49 UTC (rev 27607)
+++ scummvm/trunk/engines/lure/debug-methods.h	2007-06-22 12:40:30 UTC (rev 27608)
@@ -1,42 +0,0 @@
-/* ScummVM - Graphic Adventure Engine
- *
- * ScummVM is the legal property of its developers, whose names
- * are too numerous to list here. Please refer to the COPYRIGHT
- * file distributed with this source distribution.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
-
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
- * GNU General Public License for more details.
-
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * $URL$
- * $Id$
- *
- */
-
-#ifdef LURE_DEBUG
-#ifndef LURE_DEBUG_METHODS_H
-#define LURE_DEBUG_METHODS_H
-
-#include "common/stdafx.h"
-#include "lure/surface.h"
-
-namespace Lure {
-
-void showActiveHotspots();
-
-void showRoomHotspots();
-
-} // End of namespace Lure
-
-#endif
-#endif


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