From 3c35f4cc8a61d34198943dc48a0374a21ad0e3fb Mon Sep 17 00:00:00 2001 From: visionmercer <62051836+visionmercer@users.noreply.github.com> Date: Wed, 20 May 2026 11:30:31 +0200 Subject: [PATCH] A bit smarter image handling. --- pixler.bas | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pixler.bas b/pixler.bas index fb4f35a..d1ad632 100644 --- a/pixler.bas +++ b/pixler.bas @@ -325,8 +325,8 @@ sub toolbox end sub sub colorpicker - dim img as long - img=_newimage(16,16,32) + static img as long + if img=0 then img=_newimage(16,16,32) for i=0 to ubound(pal) _dest img cls,pal(i) @@ -341,7 +341,6 @@ sub colorpicker addcommand"bcolor ("+hex$(pal(i))+")" end select next i - _freeimage img end sub sub addcommand(cmd as string)