Mend scroll-down arrow bug Stamps selector...

...when stamp controls were disabled.
This commit is contained in:
Bill Kendrick 2023-10-13 23:18:00 -07:00
parent ae9df2d294
commit e43c506d20
2 changed files with 13 additions and 13 deletions

View file

@ -6,13 +6,19 @@ Copyright (c) 2002-2023
Various contributors (see below, and AUTHORS.txt)
https://tuxpaint.org/
2023.October.5 (0.9.32)
2023.October.13 (0.9.32)
* Other Improvements:
-------------------
* Simplify macOS building by signing macOS app bundle anonymously by
default.
Mark Kim <markuskimius@gmail.com>
* Bug Fixes:
----------
* Corrected bug in how scroll-down arrow appeared in Stamps selector
when stamp controls were disabled.
Bill Kendrick <bill@newbreedsoftware.com>
* Localization Updates:
---------------------
* Bulgarian

View file

@ -22,7 +22,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
(See COPYING.txt)
June 14, 2002 - July 19, 2023
June 14, 2002 - October 13, 2023
*/
#include "platform.h"
@ -10818,18 +10818,16 @@ static void draw_stamps(void)
{
if (!no_stamp_rotation)
{
most =
(buttons_tall * gd_toolopt.cols) - gd_toolopt.cols - gd_toolopt.cols - gd_toolopt.cols - gd_toolopt.cols -
TOOLOFFSET;
most = ((buttons_tall - 4) * gd_toolopt.cols) - TOOLOFFSET;
}
else
{
most = (buttons_tall * gd_toolopt.cols) - gd_toolopt.cols - gd_toolopt.cols - gd_toolopt.cols - TOOLOFFSET;
most = ((buttons_tall - 3) * gd_toolopt.cols) - TOOLOFFSET;
}
}
else
{
most = (buttons_tall * gd_toolopt.cols) - gd_toolopt.cols - TOOLOFFSET;
most = ((buttons_tall - 1) * gd_toolopt.cols) - TOOLOFFSET;
}
@ -10856,13 +10854,9 @@ static void draw_stamps(void)
dest.x = WINDOW_WIDTH - r_ttoolopt.w;
dest.y = r_ttoolopt.h + off_y + (((most + 2) / gd_toolopt.cols + TOOLOFFSET / gd_toolopt.cols) * button_h);
if (!disable_stamp_controls)
{
dest.y -= (button_h * 2);
}
dest.y = r_ttoolopt.h + off_y + ((((most + TOOLOFFSET) / gd_toolopt.cols) - 1) * button_h);
dest.x = WINDOW_WIDTH - r_ttoolopt.w;
if (stamp_scroll[stamp_group] < num_stamps[stamp_group] - (most - 2) - TOOLOFFSET)
{
SDL_BlitSurface(img_scroll_down, NULL, screen, &dest);