diff options
Diffstat (limited to 'android/main-ui.c')
-rw-r--r-- | android/main-ui.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/android/main-ui.c b/android/main-ui.c index 5f3b8e9..043a9a8 100644 --- a/android/main-ui.c +++ b/android/main-ui.c @@ -61,6 +61,7 @@ #include "android/snapshot.h" #include "android/core-connection.h" +#include "android/framebuffer-ui.h" #include "framebuffer.h" #include "iolooper.h" @@ -103,6 +104,9 @@ unsigned long android_verbose; /* Instance of the "attach UI" Emulator's core console client. */ CoreConnection* attach_client = NULL; +/* Instance of the "framebuffer" console client. */ +ClientFramebuffer* fb_client = NULL; + /* -ui-settings parameters received from the core on UI attachment. */ char* core_ui_settings = ""; @@ -208,7 +212,7 @@ sdl_set_window_icon( void ) SDL_FreeSurface(icon); free( icon_pixels ); } -#endif /* !_WIN32 */ +#endif /* !_WIN32 */ } } @@ -921,7 +925,6 @@ attach_to_core(AndroidOptions* opts) { fprintf(stdout, "UI setting for the core%s:\n", core_ui_settings); } - return 0; } else { derror("Unable to attach to the core %s: %s\n", sock_address_to_string(&console_socket), @@ -939,6 +942,13 @@ attach_to_core(AndroidOptions* opts) { } else { return -1; } + + fb_client = clientfb_create(&console_socket, "-raw"); + if (fb_client == NULL) { + return -1; + } + + return 0; } int main(int argc, char **argv) |