apps/examples/pwfb : fix compiling error
fix compiling warning and error when CONFIG_NX=y, EXAMPLES_PWFB=y and EXAMPLES_PWFB_DEFAULT_FONT=y fix CI-Precheck for pwfb_motion.c Signed-off-by: YanXiaowei <yanxiaowei@xiaomi.com>
This commit is contained in:
parent
79a111fc1a
commit
b2d5d3f51c
@ -170,8 +170,6 @@ static void pwfb_tb_position(NXTKWINDOW hwnd,
|
||||
FAR void *arg)
|
||||
{
|
||||
#ifdef CONFIG_EXAMPLES_PWFB_VERBOSE
|
||||
FAR struct nxeg_state_s *st = (FAR struct nxeg_state_s *)arg;
|
||||
|
||||
/* Report the position */
|
||||
|
||||
printf("pwfb_tb_position: hwnd=%p size=(%d,%d) pos=(%d,%d) "
|
||||
|
@ -114,12 +114,12 @@
|
||||
|
||||
#ifndef CONFIG_EXAMPLES_PWFB_COLOR3
|
||||
# if CONFIG_EXAMPLES_PWFB_BPP == 24 || CONFIG_EXAMPLES_PWFB_BPP == 32
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR2 0x00ffecb3
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR3 0x00ffecb3
|
||||
# elif CONFIG_EXAMPLES_PWFB_BPP == 16
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR2 0xff76
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR3 0xff76
|
||||
# else
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR2 '3'
|
||||
# endif
|
||||
# define CONFIG_EXAMPLES_PWFB_COLOR3 '3'
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_EXAMPLES_PWFB_TBCOLOR
|
||||
@ -142,6 +142,10 @@
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_EXAMPLES_PWFB_DEFAULT_FONT
|
||||
# define CONFIG_EXAMPLES_PWFB_FONTID FONTID_DEFAULT
|
||||
#endif
|
||||
|
||||
/* Cursor timing */
|
||||
|
||||
#if CONFIG_EXAMPLES_PWFB_RATECONTROL > 0
|
||||
|
@ -177,7 +177,7 @@ static inline bool pwfb_move_cursor(FAR struct pwfb_state_s *st)
|
||||
#ifdef CONFIG_EXAMPLES_PWFB_VERBOSE
|
||||
printf("pwfb_move_cursor: State: %u countdown: %u blinktime: %u\n",
|
||||
(unsigned int)st->cursor.state, (unsigned int)st->cursor.countdown,
|
||||
(unsigned int)st->cursor.blinktime;
|
||||
(unsigned int)st->cursor.blinktime);
|
||||
printf("pwfb_move_cursor: Velocity: (%lx.%04lx,%lx.%04lx)\n",
|
||||
(unsigned long)st->cursor.deltax >> 16,
|
||||
(unsigned long)st->cursor.deltax & 0xffff,
|
||||
@ -186,12 +186,13 @@ static inline bool pwfb_move_cursor(FAR struct pwfb_state_s *st)
|
||||
#endif
|
||||
|
||||
/* Handle the update based on cursor state */
|
||||
|
||||
/* If the state is not PFWB_CURSOR_STATIONARY, then update the cursor
|
||||
* position.
|
||||
*/
|
||||
|
||||
if (st->cursor.state != PFWB_CURSOR_STATIONARY)
|
||||
{
|
||||
if (st->cursor.state != PFWB_CURSOR_STATIONARY)
|
||||
{
|
||||
/* Update X position */
|
||||
|
||||
newx = st->cursor.xpos + st->cursor.deltax;
|
||||
@ -258,7 +259,7 @@ static inline bool pwfb_move_cursor(FAR struct pwfb_state_s *st)
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Check for state changes */
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user