mirror of
https://github.com/Oibaf66/frodo-wii.git
synced 2024-11-29 06:54:22 +01:00
Activate the Gui (basic stuff works!)
This commit is contained in:
parent
0ae643c77e
commit
fcf5d06256
@ -338,6 +338,8 @@ void C64::VBlank(bool draw_frame)
|
||||
}
|
||||
this->network_vblank();
|
||||
|
||||
Gui::gui->runLogic();
|
||||
|
||||
#if defined(GEKKO)
|
||||
if (this->quit_thyself && Network::networking_started == true)
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
|
@ -327,6 +327,7 @@ void C64Display::Update(uint8 *src_pixels)
|
||||
this->Update_32((Uint8*)screen); break;
|
||||
}
|
||||
}
|
||||
Gui::gui->draw(real_screen);
|
||||
|
||||
if (this->TheC64->network_connection_type != NONE)
|
||||
draw_string(real_screen, 0, 0, networktraffic_string, black, fill_gray);
|
||||
@ -669,6 +670,8 @@ void C64Display::PollKeyboard(uint8 *key_matrix, uint8 *rev_matrix, uint8 *joyst
|
||||
{
|
||||
SDL_Event event;
|
||||
while (SDL_PollEvent(&event)) {
|
||||
Gui::gui->pushEvent(&event);
|
||||
|
||||
switch (event.type) {
|
||||
|
||||
// Key pressed
|
||||
@ -691,7 +694,7 @@ void C64Display::PollKeyboard(uint8 *key_matrix, uint8 *rev_matrix, uint8 *joyst
|
||||
break;
|
||||
|
||||
case SDLK_HOME: // Home: Pause and enter menu
|
||||
TheC64->enter_menu();
|
||||
Gui::gui->activate();
|
||||
break;
|
||||
|
||||
case SDLK_KP_PLUS: // '+' on keypad: Increase SkipFrames
|
||||
|
@ -75,8 +75,6 @@ int main(int argc, char **argv)
|
||||
fprintf(stderr, "Unable to init TTF: %s\n", TTF_GetError() );
|
||||
return 1;
|
||||
}
|
||||
Gui::gui = new Gui();
|
||||
Gui::gui->setTheme("default");
|
||||
#endif
|
||||
if (!init_graphics())
|
||||
return 1;
|
||||
@ -141,6 +139,7 @@ void Frodo::ReadyToRun(void)
|
||||
|
||||
// Create and start C64
|
||||
TheC64 = new C64;
|
||||
Gui::init();
|
||||
load_rom_files();
|
||||
TheC64->Run();
|
||||
delete TheC64;
|
||||
|
Loading…
Reference in New Issue
Block a user