Skip to content

Commit

Permalink
Switch to int32 for marquee text timer
Browse files Browse the repository at this point in the history
  • Loading branch information
dylwhich committed Aug 24, 2024
1 parent 9df67ab commit b24ddab
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion main/display/font.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ void makeOutlineFont(font_t* srcFont, font_t* dstFont, bool spiRam)
* @return The x offset at the end of the drawn string
*/
int16_t drawTextMarquee(const font_t* font, paletteColor_t color, const char* text, int16_t xOff, int16_t yOff,
int16_t xMax, int64_t* timer)
int16_t xMax, int32_t* timer)
{
// Marquee speed in microseconds per pixel
#define MARQUEE_SPEED 40000
Expand Down
2 changes: 1 addition & 1 deletion main/display/font.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ uint16_t textWordWrapHeight(const font_t* font, const char* text, int16_t width,

void makeOutlineFont(font_t* srcFont, font_t* dstFont, bool spiRam);
int16_t drawTextMarquee(const font_t* font, paletteColor_t color, const char* text, int16_t xOff, int16_t yOff,
int16_t xMax, int64_t* timer);
int16_t xMax, int32_t* timer);
bool drawTextEllipsize(const font_t* font, paletteColor_t color, const char* text, int16_t xOff, int16_t yOff,
int16_t maxW, bool center);

Expand Down
2 changes: 1 addition & 1 deletion main/menu/menuManiaRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ typedef struct
int16_t selectedBounceIdx; ///< The index to the bounce offset for the selected item
int32_t selectedBounceTimer; ///< The timer to bounce the offset for the selected item
int32_t selectedValue; ///< The option index or setting value to tell when it changes
int64_t selectedMarqueeTimer; ///< The timer for marquee-ing the selected item text, if too long to fit
int32_t selectedMarqueeTimer; ///< The timer for marquee-ing the selected item text, if too long to fit
} menuManiaRenderer_t;

menuManiaRenderer_t* initMenuManiaRenderer(font_t* titleFont, font_t* titleFontOutline, font_t* menuFont);
Expand Down
2 changes: 1 addition & 1 deletion main/modes/music/usbsynth/mode_synth.c
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ typedef struct
synthConfig_t synthConfig;
list_t controllerSettings;

int64_t marqueeTimer;
int32_t marqueeTimer;
} synthData_t;

//==============================================================================
Expand Down
2 changes: 1 addition & 1 deletion main/utils/wheel_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ typedef struct
bool zoomed; ///< Whether or not a settings item is selected
bool zoomBackSelected; ///< Whether or not the center is selected while zoomed
uint8_t zoomValue; ///< The current selected option/value if zoomed
int64_t timer; ///< The timer for animations
int32_t timer; ///< The timer for animations
} wheelMenuRenderer_t;

wheelMenuRenderer_t* initWheelMenu(const font_t* font, uint16_t anchorAngle, const rectangle_t* textBox);
Expand Down

0 comments on commit b24ddab

Please sign in to comment.