forked from xamarin/xamarin-macios
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
tj_devel709
committed
Oct 18, 2023
1 parent
b753413
commit 1201398
Showing
1 changed file
with
126 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,127 @@ | ||
using CoreFoundation; | ||
using ObjCRuntime; | ||
using Foundation; | ||
using System; | ||
|
||
#if MONOMAC | ||
using AppKit; | ||
#else | ||
using UIKit; | ||
using NSView = AppKit.UIView; | ||
#endif | ||
|
||
#if !NET | ||
using NativeHandle = System.IntPtr; | ||
#endif | ||
|
||
namespace PrintCore { | ||
|
||
[Mac (14,0)] | ||
[Protocol] | ||
[BaseType (typeof (NSObject))] | ||
interface PDEPanel | ||
{ | ||
[Abstract] | ||
[Export ("willShow")] | ||
void WillShow (); | ||
|
||
[Abstract] | ||
[Export ("shouldHide")] | ||
bool ShouldHide { get; } | ||
|
||
[Abstract] | ||
[Export ("saveValuesAndReturnError:")] | ||
bool SaveValuesAndReturnError ([NullAllowed] out NSError error); | ||
|
||
[Abstract] | ||
[Export ("restoreValuesAndReturnError:")] | ||
bool RestoreValuesAndReturnError ([NullAllowed] out NSError error); | ||
|
||
[NullAllowed, Export ("supportedPPDOptionKeys")] | ||
string[] SupportedPpdOptionKeys { get; } | ||
|
||
[Abstract] | ||
[Export ("PPDOptionKeyValueDidChange:ppdChoice:")] | ||
void PpdOptionKeyValueDidChange (string option, string choice); | ||
|
||
[Abstract] | ||
[NullAllowed, Export ("panelView")] | ||
NSView PanelView { get; } | ||
|
||
[Abstract] | ||
[Export ("panelName")] | ||
string PanelName { get; } | ||
|
||
[Abstract] | ||
[Export ("panelKind")] | ||
string PanelKind { get; } | ||
|
||
[Abstract] | ||
[NullAllowed, Export ("summaryInfo")] | ||
NSDictionary<NSString, NSString> SummaryInfo { get; } | ||
|
||
[Export ("shouldShowHelp")] | ||
bool ShouldShowHelp { get; } | ||
|
||
[Export ("shouldPrint")] | ||
bool ShouldPrint { get; } | ||
|
||
[Export ("printWindowWillClose:")] | ||
void PrintWindowWillClose (bool userCanceled); | ||
} | ||
|
||
[Mac (14,0)] | ||
[Protocol] | ||
[BaseType (typeof (NSObject))] | ||
interface PDEPlugIn | ||
{ | ||
[Abstract] | ||
[Export ("initWithBundle:")] | ||
NativeHandle Constructor (NSBundle bundle); | ||
|
||
[Abstract] | ||
[Export ("PDEPanelsForType:withHostInfo:")] | ||
[return: NullAllowed] | ||
PDEPanel[] PDEPanelsForType (string pdeType, IPDEPlugInCallbackProtocol host); | ||
} | ||
|
||
interface IPDEPlugInCallbackProtocol { } | ||
|
||
[Mac (14,0)] | ||
[Protocol] | ||
interface PDEPlugInCallbackProtocol | ||
{ | ||
[NullAllowed, Export ("printSession")] | ||
[Abstract] | ||
[Internal] | ||
// Original: unsafe PMPrintSession* PrintSession { get; } | ||
IntPtr _GetPrintSession (); | ||
|
||
[Abstract] | ||
[NullAllowed, Export ("printSettings")] | ||
// Original: unsafe PMPrintSession* PrintSettings { get; } | ||
IntPtr _GetPrintSettings (); | ||
|
||
[Abstract] | ||
[Internal] | ||
[NullAllowed, Export ("pageFormat")] | ||
// Original: unsafe PMPageFormat* PageFormat { get; } | ||
IntPtr _GetPageFormat (); | ||
|
||
[Abstract] | ||
[Internal] | ||
[Export ("PMPrinter")] | ||
// Original: unsafe PMPrinter* PMPrinter { get; } | ||
IntPtr _GetPMPrinter (); | ||
|
||
[Abstract] | ||
[Internal] | ||
[NullAllowed, Export ("ppdFile")] | ||
// Original: unsafe ppd_file_s* PpdFile { get; } | ||
IntPtr _GetPpdFile (); | ||
|
||
[Abstract] | ||
[Export ("willChangePPDOptionKeyValue:ppdChoice:")] | ||
bool PpdChoice (string option, string choice); | ||
} | ||
} |