GLBasic forum

Codesnippets => DD-GUI => Topic started by: MrTAToad on 2010-Aug-13

Title: Odd - CLICKED value doesn't always reset
Post by: MrTAToad on 2010-Aug-13
For some reason, the following is always being executed :

Code (glbasic) Select
IF DDgui_get(self.LIST_STRINGS$,"CLICKED")
DEBUG "hh\n"
self.selectedLine%=DDgui_get(self.LIST_STRINGS$,"SELECT")
IF self.selectedLine%>=0
DEBUG self.selectedLine%+"\n"
DDgui_set(self.TEXT_STRINGETEXT$,"TEXT",self.strings[self.stringIndex%].lines[self.selectedLine%].name$)
self.TStringEntry_EnableDisplayEntryArea(self.selectedLine%)
ENDIF


LIST_STRING$ is only pressed once, but for some reason CLICKED always returns TRUE

Now, EnableDisplayEntryArea is this :

Code (glbasic) Select
FUNCTION TStringEntry_EnableDisplayEntryArea%:selectedLine%
IF selectedLine%=self.INVALID%
DDgui_set(self.LIST_STRINGS$,"READONLY",FALSE)
DDgui_set(self.TEXT_STRINGETEXT$,"READONLY",TRUE)
DDgui_set(self.BUTTON_UPDATE$,"READONLY",TRUE)
ELSE
DDgui_set(self.LIST_STRINGS$,"READONLY",TRUE)
DDgui_set(self.TEXT_STRINGETEXT$,"READONLY",FALSE)
DDgui_set(self.BUTTON_UPDATE$,"READONLY",FALSE)
ENDIF
ENDFUNCTION


Is it possible that SELECT is setting CLICKED ?

Aside from that the DDGui update seems okay...  :good:
Title: Re: Odd
Post by: Schranz0r on 2010-Aug-13
pls select a subject that match your post... (better for the searchfunction of this forum ;) )

I can't help you with your problem, never used DDGUI  :x
Title: Re: Odd - CLICKED value doesn't always reset
Post by: MrTAToad on 2010-Aug-14
I couldn't think of anything better at the time...  :S
Title: Re: Odd - CLICKED value doesn't always reset
Post by: Kitty Hello on 2010-Aug-17
if the selection of a list changes, a CLICKED will be triggered, yes.
Title: Re: Odd - CLICKED value doesn't always reset
Post by: MrTAToad on 2010-Aug-17
I think that must be the cause then...