From 9167422ce3b479671419784c6b26bb2c8ee799f5 Mon Sep 17 00:00:00 2001 From: Nicola Mettifogo Date: Sat, 11 Aug 2007 20:44:22 +0000 Subject: Moved cursor handling from Gfx to engine subclasses. svn-id: r28534 --- engines/parallaction/graphics.cpp | 40 --------------------------------------- 1 file changed, 40 deletions(-) (limited to 'engines/parallaction/graphics.cpp') diff --git a/engines/parallaction/graphics.cpp b/engines/parallaction/graphics.cpp index cdc2641666..2e7d79c37c 100644 --- a/engines/parallaction/graphics.cpp +++ b/engines/parallaction/graphics.cpp @@ -454,43 +454,8 @@ void jobEraseLabel(void *parm, Job *j) { return; } -void Gfx::initMouse(uint16 arg_0) { - _mouseComposedArrow = _vm->_disk->loadPointer(); - byte temp[MOUSEARROW_WIDTH*MOUSEARROW_HEIGHT]; - memcpy(temp, _mouseArrow, MOUSEARROW_WIDTH*MOUSEARROW_HEIGHT); - - uint16 k = 0; - for (uint16 i = 0; i < 4; i++) { - for (uint16 j = 0; j < 64; j++) _mouseArrow[k++] = temp[i + j * 4]; - } - - return; -} - - -void Gfx::setMousePointer(int16 index) { - - if (index == kCursorArrow) { // standard mouse pointer - - g_system->setMouseCursor(_mouseArrow, MOUSEARROW_WIDTH, MOUSEARROW_HEIGHT, 0, 0, 0); - g_system->showMouse(true); - - } else { - // inventory item pointer - byte *v8 = (byte*)_mouseComposedArrow->pixels; - - // FIXME: destination offseting is not clear - byte* s = _vm->_char._objs->getFramePtr(getInventoryItemIndex(index)); - byte* d = v8 + 7 + MOUSECOMBO_WIDTH * 7; - copyRect(INVENTORYITEM_WIDTH, INVENTORYITEM_HEIGHT, d, MOUSECOMBO_WIDTH, s, INVENTORYITEM_PITCH); - - g_system->setMouseCursor(v8, MOUSECOMBO_WIDTH, MOUSECOMBO_HEIGHT, 0, 0, 0); - } - - return; -} @@ -824,8 +789,6 @@ Gfx::Gfx(Parallaction* vm) : memset(_palettefx, 0, sizeof(_palettefx)); - initMouse( 0 ); - _halfbrite = false; _font = NULL; @@ -840,9 +803,6 @@ Gfx::~Gfx() { _buffers[kBitBack]->free(); delete _buffers[kBitBack]; - _mouseComposedArrow->free(); - delete _mouseComposedArrow; - return; } -- cgit v1.2.3