From cedd2207897d1266b00acb97625fbfda6c927133 Mon Sep 17 00:00:00 2001 From: Darth Affe Date: Tue, 31 Jan 2017 20:25:01 +0100 Subject: [PATCH] Fixed stupid formating in Cue-Natives --- RGB.NET.Devices.Corsair/Native/_CUESDK.cs | 49 +++++------------------ 1 file changed, 10 insertions(+), 39 deletions(-) diff --git a/RGB.NET.Devices.Corsair/Native/_CUESDK.cs b/RGB.NET.Devices.Corsair/Native/_CUESDK.cs index b24db79..97698d9 100644 --- a/RGB.NET.Devices.Corsair/Native/_CUESDK.cs +++ b/RGB.NET.Devices.Corsair/Native/_CUESDK.cs @@ -40,45 +40,16 @@ namespace RGB.NET.Devices.Corsair.Native _dllHandle = LoadLibrary(dllPath); - _corsairSetLedsColorsPointer = - (CorsairSetLedsColorsPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairSetLedsColors"), - typeof(CorsairSetLedsColorsPointer)); - _corsairGetDeviceCountPointer = - (CorsairGetDeviceCountPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetDeviceCount"), - typeof(CorsairGetDeviceCountPointer)); - _corsairGetDeviceInfoPointer = - (CorsairGetDeviceInfoPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetDeviceInfo"), - typeof(CorsairGetDeviceInfoPointer)); - _corsairGetLedPositionsPointer = - (CorsairGetLedPositionsPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedPositions"), - typeof(CorsairGetLedPositionsPointer)); - _corsairGetLedPositionsByDeviceIndexPointer = - (CorsairGetLedPositionsByDeviceIndexPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedPositionsByDeviceIndex"), - typeof(CorsairGetLedPositionsByDeviceIndexPointer)); - _corsairGetLedIdForKeyNamePointer = - (CorsairGetLedIdForKeyNamePointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedIdForKeyName"), - typeof(CorsairGetLedIdForKeyNamePointer)); - _corsairRequestControlPointer = - (CorsairRequestControlPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairRequestControl"), - typeof(CorsairRequestControlPointer)); - _corsairReleaseControlPointer = - (CorsairReleaseControlPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairReleaseControl"), - typeof(CorsairReleaseControlPointer)); - _corsairPerformProtocolHandshakePointer = - (CorsairPerformProtocolHandshakePointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairPerformProtocolHandshake"), - typeof(CorsairPerformProtocolHandshakePointer)); - _corsairGetLastErrorPointer = - (CorsairGetLastErrorPointer) - Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLastError"), typeof(CorsairGetLastErrorPointer)); + _corsairSetLedsColorsPointer = (CorsairSetLedsColorsPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairSetLedsColors"), typeof(CorsairSetLedsColorsPointer)); + _corsairGetDeviceCountPointer = (CorsairGetDeviceCountPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetDeviceCount"), typeof(CorsairGetDeviceCountPointer)); + _corsairGetDeviceInfoPointer = (CorsairGetDeviceInfoPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetDeviceInfo"), typeof(CorsairGetDeviceInfoPointer)); + _corsairGetLedPositionsPointer = (CorsairGetLedPositionsPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedPositions"), typeof(CorsairGetLedPositionsPointer)); + _corsairGetLedPositionsByDeviceIndexPointer = (CorsairGetLedPositionsByDeviceIndexPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedPositionsByDeviceIndex"), typeof(CorsairGetLedPositionsByDeviceIndexPointer)); + _corsairGetLedIdForKeyNamePointer = (CorsairGetLedIdForKeyNamePointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLedIdForKeyName"), typeof(CorsairGetLedIdForKeyNamePointer)); + _corsairRequestControlPointer = (CorsairRequestControlPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairRequestControl"), typeof(CorsairRequestControlPointer)); + _corsairReleaseControlPointer = (CorsairReleaseControlPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairReleaseControl"), typeof(CorsairReleaseControlPointer)); + _corsairPerformProtocolHandshakePointer = (CorsairPerformProtocolHandshakePointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairPerformProtocolHandshake"), typeof(CorsairPerformProtocolHandshakePointer)); + _corsairGetLastErrorPointer = (CorsairGetLastErrorPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "CorsairGetLastError"), typeof(CorsairGetLastErrorPointer)); } private static void UnloadCUESDK()