Clean up and comply to new api.
authorasterix <asterix@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 20 May 2010 16:49:05 +0000 (16:49 +0000)
committerasterix <asterix@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 20 May 2010 16:49:05 +0000 (16:49 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@3757 38d2e660-2303-0410-9eaa-f027e97ec537

bertos/drv/lcd_gfx_qt.cpp
bertos/drv/lcd_gfx_qt.h

index b7a2e519273f1294af261d60cc055af7c4692e5d..69ff66f4c2c14715f9427c2c81e9696a82c3379d 100644 (file)
@@ -30,7 +30,6 @@
  *
  * -->
  *
- * \version $Id$
  * \author Bernie Innocenti <bernie@codewiz.org>
  *
  * \brief Custom control for graphics LCD emulation (implementation)
@@ -166,18 +165,18 @@ DECLARE_WALL(wall_before_raster, WALL_SIZE)
 static uint8_t lcd_raster[RAST_SIZE(EmulLCD::WIDTH, EmulLCD::HEIGHT)];
 DECLARE_WALL(wall_after_raster, WALL_SIZE)
 
-/** Default LCD bitmap */
-struct Bitmap lcd_bitmap;
 
-/*extern "C"*/ void lcd_init(void)
+
+
+/*extern "C"*/ void lcd_gfx_qt_init(Bitmap *lcd_bitmap)
 {
        //FIXME INIT_WALL(wall_before_raster);
        //FIXME INIT_WALL(wall_after_raster);
-       gfx_bitmapInit(&lcd_bitmap, lcd_raster, EmulLCD::WIDTH, EmulLCD::HEIGHT);
-       gfx_bitmapClear(&lcd_bitmap);
+       gfx_bitmapInit(lcd_bitmap, lcd_raster, EmulLCD::WIDTH, EmulLCD::HEIGHT);
+       gfx_bitmapClear(lcd_bitmap);
 }
 
-/*extern "C"*/ void lcd_blitBitmap(Bitmap *bm)
+/*extern "C"*/ void lcd_gfx_qt_blitBitmap(const        Bitmap *bm)
 {
        //FIXME CHECK_WALL(wall_before_raster);
        //FIXME CHECK_WALL(wall_after_raster);
index f1bb4e9311f5a61422370b8ff704c8fcb7d8d864..9840f24cd44817db4765c07619b514999eb62117 100644 (file)
@@ -30,7 +30,6 @@
  * All Rights Reserved.
  * -->
  *
- * \version $Id$
  * \author Bernie Innocenti <bernie@codewiz.org>
  *
  * \brief Custom control for graphics LCD emulation (interface)
 #define DRV_LCD_GFX_QT_H
 
 // uint8_t
+#include <gfx/gfx.h>
 #include <cfg/compiler.h>
 
 #include <QtGui/QColor>
 #include <QtGui/QFrame>
 
+#define LCD_WIDTH      128
+
 // fwd decls
 class QSizePolicy;
 class QPaintEvent;
@@ -89,4 +91,8 @@ protected:
        unsigned char raster[(WIDTH + 7 / 8) * HEIGHT];
 };
 
+
+void lcd_gfx_qt_init(Bitmap *lcd_bitmap);
+void lcd_gfx_qt_blitBitmap(const Bitmap *bm);
+
 #endif // DRV_LCD_GFX_QT_H