MyEarth Posted September 7, 2015 Share Posted September 7, 2015 Hi, the _GetMinAnimate not work like expected, someone knows why? Orginal code by eemuli_SetMinAnimate(False) MsgBox(0, 0, _GetMinAnimate()) Sleep(2000) _SetMinAnimate(True) MsgBox(0, 0, _GetMinAnimate()) Func _SetMinAnimate($bBoolean = True) ; $SPI_SETANIMATION = 0x0049 Local Const $tagANIMATIONINFO = "uint cbSize;int iMinAnimate" Local $sStruct = DllStructCreate($tagANIMATIONINFO) DllStructSetData($sStruct, "iMinAnimate", $bBoolean) DllStructSetData($sStruct, "cbSize", DllStructGetSize($sStruct)) $aReturn = DllCall('user32.dll', 'int', 'SystemParametersInfo', 'uint', 0x0049, 'int', DllStructGetSize($sStruct), 'ptr', DllStructGetPtr($sStruct), 'uint', 0) If IsArray($aReturn) Then Return 1 Return 0 EndFunc ;==>_SetMinAnimate Func _GetMinAnimate() ; $SPI_GETANIMATION = 0x0048 Local Const $tagANIMATIONINFO = "uint cbSize;int iMinAnimate" Local $sStruct = DllStructCreate($tagANIMATIONINFO) DllStructSetData($sStruct, "cbSize", DllStructGetSize($sStruct)) $aReturn = DllCall('user32.dll', 'int', 'SystemParametersInfo', 'uint', 0x0048, 'int', DllStructGetSize($sStruct), 'ptr', DllStructGetPtr($sStruct), 'uint', 0) If IsArray($aReturn) Then Return $aReturn[0] Return 0 EndFunc ;==>_GetMinAnimateThanks Link to comment Share on other sites More sharing options...
Danyfirex Posted September 7, 2015 Share Posted September 7, 2015 (edited) It's working for me. if You mean (windows got a nice effect while activate/deactive) Saludos Edited September 7, 2015 by Danyfirex Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut Link to comment Share on other sites More sharing options...
MyEarth Posted September 7, 2015 Author Share Posted September 7, 2015 No, you don't have understand _SetMinAnimate with be different boolean value work fine and until that is ok, is _GetMinAnimate in the MsgBox don't give me the correct boolean value:GETANIMATIONRetrieves the animation effects associated with user actions. The pvParam parameter must point to an ANIMATIONINFO structure that receives the information. Set the cbSize member of this structure and the uiParam parameter to sizeof(ANIMATIONINFO).I want to know if is activate/deactive before activating/deactivating Link to comment Share on other sites More sharing options...
Danyfirex Posted September 7, 2015 Share Posted September 7, 2015 mmm I see now. Just return the iMinAnimate _SetMinAnimate(False) MsgBox(0, 0, (_GetMinAnimate() ? "Active" : "Deactive")) Sleep(2000) _SetMinAnimate(True) MsgBox(0, 0, (_GetMinAnimate() ? "Active" : "Deactive")) Func _SetMinAnimate($bBoolean = True) ; $SPI_SETANIMATION = 0x0049 Local Const $tagANIMATIONINFO = "uint cbSize;int iMinAnimate" Local $sStruct = DllStructCreate($tagANIMATIONINFO) DllStructSetData($sStruct, "iMinAnimate", $bBoolean) DllStructSetData($sStruct, "cbSize", DllStructGetSize($sStruct)) $aReturn = DllCall('user32.dll', 'int', 'SystemParametersInfo', 'uint', 0x0049, 'int', DllStructGetSize($sStruct), 'ptr', DllStructGetPtr($sStruct), 'uint', 0) If IsArray($aReturn) Then Return 1 Return 0 EndFunc ;==>_SetMinAnimate Func _GetMinAnimate() ; $SPI_GETANIMATION = 0x0048 Local Const $tagANIMATIONINFO = "uint cbSize;int iMinAnimate" Local $sStruct = DllStructCreate($tagANIMATIONINFO) DllStructSetData($sStruct, "cbSize", DllStructGetSize($sStruct)) $aReturn = DllCall('user32.dll', 'int', 'SystemParametersInfo', 'uint', 0x0048, 'int', DllStructGetSize($sStruct), 'ptr', DllStructGetPtr($sStruct), 'uint', 0) If IsArray($aReturn) Then Return $sStruct.iMinAnimate Return 0 EndFunc ;==>_GetMinAnimateSaludos Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now