From c569e5c35837c8612ac8cca0bafa0301ddc4d0d0 Mon Sep 17 00:00:00 2001 From: ehouse Date: Sun, 14 Nov 2004 16:06:30 +0000 Subject: [PATCH] add HintAtts param to draw_drawBoardArrow --- common/board.c | 12 +++++++----- common/draw.h | 7 ++++--- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/common/board.c b/common/board.c index 5bf151906..429d3d224 100644 --- a/common/board.c +++ b/common/board.c @@ -1013,15 +1013,17 @@ board_draw( BoardCtxt* board ) BoardArrow* arrow = &board->boardArrow[board->selPlayer]; if ( arrow->visible ) { + XP_U16 col = arrow->col; + XP_U16 row = arrow->row; XP_Bool drawVertical = (arrow->vert == XP_CURSOR_KEY_DOWN) ^ board->isFlipped; - if ( getCellRect( board, arrow->col, arrow->row, - &cursorRect ) ) { + if ( getCellRect( board, col, row, &cursorRect ) ) { XWBonusType bonus; - bonus = util_getSquareBonus( board->util, model, arrow->col, - arrow->row ); + HintAtts hintAtts; + bonus = util_getSquareBonus( board->util, model, col, row ); + hintAtts = figureHintAtts( board, col, row ); draw_drawBoardArrow( board->draw, &cursorRect, - bonus, drawVertical ); + bonus, drawVertical, hintAtts ); } } #ifdef KEYBOARD_NAV diff --git a/common/draw.h b/common/draw.h index b4e3caa0d..2d765c852 100644 --- a/common/draw.h +++ b/common/draw.h @@ -119,7 +119,8 @@ typedef struct DrawCtxVTable { void (*m_draw_clearRect)( DrawCtx* dctx, XP_Rect* rect ); void (*m_draw_drawBoardArrow)( DrawCtx* dctx, XP_Rect* rect, - XWBonusType bonus, XP_Bool vert ); + XWBonusType bonus, XP_Bool vert, + HintAtts hintAtts ); #ifdef KEY_SUPPORT void (*m_draw_drawTrayCursor)( DrawCtx* dctx, XP_Rect* rect ); void (*m_draw_drawBoardCursor)( DrawCtx* dctx, XP_Rect* rect ); @@ -201,8 +202,8 @@ struct DrawCtx { #define draw_clearRect( dc, rect ) (dc)->vtable->m_draw_clearRect((dc),(rect)) -#define draw_drawBoardArrow( dc, r, b, v ) \ - (dc)->vtable->m_draw_drawBoardArrow((dc),(r),(b), (v)) +#define draw_drawBoardArrow( dc, r, b, v, h ) \ + (dc)->vtable->m_draw_drawBoardArrow((dc),(r),(b), (v), (h)) #ifdef KEY_SUPPORT # define draw_drawTrayCursor( dc, r ) \ (dc)->vtable->m_draw_drawTrayCursor((dc),(r))