public void SavePanelDidEndReturnCodeContextInfo(NSSavePanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     if (returnCode == NSPanel.NSOKButton)
     {
         NSString filename = sheet.Filename + ".tiff";
         this.imageView.CroppedImage().TIFFRepresentation.WriteToFileAtomically(filename, true);
     }
 }
예제 #2
0
 public void SaveImageDidEnd(NSSavePanel panel, NSInteger returnCode, IntPtr contextInfo)
 {
     if (returnCode == NSPanel.NSOKButton)
     {
         NSRect frame = this.imageView.Frame;
         ImageUtils.IISaveImage(this.imageView, panel.URL, (uint) Math.Ceiling(frame.size.width), (uint) Math.Ceiling(frame.size.height));
     }
 }
예제 #3
0
 public void OpenImageDidEndReturnCodeContextInfo(NSOpenPanel panel, NSInteger returnCode, IntPtr contextInfo)
 {
     if (returnCode == NSPanel.NSOKButton)
     {
         if (panel.Filenames.Count > 0)
         {
             ImageInfo image = ImageUtils.IICreateImage(NSURL.FileURLWithPath((panel.Filenames.ObjectAtIndex(0).CastTo<NSString>())));
             this.imageView.Image = image;
             this.Reset(null);
         }
     }
 }
 public void PanelDidEndReturnCodeContextInfo(SFCertificateTrustPanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(sheet, returnCode, contextInfo);
     this.Release();
 }
예제 #5
0
 public void SheetDidEndReturnCodeContextInfo(NSWindow sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(sheet, returnCode, contextInfo);
     this.Autorelease();
 }
예제 #6
0
		public static NSDecimal FromInteger (NSInteger value)
		{
			return NSNumber.NumberWithInteger (value).DecimalValue;
		}
예제 #7
0
 public void PanelDidEndReturnCodeContextInfo(NSSavePanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(sheet, returnCode, contextInfo);
     this.Autorelease();
 }
예제 #8
0
 public Id TableViewObjectValueForTableColumnRow(NSTableView aTableView, NSTableColumn theColumn, NSInteger rowIndex)
 {
     String identifier = theColumn.Identifier.CastTo<NSString>();
     if (identifier.Equals("page"))
     {
         PDFSelection selection = this._searchResults.ObjectAtIndex((uint) rowIndex).CastTo<PDFSelection>();
         return selection.Pages.ObjectAtIndex(0).CastTo<PDFPage>().Label;
     }
     else if (identifier.Equals("section"))
     {
         PDFSelection selection = this._searchResults.ObjectAtIndex((uint) rowIndex).CastTo<PDFSelection>();
         PDFOutline outline = this._pdfView.Document.OutlineItemForSelection(selection);
         return (outline != null) ? outline.Label : null;
     }
     else
     {
         return null;
     }
 }
예제 #9
0
 public Id OutlineViewChildOfItem(NSOutlineView outlineView, NSInteger index, Id item)
 {
     if (item == null)
     {
         if (this._outline != null)
         {
             return this._outline.ChildAtIndex(index).Retain();
         }
         else
         {
             return null;
         }
     }
     else
     {
         return item.CastTo<PDFOutline>().ChildAtIndex((uint) index).Retain();
     }
 }
예제 #10
0
 public void PrintPanelDidEndReturnCodeContextInfo(NSPrintPanel printPanel, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(printPanel, returnCode, contextInfo);
     this.Autorelease();
 }
예제 #11
0
 public void SheetDidEndReturnCodeContextInfo(NSOpenPanel panel, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(panel, returnCode, contextInfo);
     this.Autorelease();
 }
예제 #12
0
 public void OpenPanelDidEndReturnCodeContextInfo(NSOpenPanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     NSImage image = new NSImage(sheet.Filename).SafeAutorelease();
     this.imageView.Image = image;
     this.ImageChanged(null);
 }
 public void PanelDidEndReturnCodeContextInfo(SFChooseIdentityPanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(sheet, returnCode, contextInfo);
     this.Release();
 }
예제 #14
0
 public void SheetDidEndReturnCodeContextInfo(NSWindow sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     sheet.OrderOut(this);
 }
 public void PanelDidEndReturnCodeContextInfo(SFKeychainSettingsPanel sheet, NSInteger returnCode, IntPtr contextInfo)
 {
     this.modalDelegate(sheet, returnCode, contextInfo);
     this.Release();
 }