[Scummvm-cvs-logs] CVS: scummvm newgui.cpp,1.4,1.5 newgui.h,1.4,1.5 guimaps.h,1.5,1.6
Max Horn
fingolfin at users.sourceforge.net
Sun Jul 7 15:45:03 CEST 2002
Update of /cvsroot/scummvm/scummvm
In directory usw-pr-cvs1:/tmp/cvs-serv10919
Modified Files:
newgui.cpp newgui.h guimaps.h
Log Message:
added options dialog; added NewGui TODO list;
Index: newgui.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/newgui.cpp,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- newgui.cpp 7 Jul 2002 21:46:53 -0000 1.4
+++ newgui.cpp 7 Jul 2002 22:44:29 -0000 1.5
@@ -28,10 +28,23 @@
#define vline(x, y, y2, color) line(x, y, x, y2, color);
+/*
+ * TODO list
+ * - add more widgets
+ * - implement hotkeys
+ * - add "close" widget to all dialogs (with a flag to turn it off) ?
+ * - make dialogs "moveable" ?
+ * - implement the missing / incomplete dialogs
+ * - come up with a new look&feel / theme for the GUI
+ * - ...
+ */
+
NewGui::NewGui(Scumm *s) : _s(s), _need_redraw(false)
{
_pauseDialog = new PauseDialog(this);
_saveLoadDialog = new SaveLoadDialog(this);
+// _aboutDialog = new AboutDialog(this);
+ _optionsDialog = new OptionsDialog(this);
}
void NewGui::pauseDialog()
@@ -44,6 +57,16 @@
openDialog(_saveLoadDialog);
}
+void NewGui::aboutDialog()
+{
+// openDialog(_aboutDialog);
+}
+
+void NewGui::optionsDialog()
+{
+ openDialog(_optionsDialog);
+}
+
void NewGui::loop()
{
Dialog *activeDialog = _dialogStack.top();
@@ -124,7 +147,7 @@
#pragma mark -
-const char *NewGui::queryString(int stringno)
+const char *NewGui::queryResString(int stringno)
{
char *result;
int string;
@@ -149,6 +172,11 @@
}
return result;
+}
+
+const char *NewGui::queryCustomString(int stringno)
+{
+ return string_map_table_custom[stringno];
}
#pragma mark -
Index: newgui.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/newgui.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- newgui.h 7 Jul 2002 21:58:12 -0000 1.4
+++ newgui.h 7 Jul 2002 22:44:29 -0000 1.5
@@ -52,6 +52,9 @@
// Dialogs
void pauseDialog();
void saveloadDialog();
+ void aboutDialog();
+ void optionsDialog();
+
void loop();
bool isActive() { return ! _dialogStack.empty(); }
@@ -65,6 +68,8 @@
Dialog *_pauseDialog;
Dialog *_saveLoadDialog;
+ Dialog *_aboutDialog;
+ Dialog *_optionsDialog;
// sound state
bool _old_soundsPaused;
@@ -94,8 +99,12 @@
void drawChar(const char c, int x, int y);
void drawString(const char *str, int x, int y, int w, byte color);
- //
- const char *queryString(int string);
+ // Query a string from the resources
+ const char *queryResString(int stringno);
+
+ // Query a custom string. This is in a seperate method so that we
+ // can easily localize the messages in the future if we want to.
+ const char *queryCustomString(int stringno);
};
#endif
Index: guimaps.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/guimaps.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- guimaps.h 5 Jul 2002 17:00:17 -0000 1.5
+++ guimaps.h 7 Jul 2002 22:44:29 -0000 1.6
@@ -50,7 +50,8 @@
"Show speech subtitles", //19
"Amiga pallette conversion", //20
"Except:", //21
- "Simon the Sorcerer (c) Adventuresoft" //22
+ "Simon the Sorcerer (c) Adventuresoft", //22
+ "Close" //23
};
static ResString string_map_table_v7[] = {
More information about the Scummvm-git-logs
mailing list