Ticket #2996: 0002-5-Used-the-data-set-from-Java.patch

File 0002-5-Used-the-data-set-from-Java.patch, 961 bytes (added by BogDan, 9 years ago)
  • source/lib/sysdep/os/android/android.cpp

    From 20a77fbc7d985e8f46840a9ab666a76e27b89963 Mon Sep 17 00:00:00 2001
    From: BogDan Vatra <bogdan@kde.org>
    Date: Tue, 13 Jan 2015 18:48:49 +0200
    Subject: [PATCH 5/5] Used the data set from Java
    
    ---
     source/lib/sysdep/os/android/android.cpp | 7 ++-----
     1 file changed, 2 insertions(+), 5 deletions(-)
    
    diff --git a/source/lib/sysdep/os/android/android.cpp b/source/lib/sysdep/os/android/android.cpp
    index 105068a..5ec8871 100644
    a b namespace gfx {  
    4646
    4747Status GetVideoMode(int* xres, int* yres, int* bpp, int* freq)
    4848{
    49 #warning TODO: implement gfx::GetVideoMode properly for Android
    50 
    5149    if(xres)
    52         *xres = 800;
     50        *xres = atoi(getenv("ANDROID_SCREEN_WIDTH"));
    5351
    5452    if(yres)
    55         *yres = 480;
     53        *yres = atoi(getenv("ANDROID_SCREEN_HEIGHT"));
    5654
    5755    if(bpp)
    5856        *bpp = 32;
    Status sys_cursor_reset()  
    117115{
    118116    return INFO::OK;
    119117}
    120