| 12345678910111213141516171819202122232425262728293031 |
- using System.Threading.Tasks;
- using InABox.Core;
- using InABox.Mobile;
- namespace PRS.Mobile
- {
- public class DigitalFormEmbeddedImage : DigitalFormEmbeddedMedia<DFLayoutEmbeddedImage, DFLayoutEmbeddedImageProperties>
- {
- protected override bool IsVideo => false;
- protected override bool DisableLibrary => Definition.Properties.DisableLibrary;
- protected override bool Secure => Definition.Properties.Secure;
- protected override bool Required => Definition.Properties.Required;
- protected override Task<MobileDocument> CaptureMedia()
- {
- return MobileDocument.From(new MobileDocumentCameraSource());
- }
- protected override Task<MobileDocument> SelectMedia()
- {
- return MobileDocument.From(new MobileDocumentPhotoLibrarySource());
- }
-
- protected override byte[] CreateThumbnail(byte[] data, float maxwidth = 200, float maxheight=200)
- {
- return MobileUtils.ImageTools.CreateThumbnail(data, maxwidth, maxheight);
- }
-
- }
- }
|