Hi everyone,
I have a card with a group that I scroll to reveal content. The performance is really fast and really good.... except that I seem to have to leave the card and then come back. When it initially sets, its sluggish and slow.
I've been trying to hunt down the cause of this, as far as I can tell..... it happens when I use a setprop handler that changes the properties of many many things on the card. When I leave and come back to the card, it works well.
If at the end of the setprop handler I add
lock screen
go to different card
go to original card
unlock screen
then the performance problem is gone. The layer mode of the scrolling group is set to "Dynamic"....(dynamic vs. scrolling gives very similar performance)
I'm just not sure I want to use such a workaround.
Any idea what could be the problem?
Thanks....
Strange Scrolling performance and even stranger fix
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Strange Scrolling performance and even stranger fix
Founder & Developer @ MakeShyft R.D.A - https://www.makeshyft.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
-
- VIP Livecode Opensource Backer
- Posts: 10052
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: Strange Scrolling performance and even stranger fix
It may be helpful to see the full handler in which that code resides, if possible. Also, it's not clear to me which is new, the "lock screen" or going to another card.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: Strange Scrolling performance and even stranger fix
Hi Richard,
the whole thing
lock screen
lock messages
go to different card
go to original card
unlock messages
unlock screen
is at the end of the handler and that solves the problem.
The problem is the handler is one that goes through every control of the group and changes its properties ...(enable/disable buttons, change colors, etc).....so its really long and only contains calls to other handlers. ... like so....
Basically..... this handler sends a message to a group and then goes through all its controls and sets properties. There are about
13 of these groups inside the one main one that I scroll.
Thanks Richard.
the whole thing
lock screen
lock messages
go to different card
go to original card
unlock messages
unlock screen
is at the end of the handler and that solves the problem.
The problem is the handler is one that goes through every control of the group and changes its properties ...(enable/disable buttons, change colors, etc).....so its really long and only contains calls to other handlers. ... like so....
Code: Select all
else if SetUIStateTo is "UMP File Open" then
lock screen
EnableDisableControls "User Interface","Enabled","User Interface"
EnableDisableControls "W_GENERAL","Enabled","CC", "W_New User","W_Sign In"
EnableDisableControls "W_FILE ACTIONS","Enabled","CC", "W_Open UMP File","W_New UMP File","W_Open Invitation"
//EnableDisableControls "W_PVFA","Enabled","CC"
EnableDisableControls "W_QUESTIONS","Enabled","CC"
EnableDisableControls "W_STATEMENTS","Enabled","CC"
EnableDisableControls "W_RESPONSES","Enabled","CC"
EnableDisableControls "W_TAGS","Enabled","CC"
EnableDisableControls "W_CONNECTIONS","Enabled","CC"
EnableDisableControls "W_TRASHCAN","Enabled","CC"
EnableDisableControls "W_AGREEMENTS","Enabled","CC"
EnableDisableControls "W_FACILITATORS","Enabled","CC"
EnableDisableControls "W_ADMINISTRATORS","Enabled","CC"
the code for the handler being called is .....
[code]on EnableDisableControls WhatGroupToSendTo,WhatStateYouWant,WhatGroupReference
local parameters_to_send
put "EnableDisableMe " & quote & WhatStateYouWant & quote & comma & quote & WhatGroupReference & quote into parameters_to_send
if the paramcount <= 3 then
// No exceptions
else
// Cycle through Exceptions & add to message to send
repeat with exception = 4 to the paramcount
put comma & quote & param(exception) & quote after parameters_to_send
end repeat
end if
send parameters_to_send to group WhatGroupToSendTo
end EnableDisableControls
13 of these groups inside the one main one that I scroll.
Thanks Richard.
Founder & Developer @ MakeShyft R.D.A - https://www.makeshyft.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Re: Strange Scrolling performance and even stranger fix
I think I will just use this workaround for now..... this is probably not something that can be diagnosed without looking at the full stack. Thanks for efforts.
Founder & Developer @ MakeShyft R.D.A - https://www.makeshyft.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Re: Strange Scrolling performance and even stranger fix
Whats even more weird is that the performance seems to improve each time that i leave and come back to the card.....SO WEIRD!!!
Founder & Developer @ MakeShyft R.D.A - https://www.makeshyft.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com
Build Software with AppStarterStack for Livecode - https://www.AppStarterStack.com
Save Time with The Time Saver's Toolbox - https://www.TimeSaversToolbox.com