Page 1 of 2

How to refresh a hidden skin

Posted: March 14th, 2018, 12:28 am
by chabango
Hi,
I have a skin that I am using as a notification "pop up" to users that is pulling form a TXT file now for Proof of Concept(will eventually be RSS feed)
I have it configured so that the user can click on it to hide it.
My issue is trying to have the hidden skin continue to check for changes to the source file even if it is hidden.
For example, i want to be able to update the source file, have the hidden skin pick up the change and popup to display the text.
Anyone have any good ideas?
Thanks

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 9:50 am
by fonpaolo
First of all, if you add the "check" icon to your post, it will tell that the problem is solved.

Second, if a skin is hidden, it means that it's still loaded but non visible, doesn't mean that the skin isn't running only because it's hidden.
So, if it's really hidden, leave it as is, it will be updated accordingly to your Update rate.
If you mean that the skin is Unloaded, then, you can't update something that isn't even loaded.

I hope I was clear, in this case the correct terminology is essential. ;-)

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 11:34 am
by chabango
Update is set to 1000 but even if I lower it, the skin does not update wit the new text if it has been hidden.

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 12:18 pm
by balala
Please post the code you have so far OR if the skin uses some included files (.inc files, images), pack the whole config and upload it, to can take a look.

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 12:22 pm
by fonpaolo
Not knowing how you made the skin, probably there's an error or some commands blocking the whole skin or some measures from updating.
I can assure you, in no way, hiding a skin you'll have a side effect causing a block to the update of your skin, because I'm using a lot of hidden skins, believe me. ;-)

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 12:26 pm
by chabango

Code: Select all

[Rainmeter]
Update=1000
AccurateText=1
DynamicWindowSize=1
BackgroundMode=2
SolidColor=60,60,60,255
OnRefreshAction=[!Move (#SCREENAREAWIDTH#/2)-100 (#SCREENAREAHEIGHT#/2)-50]


[Variables]
Notespath=C:\rainmeter\tempfile.txt


[measureNotes]
Measure=Plugin
Plugin=QuotePlugin
PathName="#Notespath#"
Separator=ΒΆ
OnChangeAction=[!UpdateMeter "MeterNotes"][!Redraw]

[meterTitle]
Meter=STRING
MeterStyle=styleTitle
FontColor=255,51,51
FontSize=15
Text="**** OCIO Notification Message ****"
;ToolTipTitle="Click to Remove"
;ToolTipType=1
;ToolTipIcon=INFO
;ToolTipText="Mouse click to remove"
;LeftMouseUpAction=[!Hide "#CurrentConfig#"]


[meterNotes]
Meter=String
MeterStyle=styleLeftText
FontColor=255,255,255
FontSize=15
MeterStyle=styleLeftText
w=400
y=40

Text="[measureNotes]"
UpdateDivider=-10
DynamicVariables=1
ClipString=2
AntiAlias=1
ToolTipTitle="Click to Remove"
ToolTipType=1
ToolTipIcon=INFO
ToolTipText="Mouse click to remove"
LeftMouseUpAction=[!Hide "#CurrentConfig#"]

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 2:44 pm
by balala
Let's clarify something first, because for me it is not clear at all: chabango what are you talking about, updating or to refreshing your skin? Because these are completely different things. If you're talking about updating it, there is nothing to discus about, because the skin is updating automatically on each update cycle, so once per second (due to the Update=1000 option set up in the [Rainmeter] section). If you're talking about refreshing the skin, it is possible, but a refreshed skin is reloaded again, everything being rebuilt.
So, for me at least for now isn't clear at all what you would like. Please give us some details, because as I see, neither fonpaolo didn't understand your request (right fonpaolo?).

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 3:01 pm
by chabango
Sorry, I hope this helps clarify.
The skin displays a message from a source file. If The user clicks on the skin to hide it, once it is hidden, the skin does not "unhide" if the source message changes. If the message changes in the source , the skin remains hidden and does not display the new message to the user.

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 3:07 pm
by fonpaolo
Yes balala, you're right.
For what I can understand, chabango, maybe you may have some confusion on Rainmeter's terminology, or maybe you're trying to obtain something but not in the "right way".

As is, as balala said, the skin is updating regularly, even if, for me, once a second is too often.
I don't see, once you've hidden the skin, how you can make it visible again... probably using a command in another skin or the code posted is only a part of it?

UpdateDivider=-10 means nothing...
UpdateDivider=-1 means never update;
UpdateDivider=10 means after 10 seconds (1 second x 10).

Re: How to refresh a hidden skin

Posted: March 14th, 2018, 3:11 pm
by fonpaolo
chabango wrote:Sorry, I hope this helps clarify.
The skin displays a message from a source file. If The user clicks on the skin to hide it, once it is hidden, the skin does not "unhide" if the source message changes. If the message changes in the source , the skin remains hidden and does not display the new message to the user.
If you want to show the skin, once the quote is updated (please read the post above), you can add to your [measureNotes]:

Code: Select all

OnChangeAction=[!Show "#CurrentConfig#"][!UpdateMeter "MeterNotes"][!Redraw]