개정판 ac4f1e13
Markup load 비동기로 변경
Change-Id: I471906b1090f7f3f0fd18e97d88a54f75fd1f673
MarkupToPDF/Controls/Etc/SignControl.cs | ||
---|---|---|
463 | 463 |
{ |
464 | 464 |
byte[] imageBytes = System.Convert.FromBase64String(_sign); |
465 | 465 |
|
466 |
System.IO.MemoryStream stream = new System.IO.MemoryStream(); |
|
467 |
stream.Write(imageBytes, 0, imageBytes.Length); |
|
468 |
stream.Position = 0; |
|
469 |
System.Drawing.Image img = System.Drawing.Image.FromStream(stream); |
|
470 | 466 |
BitmapImage returnImage = new BitmapImage(); |
471 |
returnImage.BeginInit(); |
|
472 |
System.IO.MemoryStream ms = new System.IO.MemoryStream(); |
|
473 |
img.Save(ms, System.Drawing.Imaging.ImageFormat.Png); |
|
474 |
ms.Seek(0, System.IO.SeekOrigin.Begin); |
|
475 |
returnImage.StreamSource = ms; |
|
476 |
returnImage.EndInit(); |
|
477 |
stream.Close(); |
|
467 |
|
|
468 |
using (System.IO.MemoryStream stream = new System.IO.MemoryStream()) |
|
469 |
{ |
|
470 |
stream.WriteAsync(imageBytes, 0, imageBytes.Length); |
|
471 |
stream.Position = 0; |
|
472 |
System.Drawing.Image img = System.Drawing.Image.FromStream(stream); |
|
473 |
returnImage.BeginInit(); |
|
474 |
System.IO.MemoryStream ms = new System.IO.MemoryStream(); |
|
475 |
img.Save(ms, System.Drawing.Imaging.ImageFormat.Png); |
|
476 |
ms.Seek(0, System.IO.SeekOrigin.Begin); |
|
477 |
returnImage.StreamSource = ms; |
|
478 |
returnImage.EndInit(); |
|
479 |
stream.Close(); |
|
480 |
} |
|
481 |
|
|
478 | 482 |
instance.SignImage = returnImage; |
479 | 483 |
} |
480 | 484 |
} |
내보내기 Unified diff