It is currently May 17th, 2024, 5:15 am
Get help with creating, editing & fixing problems with skins
hmmka
Posts: 4 Joined: March 18th, 2010, 1:40 pm
Post
by hmmka » October 7th, 2010, 10:55 am
hi
my skins contains a shutodwn, a restart and a standbybutton.
is there any possibility to get a confirmation dialogue before the shutdown/restart/standby is going to be executed??
would help against accidental clicking it
Code: Select all
[MeterShutdown]
Meter=STRING
X=23
Y=71
FontColor=#WhiteColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=0
MouseOverAction=!Execute [!RainmeterShowMeter MeterShutdownH][!RainmeterRedraw]
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
[MeterShutdownH]
Meter=STRING
X=r
Y=r
FontColor=#TurquoiseColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=1
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
LeftMouseDownAction=!Execute [#Shutdown#]
Dave_W
Posts: 37 Joined: April 20th, 2009, 10:58 am
Post
by Dave_W » October 7th, 2010, 11:38 am
There might be a neater way to do it, but the obvious idea to me is instead of having the button execute the shutdown, have it launch another config that is (basically) an "Are you sure?" textbox - if you click THAT then it shuts down. If you wanted to get flash, you could put a button on that meter to click.
So like this:
Code: Select all
[MeterShutdown]
Meter=STRING
X=23
Y=71
FontColor=#WhiteColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=0
MouseOverAction=!Execute [!RainmeterShowMeter MeterShutdownH][!RainmeterRedraw]
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
[MeterShutdownH]
Meter=STRING
X=r
Y=r
FontColor=#TurquoiseColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=1
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
LeftMouseDownAction=!Execute [!RainmeterShowMeter MeterShutdownConfirm][!RainmeterRedraw]
[MeterShutdownConfirm]
Meter=STRING
X=r
Y=r
FontColor=#TurquoiseColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Text="Are you sure you want to shut down?"
Solidcolor=0,0,0,2
Hidden=1
RightMouseDoubleClickAction=!Execute [!RainmeterHideMeter MeterShutdownConfirm][!RainmeterRedraw]
LeftMouseDownAction=!Execute [#Shutdown#]
hmmka
Posts: 4 Joined: March 18th, 2010, 1:40 pm
Post
by hmmka » October 7th, 2010, 12:47 pm
yeah very nice idea!
i'll try to implement this tonight
hmmka
Posts: 4 Joined: March 18th, 2010, 1:40 pm
Post
by hmmka » October 7th, 2010, 5:10 pm
it works very nice now
made even one more meter to confirmation:
Code: Select all
[MeterShutdown]
Meter=STRING
X=23
Y=71
FontColor=#WhiteColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=0
MouseOverAction=!Execute [!RainmeterShowMeter MeterShutdownH][!RainmeterRedraw]
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
[MeterShutdownH]
Meter=STRING
X=r
Y=r
FontColor=#TurquoiseColor#
FontSize=#Size2#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Postfix="Shutdown"
Hidden=1
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownH][!RainmeterRedraw]
LeftMouseDownAction=!Execute [!RainmeterShowMeter MeterShutdownConfirm][!RainmeterHideMeter Metersd][!RainmeterHideMeter Metershutdown][!RainmeterHideMeter Meterrestart][!RainmeterHideMeter Meterstandby][!RainmeterHideMeter Meterrs][!RainmeterHideMeter Metersb][!RainmeterRedraw]
[MeterShutdownConfirm]
Meter=STRING
X=45
Y=30
FontColor=#WhiteColor#
FontSize=#Size4#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Text="Are you sure?"
Solidcolor=0,0,0,2
Hidden=1
MouseOverAction=!Execute [!RainmeterShowMeter MeterShutdownConfirm2][!RainmeterRedraw]
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownConfirm2][!RainmeterRedraw]
[MeterShutdownConfirm2]
Meter=STRING
X=45
Y=30
FontColor=#TurquoiseColor#
FontSize=#Size4#
FontFace=#Font2#
StringAlign=Left
StringStyle=italic
AntiAlias=1
Text="Are you sure?"
Solidcolor=0,0,0,2
Hidden=1
RightMouseDoubleClickAction=!Execute [!RainmeterHideMeter MeterShutdownConfirm][!RainmeterShowMeter MeterSd][!RainmeterShowMeter Meterrs][!RainmeterShowMeter MeterSb][!RainmeterShowMeter Metershutdown][!RainmeterShowMeter Meterrestart][!RainmeterShowMeter Meterstandby][!RainmeterRedraw]
LeftMouseDownAction=!Execute [#Shutdown#]
MouseOverAction=!Execute [!RainmeterShowMeter MeterShutdownConfirm2][!RainmeterRedraw]
MouseLeaveAction=!Execute [!RainmeterHideMeter MeterShutdownConfirm2][!RainmeterRedraw]
Dave_W
Posts: 37 Joined: April 20th, 2009, 10:58 am
Post
by Dave_W » October 8th, 2010, 8:26 am
Nice, man.
So the idea with the third/fourth meter is that you get a highlight on mouseover, essentially? That's pretty cool.
Glad to help.
hmmka
Posts: 4 Joined: March 18th, 2010, 1:40 pm
Post
by hmmka » October 14th, 2010, 9:38 pm
Dave_W wrote: Nice, man.
thx
Dave_W wrote:
So the idea with the third/fourth meter is that you get a highlight on mouseover, essentially? That's pretty cool.
Glad to help.
yep thats all what it is supposed to do.
here are some screenshots (shutdown meter in bottom right corner) :
1. [MeterShutdown]
2. [MeterShutdownH] (makes the mouseover effect for shutdown/restart/standby
3. [MeterShutdownConfirm] (shows the "are you sure?" question)
4. [MeterShutdownConfirm2] (makes the mouseover effect for the "are you sure?" question