From b3ea27ef6e6ff14aef78fb6c1e2017ccb3487f3b Mon Sep 17 00:00:00 2001 From: RKrom Date: Sun, 17 Feb 2013 10:51:11 +0000 Subject: [PATCH] Fixed compile error, forgot parameter git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2497 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4 --- GreenshotPlugin/UnmanagedHelpers/GDIplus.cs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs b/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs index d641407b4..8aa8b8270 100644 --- a/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs +++ b/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs @@ -165,7 +165,7 @@ namespace GreenshotPlugin.UnmanagedHelpers { return (IntPtr)FIELD_INFO_NATIVE_IMAGEATTRIBUTES.GetValue(imageAttributes); } - private static bool canApply() { + private static bool canApply(int radius) { if (Environment.OSVersion.Version.Major < 6) { return false; } else if ((Environment.OSVersion.Version.Major >= 6 && Environment.OSVersion.Version.Minor >= 2) && radius < 20) { @@ -183,7 +183,8 @@ namespace GreenshotPlugin.UnmanagedHelpers { /// bool true if the edges are expanded with the radius /// false if there is no GDI+ available or an exception occured public static bool ApplyBlur(Bitmap destinationBitmap, Rectangle area, int radius, bool expandEdges) { - if (!canApply()) { + if (!canApply(radius)) + { return false; } IntPtr hBlurParams = IntPtr.Zero; @@ -237,7 +238,8 @@ namespace GreenshotPlugin.UnmanagedHelpers { /// /// false if there is no GDI+ available or an exception occured public static bool DrawWithBlur(Graphics graphics, Bitmap image, Rectangle source, Matrix transform, ImageAttributes imageAttributes, int radius, bool expandEdges) { - if (!canApply()) { + if (!canApply(radius)) + { return false; }