It is currently April 19th, 2024, 10:33 pm

Shutdown Skin

Skins to open folders and launch applications and websites
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Shutdown Skin

Post by jsmorley »

Here is another little "shutdown" skin, designed for Windows 8.1

There are a lot of power skins out there, and this doesn't do anything special, but I wanted a single place to keep all the common command line options for Windows to restart / shutdown / sleep / logoff / lock the computer.

Windows 8 added a new "hybrid shutdown" as the default. This "hibernates" the Windows system kernel, while shutting down the "user" session. This will make the computer start up orders of magnitude faster than the old "full shutdown", however there may be times when you want Windows to fully reinitialize all hardware. I have added buttons for both.
ShutdownSkin_1.0.rmskin
test.gif
The commands are:

Restart: shutdown -r -t 00
Hybrid Shutdown: shutdown -s -hybrid -f -t 00
Full Shutdown: shutdown -s -f -t 00
Sleep: rundll32.exe PowrProf.dll,SetSuspendState 0,1,0
Logoff User: shutdown -l
Lock Workstation: rundll32.exe User32.dll,LockWorkStation

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
MouseLeaveAction=[!SetOptionGroup Meters ImageAlpha "255"][!SetOption MeterTitle Text "Select Power Option"][!UpdateMeter *][!Redraw]

[Metadata]
Name=ShutdownSkin
Author=JSMorley
Version=May 17, 2014
License=Creative Commons Attribution-Non-Commercial-Share Alike 3.0
Information=Shutdown buttons||Full Shutdown / Hybrid Shutdown / Restart / Sleep / Logoff / Lock||Double-Click to execute

[MeterBack]
Meter=Image
W=206
H=36
SolidColor=50,50,50,255

[MeterRestart]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownRestart.png
X=2
Y=2
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Restart Computer"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[shutdown.exe -r -t 00]

[MeterHybrid]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownHybrid.png
X=2R
Y=0r
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Hybrid Shutdown"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[shutdown.exe -s -hybrid -f -t 00]

[MeterFull]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownFull.png
X=2R
Y=0r
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Full Shutdown"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[shutdown -s -f -t 00]

[MeterSleep]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownSleep.png
X=2R
Y=0r
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Sleep Computer"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[rundll32.exe PowrProf.dll,SetSuspendState 0,1,0]

[MeterLogoff]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownLogoff.png
X=2R
Y=0r
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Logoff User"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[shutdown -l]

[MeterLock]
Meter=Image
Group=Meters
ImageName=#@#Images\ShutdownLock.png
X=2R
Y=0r
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "140"][!SetOption #CURRENTSECTION# ImageAlpha "255"][!SetOption MeterTitle Text "Lock Computer"][!UpdateMeter *][!Redraw]
LeftMouseDoubleClickAction=[rundll32.exe User32.dll,LockWorkStation]

[MeterTitle]
Meter=String
X=0
Y=2R
W=202
H=17
FontSize=11
FontColor=255,255,255,255
SolidColor=50,50,50,255
Padding=4,2,0,2
AntiAlias=1
Text=Select Power Option
MouseOverAction=[!SetOptionGroup Meters ImageAlpha "255"][!SetOption MeterTitle Text "Select Power Option"][!UpdateMeter *][!Redraw]
You do not have the required permissions to view the files attached to this post.
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Shutdown Skin

Post by jsmorley »

I wasn't entirely happy with the mouseover / mouseleave transitions, so I reworked that part a little.
User avatar
ikarus1969
Posts: 571
Joined: February 28th, 2011, 3:20 pm
Location: Vienna, Austria

Re: Shutdown Skin

Post by ikarus1969 »

Hi jsmorley!

thank you for posting this skin - i took the code and adapted it for my needs. :bow:

Here's a screenshot - if i ever should publish some of my other skins with that included i will credit you of course!
Screenshot Shutdown skin adapted.png
You do not have the required permissions to view the files attached to this post.
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Shutdown Skin

Post by jsmorley »

Looks nice...
User avatar
fonpaolo
Moderator
Posts: 1387
Joined: April 11th, 2013, 8:08 pm
Location: Italy

Re: Shutdown Skin

Post by fonpaolo »

Sorry to resurrect an old discussion, however...
I'm planning to update my shutdown skin and with the release of Windows 10 (that I haven't yet installed).
I want to ask if there are differences from Windows 8+ or not.

Thanks.
User avatar
fonpaolo
Moderator
Posts: 1387
Joined: April 11th, 2013, 8:08 pm
Location: Italy

Re: Shutdown Skin

Post by fonpaolo »

I would also know if in Windows 10 there are "switch user", "hibernation", "sleep/standby"(*) and if they use the same (old) commands.

Then, for "lock" I use:

Code: Select all

%windir%\System32\tsdiscon.exe
...but I see that you use:

Code: Select all

[rundll32.exe User32.dll,LockWorkStation]
There may be problems using my command?
(I know that for the "basic" editions, that executable has to be manually downloaded)

(*) I know that if hibernation is used the "sleep" mode ends always in hibernation, but there's a workaround.
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Shutdown Skin

Post by jsmorley »

That %windir%\System32\tsdiscon.exe works ok I guess, but does all kinds of screen flashing and is kinda ugly. rundll32.exe User32.dll,LockWorkStation works much better for me.

I don't know about hibernate or sleep. I really never use hibernate, and sleep always crashes my system when it wakes up. Always has, Win7, Win8, Win10.

But in any case, all the commands in my skin work exactly the same for me in Win10 as they did in Win8.
User avatar
fonpaolo
Moderator
Posts: 1387
Joined: April 11th, 2013, 8:08 pm
Location: Italy

Re: Shutdown Skin

Post by fonpaolo »

Thanks jsmorley for the reply. :D

At the moment I can't really test a lot of different Operating Systems, so I have to rely to Windows forums (at the moment, there isn't much for 10) and to current Windows 10 experienced users.

I'll use your solution for lock, even if I have no problems, however, this will eliminate the problem for the users of the basic editions to download and copy the missing file.

I use hibernation, not so much, but sometimes leave the computer on and go away for some time isn't a practical solution for me.
I never use sleep, mainly because having hibernation enabled, sleep doesn't work, but I have found a solution which avoids any change on system settings (as disable hibernation, set it to sleep and then enable hibernation again) and because most of the other solutions I found, may cause more damages than benefits.
(If I'll never use a similar solution for me, let alone if I'll do that for all the users of my skins.)

...and for once, I'm lucky: never had a problem with hibernation or sleep on any computer I used, but I also know it's very difficult to have them work well with some hardware configurations.
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Shutdown Skin

Post by jsmorley »

Yeah, as long as "sleep" is really "hibernate" it works fine on my system, although I really never use it. If it set to be actually "sleep", something about my hardware or software (more likely software) really hates it and the system is unstable when it "wakes up".
User avatar
fonpaolo
Moderator
Posts: 1387
Joined: April 11th, 2013, 8:08 pm
Location: Italy

Re: Shutdown Skin

Post by fonpaolo »

Yes, exactly, I still have to test that "solution" on some other systems, but the first results are already promising.

For my (limited) experience, more than from the software, the problems are related to some drivers or particular hardware (more than once I had to tell to the hardware dealer that the pieces he was trying to sell were not very compatible with each other...)

Only once I had some problems and then I realized they were related to the video card.
If the problems were caused by hardware or drivers, I don't know, but when I changed it with another, sleep has started to work again.