20 Nov 2019 - TVDB Scraper v3.2.0 is now available which reinstates scraping. TVDB are still in the process of fixing a number of bugs so there may still be further breakages. See this post. 2901570 (post)

onunload ClearProperty() not working?
#1
I am currently modding DialogMusicInfo from one of the Titan Skins.
Now i am facing some strange behavior and I don't know why (possible bug?)

I have
<onunload>ClearProperty(AdditionalInfo)</onunload>
at the beginning of the file, which should clear Additional Infos. This property is used to control various other stuff. I checked that this property is working, as there is a button which actually clears the Additional Infos.

Also if i execute it onload instead of onunload it will clear everything. This will do as workaround, but since the whole skin does similar things all over the place, i was wondering, if i am doing something wrong, or if onunload with ClearProperty() actually isn't working?
onunload does work with other stuff, like Notification().
Reply
#2
Have you tried adding the window ID that was used to set the property?
Reply
#3
I tried with
<onunload>ClearProperty(AdditionalInfo, 12001)</onunload>
which worked for album and artist indeed, but for songs there is a different id, which i would have to pass.
Also, as i said, it does work for onload, here everything seems to be cleared. Definitely not the behavior i would expect (for onunload)
Reply
#4
It's a race condition. The window is unloaded before the property of the window gets cleared. 

try adding:
Code:
<animation effect="fade" start="100" end="0" time="1" delay="50">WindowClose</animation>

That should give you a small buffer.
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
 
Thread Rating:
  • 0 Vote(s) - 0 Average



Logout Mark Read Team Forum Stats Members Help
onunload ClearProperty() not working?00