mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-06 02:46:49 +00:00
fixed colors in gui
svn-id: r3944
This commit is contained in:
parent
084834f776
commit
4c95478ccb
21
gui.cpp
21
gui.cpp
@ -675,7 +675,7 @@ void Gui::handleCommand(int cmd)
|
||||
close();
|
||||
return;
|
||||
case 9: /* options button */
|
||||
options(_s);
|
||||
options();
|
||||
draw(0, 100);
|
||||
return;
|
||||
default:
|
||||
@ -822,14 +822,13 @@ void Gui::init(Scumm *s)
|
||||
_s = s;
|
||||
}
|
||||
|
||||
void Gui::loop(Scumm *s)
|
||||
void Gui::loop()
|
||||
{
|
||||
init(s);
|
||||
if (_active == 1) {
|
||||
_active++;
|
||||
draw(0, 200); // was 100
|
||||
_old_cursor_mode = s->_system->show_mouse(true);
|
||||
s->pauseSounds(true);
|
||||
_old_cursor_mode = _s->_system->show_mouse(true);
|
||||
_s->pauseSounds(true);
|
||||
}
|
||||
|
||||
_s->getKeyInput(0);
|
||||
@ -876,9 +875,8 @@ void Gui::close()
|
||||
#endif
|
||||
}
|
||||
|
||||
void Gui::saveLoadDialog(Scumm *s)
|
||||
void Gui::saveLoadDialog()
|
||||
{
|
||||
init(s);
|
||||
_widgets[0] = save_load_dialog;
|
||||
_editString = -1;
|
||||
_cur_page = 0;
|
||||
@ -886,27 +884,24 @@ void Gui::saveLoadDialog(Scumm *s)
|
||||
_dialog = SAVELOAD_DIALOG;
|
||||
}
|
||||
|
||||
void Gui::pause(Scumm *s)
|
||||
void Gui::pause()
|
||||
{
|
||||
init(s);
|
||||
_widgets[0] = pause_dialog;
|
||||
_cur_page = 0;
|
||||
_active = true;
|
||||
_dialog = PAUSE_DIALOG;
|
||||
}
|
||||
|
||||
void Gui::options(Scumm *s)
|
||||
void Gui::options()
|
||||
{
|
||||
init(s);
|
||||
_widgets[0] = options_dialog;
|
||||
_active = true;
|
||||
_cur_page = 0;
|
||||
_dialog = OPTIONS_DIALOG;
|
||||
}
|
||||
|
||||
void Gui::launcher(Scumm *s)
|
||||
void Gui::launcher()
|
||||
{
|
||||
init(s);
|
||||
_widgets[0] = launcher_dialog;
|
||||
_active = true;
|
||||
_cur_page = 0;
|
||||
|
10
gui.h
10
gui.h
@ -88,7 +88,7 @@ public:
|
||||
int _editLen;
|
||||
bool valid_games[9];
|
||||
char game_names[9][SAVEGAME_NAME_LEN];
|
||||
void loop(Scumm *s);
|
||||
void loop();
|
||||
void init(Scumm *s);
|
||||
void draw(int start, int end);
|
||||
void draw(int item) { draw(item,-1); }
|
||||
@ -115,10 +115,10 @@ public:
|
||||
byte getDefaultColor(int color);
|
||||
|
||||
// Dialogs
|
||||
void saveLoadDialog(Scumm *s);
|
||||
void pause(Scumm *s);
|
||||
void options(Scumm *s);
|
||||
void launcher(Scumm *s);
|
||||
void saveLoadDialog();
|
||||
void pause();
|
||||
void options();
|
||||
void launcher();
|
||||
|
||||
void handleSoundDialogCommand(int cmd);
|
||||
void handleOptionsDialogCommand(int cmd);
|
||||
|
@ -768,12 +768,12 @@ void Scumm::unkRoomFunc4(int a, int b, int c, int d, int e)
|
||||
|
||||
void Scumm::pauseGame(bool user)
|
||||
{
|
||||
((Gui *)_gui)->pause(this);
|
||||
((Gui *)_gui)->pause();
|
||||
}
|
||||
|
||||
void Scumm::setOptions()
|
||||
{
|
||||
((Gui *)_gui)->options(this);
|
||||
((Gui *)_gui)->options();
|
||||
}
|
||||
|
||||
void Scumm::shutDown(int i)
|
||||
@ -833,7 +833,7 @@ void Scumm::processKbd()
|
||||
&& _currentRoom != 0) {
|
||||
if (_features & GF_AFTER_V7)
|
||||
runScript(_vars[VAR_UNK_SCRIPT], 0, 0, 0);
|
||||
((Gui *)_gui)->saveLoadDialog(this);
|
||||
((Gui *)_gui)->saveLoadDialog();
|
||||
if (_features & GF_AFTER_V7)
|
||||
runScript(_vars[VAR_UNK_SCRIPT_2], 0, 0, 0);
|
||||
} else if (_lastKeyHit == _vars[VAR_TALKSTOP_KEY]) {
|
||||
@ -1193,7 +1193,7 @@ void Scumm::mainRun()
|
||||
waitForTimer(delta * 15 + last_time - new_time);
|
||||
last_time = _system->get_msecs();
|
||||
if (_gui->_active) {
|
||||
_gui->loop(this);
|
||||
_gui->loop();
|
||||
delta = 5;
|
||||
} else {
|
||||
delta = scummLoop(delta);
|
||||
|
Loading…
x
Reference in New Issue
Block a user