void options_close() { Options::close_objects(); while(FocusHolder *fh = optionstack.ItemAt(0)) delete fh; settings_save(); }
void options_tick() { int i; FocusHolder *fh; if (justpushed(F3KEY)) { game.pause(0); return; } ClearScreen(BLACK); Options::run_and_draw_objects(); fh = optionstack.ItemAt(optionstack.CountItems() - 1); if (fh) { fh->RunInput(); if (game.paused != GP_OPTIONS) return; fh = optionstack.ItemAt(optionstack.CountItems() - 1); if (fh == opt.dismiss_on_focus && fh) { opt.dismiss_on_focus = NULL; delete fh; } } for(i=0;;i++) { fh = optionstack.ItemAt(i); if (!fh) break; fh->Draw(); } _vkey_edit_draw(); if (opt.xoffset > 0) { opt.dlg->offset(SLIDE_SPEED, 0); opt.xoffset -= SLIDE_SPEED; } }