diff --git a/examples/pwfb/pwfb_events.c b/examples/pwfb/pwfb_events.c index 0dcdfbafd8..6f4441ccf0 100644 --- a/examples/pwfb/pwfb_events.c +++ b/examples/pwfb/pwfb_events.c @@ -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) " diff --git a/examples/pwfb/pwfb_internal.h b/examples/pwfb/pwfb_internal.h index c29e2da8d5..8882009e53 100644 --- a/examples/pwfb/pwfb_internal.h +++ b/examples/pwfb/pwfb_internal.h @@ -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 diff --git a/examples/pwfb/pwfb_motion.c b/examples/pwfb/pwfb_motion.c index b2578ab121..a44cae4ffc 100644 --- a/examples/pwfb/pwfb_motion.c +++ b/examples/pwfb/pwfb_motion.c @@ -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 */