浏览代码

Ifdef savetodesktop

Krzysztof Krysiński 1 年之前
父节点
当前提交
e4bfaa02bf
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      src/ChunkyImageLib/Surface.cs

+ 2 - 1
src/ChunkyImageLib/Surface.cs

@@ -132,7 +132,7 @@ public class Surface : IDisposable
         return true;
     }
 
-    [Conditional("DEBUG")]
+#if DEBUG
     public void SaveToDesktop(string filename = "savedSurface.png")
     {
         using var final = DrawingSurface.Create(new ImageInfo(Size.X, Size.Y, ColorType.Rgba8888, AlphaType.Premul, ColorSpace.CreateSrgb()));
@@ -144,6 +144,7 @@ public class Surface : IDisposable
             png.SaveTo(stream);
         }
     }
+#endif
 
     private DrawingSurface CreateDrawingSurface()
     {