fixed bugs related to issue #95

This commit is contained in:
joten 2016-04-13 18:48:37 +02:00
parent 7750b85ae7
commit be58a11b4e
2 changed files with 6 additions and 2 deletions

View file

@ -445,12 +445,14 @@ Bar_updateStatus() {
GuiControl, , Bar_#%m%_volume_highlighted, %vol%
GuiControl, , Bar_#%m%_volume, % " VOL: " SubStr(" " vol, -2) "% "
}
If Config_readinDate
If Config_readinDate {
FormatTime, time, , % Config_readinDateFormat
GuiControl, , Bar_#%m%_date, % time
If Config_readinTime
}
If Config_readinTime {
FormatTime, time, , % Config_readinTimeFormat
GuiControl, , Bar_#%m%_time, % time
}
}
}

View file

@ -75,6 +75,7 @@ ResourceMonitor_getDiskLoad(ByRef readLoad, ByRef writeLoad) {
Global ResourceMonitor_hDrive
Static oldReadCount, oldWriteCount
nReturn := oldReadCount := oldWriteCount := 0
dpSize := 5 * 8 + 4 + 4 + 4 + 4 + 8 + 4 + 8 * (A_IsUnicode ? 2 : 1) + 12 ;; 88?
VarSetCapacity(dp, dpSize)
DllCall("DeviceIoControl", "UInt", ResourceMonitor_hDrive, "UInt", 0x00070020, "UInt", 0, "UInt", 0, "UInt", &dp, "UInt", dpSize, "UIntP", nReturn, "UInt", 0) ;; IOCTL_DISK_PERFORMANCE
@ -119,6 +120,7 @@ ResourceMonitor_getSystemTimes() {
Static oldIdleTime, oldKrnlTime, oldUserTime
Static newIdleTime, newKrnlTime, newUserTime
newIdleTime := newKrnlTime := newUserTime := 0
oldIdleTime := newIdleTime
oldKrnlTime := newKrnlTime
oldUserTime := newUserTime