Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit41347c4

Browse files
authored
[tvservices] Update for Xcode 11 beta 1 (#6391)
No changes in beta 2
1 parentee2d045 commit41347c4

File tree

3 files changed

+298
-81
lines changed

3 files changed

+298
-81
lines changed

‎src/tvservices.cs‎

Lines changed: 274 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
// Copyright 2015 Xamarin Inc.
2+
// Copyright 2019 Microsoft Corporation
23

34
usingSystem;
5+
usingCoreGraphics;
46
usingFoundation;
57
usingObjCRuntime;
68

79
namespaceTVServices{
810

911
[TV(9,0)]
12+
[Deprecated(PlatformName.TvOS,13,0,message:"Use 'TVTopShelfContentProvider' instead.")]
1013
[BaseType(typeof(NSObject))]
1114
[DisableDefaultCtor]
1215
interfaceTVContentIdentifier:NSCopying,NSSecureCoding{
@@ -23,6 +26,7 @@ interface TVContentIdentifier : NSCopying, NSSecureCoding {
2326

2427
[TV(9,0)]
2528
[BaseType(typeof(NSObject))]
29+
[Deprecated(PlatformName.TvOS,13,0,message:"Use 'TVTopShelfItem' instead.")]
2630
[DisableDefaultCtor]
2731
interfaceTVContentItem:NSCopying,NSSecureCoding{
2832
[Export("contentIdentifier",ArgumentSemantic.Copy)]
@@ -101,4 +105,274 @@ interface TVTopShelfItems {
101105
[Field("TVTopShelfItemsDidChangeNotification")]
102106
NSStringDidChangeNotification{get;}
103107
}
108+
109+
[TV(13,0)]
110+
[BaseType(typeof(NSObject))]
111+
[DisableDefaultCtor]// Name property can't be null
112+
interfaceTVAppProfileDescriptor:NSCopying,NSSecureCoding{
113+
114+
[Export("initWithName:")]
115+
IntPtrConstructor(stringname);
116+
117+
[Export("name")]
118+
stringName{get;set;}
119+
}
120+
121+
[TV(13,0)]
122+
[BaseType(typeof(NSObject))]
123+
[DisableDefaultCtor]
124+
interfaceTVTopShelfAction{
125+
[Export("URL",ArgumentSemantic.Copy)]
126+
NSUrlUrl{get;}
127+
128+
[Export("initWithURL:")]
129+
[DesignatedInitializer]
130+
IntPtrConstructor(NSUrlurl);
131+
}
132+
133+
[TV(13,0)]
134+
[Native]
135+
enumTVTopShelfCarouselContentStyle:long{
136+
Actions,
137+
Details,
138+
}
139+
140+
interfaceITVTopShelfContent{}
141+
142+
[TV(13,0)]
143+
[Protocol]
144+
interfaceTVTopShelfContent{}
145+
146+
[TV(13,0)]
147+
[BaseType(typeof(NSObject))]
148+
[DisableDefaultCtor]
149+
interfaceTVTopShelfCarouselContent:TVTopShelfContent{
150+
[Export("style")]
151+
TVTopShelfCarouselContentStyleStyle{get;}
152+
153+
[Export("items",ArgumentSemantic.Copy)]
154+
TVTopShelfCarouselItem[]Items{get;}
155+
156+
[Export("initWithStyle:items:")]
157+
[DesignatedInitializer]
158+
IntPtrConstructor(TVTopShelfCarouselContentStylestyle,TVTopShelfCarouselItem[]items);
159+
}
160+
161+
[TV(13,0)]
162+
[Flags]
163+
[Native]
164+
publicenumTVTopShelfCarouselItemMediaOptions:ulong{
165+
VideoResolutionHD=1uL<<0,
166+
VideoResolution4K=2uL<<0,
167+
VideoColorSpaceHdr=1uL<<6,
168+
VideoColorSpaceDolbyVision=2uL<<6,
169+
AudioDolbyAtmos=1uL<<12,
170+
AudioTranscriptionClosedCaptioning=1uL<<13,
171+
AudioTranscriptionSdh=1uL<<14,
172+
AudioDescription=1uL<<15,
173+
}
174+
175+
[TV(13,0)]
176+
[BaseType(typeof(TVTopShelfItem))]
177+
[DisableDefaultCtor]// -[TVTopShelfCarouselItem init]: unrecognized selector sent to instance 0x600000eb18c0
178+
interfaceTVTopShelfCarouselItem{
179+
180+
// inlined from base class
181+
[Export("initWithIdentifier:")]
182+
[DesignatedInitializer]
183+
IntPtrConstructor(stringidentifier);
184+
185+
[NullAllowed,Export("contextTitle")]
186+
stringContextTitle{get;set;}
187+
188+
[NullAllowed,Export("summary")]
189+
stringSummary{get;set;}
190+
191+
[NullAllowed,Export("genre")]
192+
stringGenre{get;set;}
193+
194+
[Export("duration")]
195+
double/* NSTimeInterval */Duration{get;set;}
196+
197+
[NullAllowed,Export("creationDate",ArgumentSemantic.Copy)]
198+
NSDateCreationDate{get;set;}
199+
200+
[Export("mediaOptions",ArgumentSemantic.Assign)]
201+
TVTopShelfCarouselItemMediaOptionsMediaOptions{get;set;}
202+
203+
[NullAllowed,Export("previewVideoURL",ArgumentSemantic.Copy)]
204+
NSUrlPreviewVideoUrl{get;set;}
205+
206+
[NullAllowed,Export("cinemagraphURL",ArgumentSemantic.Copy)]
207+
NSUrlCinemagraphUrl{get;set;}
208+
209+
[Export("namedAttributes",ArgumentSemantic.Copy)]
210+
TVTopShelfNamedAttribute[]NamedAttributes{get;set;}
211+
}
212+
213+
[TV(13,0)]
214+
[BaseType(typeof(NSObject))]
215+
interfaceTVTopShelfContentProvider{
216+
[Async]
217+
[Export("loadTopShelfContentWithCompletionHandler:")]
218+
voidLoadTopShelfContent(Action<ITVTopShelfContent>completionHandler);
219+
220+
[Static]
221+
[Export("topShelfContentDidChange")]
222+
voidDidChange();
223+
}
224+
225+
[TV(13,0)]
226+
[BaseType(typeof(NSObject))]
227+
[DisableDefaultCtor]
228+
interfaceTVTopShelfInsetContent:TVTopShelfContent{
229+
[Export("items",ArgumentSemantic.Copy)]
230+
TVTopShelfItem[]Items{get;}
231+
232+
[Static]
233+
[Export("imageSize")]
234+
CGSizeImageSize{get;}
235+
236+
[Export("initWithItems:")]
237+
IntPtrConstructor(TVTopShelfItem[]items);
238+
}
239+
240+
[TV(13,0)]
241+
[BaseType(typeof(TVTopShelfObject))]
242+
[DisableDefaultCtor]// identifier can't be null and we have a designated initializer
243+
interfaceTVTopShelfItem{
244+
245+
[Export("identifier")]
246+
stringIdentifier{get;}
247+
248+
[NullAllowed,Export("playAction",ArgumentSemantic.Strong)]
249+
TVTopShelfActionPlayAction{get;set;}
250+
251+
[NullAllowed,Export("displayAction",ArgumentSemantic.Strong)]
252+
TVTopShelfActionDisplayAction{get;set;}
253+
254+
[NullAllowed,Export("expirationDate",ArgumentSemantic.Copy)]
255+
NSDateExpirationDate{get;set;}
256+
257+
[Export("setImageURL:forTraits:")]
258+
voidSetImageUrl([NullAllowed]NSUrlimageUrl,TVTopShelfItemImageTraitstraits);
259+
260+
[Export("imageURLForTraits:")]
261+
[return:NullAllowed]
262+
NSUrlGetImageUrl(TVTopShelfItemImageTraitstraits);
263+
264+
[Export("initWithIdentifier:")]
265+
[DesignatedInitializer]
266+
IntPtrConstructor(stringidentifier);
267+
}
268+
269+
[TV(13,0)]
270+
[BaseType(typeof(NSObject))]
271+
[DisableDefaultCtor]
272+
interfaceTVTopShelfNamedAttribute{
273+
274+
[Export("name")]
275+
stringName{get;}
276+
277+
[Export("values",ArgumentSemantic.Copy)]
278+
string[]Values{get;}
279+
280+
[Export("initWithName:values:")]
281+
[DesignatedInitializer]
282+
IntPtrConstructor(stringname,string[]values);
283+
}
284+
285+
[TV(13,0)]
286+
[BaseType(typeof(NSObject))]
287+
[Abstract]
288+
[DisableDefaultCtor]
289+
interfaceTVTopShelfObject{
290+
[NullAllowed,Export("title")]
291+
stringTitle{get;set;}
292+
}
293+
294+
[TV(13,0)]
295+
[Flags]
296+
[Native]
297+
enumTVTopShelfItemImageTraits:ulong{
298+
Scale1x=1,
299+
Scale2x=2,
300+
}
301+
302+
[TV(13,0)]
303+
[BaseType(typeof(NSObject))]
304+
interfaceTVUserManager{
305+
306+
[NullAllowed,Export("currentUserIdentifier")]
307+
stringCurrentUserIdentifier{get;}
308+
309+
[Export("userIdentifiersForCurrentProfile",ArgumentSemantic.Copy)]
310+
string[]UserIdentifiersForCurrentProfile{get;set;}
311+
312+
[Async]
313+
[Export("presentProfilePreferencePanelWithCurrentSettings:availableProfiles:completion:")]
314+
voidPresentProfilePreferencePanel(NSDictionary<NSString,TVAppProfileDescriptor>currentSettings,TVAppProfileDescriptor[]availableProfiles,Action<NSDictionary<NSString,TVAppProfileDescriptor>>completion);
315+
316+
[Async]
317+
[Export("shouldStorePreferenceForCurrentUserToProfile:completion:")]
318+
voidShouldStorePreferenceForCurrentUser(TVAppProfileDescriptorprofile,Action<bool>completion);
319+
320+
[Notification]
321+
[Field("TVUserManagerCurrentUserIdentifierDidChangeNotification")]
322+
NSStringCurrentUserIdentifierDidChangeNotification{get;}
323+
}
324+
325+
[TV(13,0)]
326+
[BaseType(typeof(TVTopShelfObject))]
327+
[DisableDefaultCtor]// null is not allowed for items
328+
interfaceTVTopShelfItemCollection{
329+
330+
[Export("items",ArgumentSemantic.Copy)]
331+
TVTopShelfItem[]Items{get;}
332+
333+
[Export("initWithItems:")]
334+
IntPtrConstructor(TVTopShelfItem[]items);
335+
}
336+
337+
[TV(13,0)]
338+
[BaseType(typeof(NSObject))]
339+
[DisableDefaultCtor]
340+
interfaceTVTopShelfSectionedContent:TVTopShelfContent{
341+
342+
[Export("sections",ArgumentSemantic.Copy)]
343+
TVTopShelfItemCollection[]Sections{get;}
344+
345+
[Export("initWithSections:")]
346+
[DesignatedInitializer]
347+
IntPtrConstructor(TVTopShelfItemCollection[]sections);
348+
349+
[Static]
350+
[Export("imageSizeForImageShape:")]
351+
CGSizeGetImageSize(TVTopShelfSectionedItemImageShapeshape);
352+
}
353+
354+
[TV(13,0)]
355+
[Native]
356+
publicenumTVTopShelfSectionedItemImageShape:long{
357+
Square,
358+
Poster,
359+
Hdtv,
360+
}
361+
362+
[TV(13,0)]
363+
[BaseType(typeof(TVTopShelfItem))]
364+
[DisableDefaultCtor]// -[TVTopShelfSectionedItem init]: unrecognized selector sent to instance 0x600001f251a0
365+
interfaceTVTopShelfSectionedItem{
366+
367+
// inlined from base type
368+
[Export("initWithIdentifier:")]
369+
[DesignatedInitializer]
370+
IntPtrConstructor(stringidentifier);
371+
372+
[Export("imageShape",ArgumentSemantic.Assign)]
373+
TVTopShelfSectionedItemImageShapeImageShape{get;set;}
374+
375+
[Export("playbackProgress")]
376+
doublePlaybackProgress{get;set;}
377+
}
104378
}

‎tests/introspection/iOS/iOSApiProtocolTest.cs‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,18 @@ protected override bool Skip (Type type, string protocolName)
344344
case"CLKSimpleGaugeProvider":
345345
case"CLKTimeIntervalGaugeProvider":
346346
returntrue;
347+
#elif__TVOS__
348+
case"TVTopShelfAction":
349+
case"TVTopShelfCarouselContent":
350+
case"TVTopShelfCarouselItem":
351+
case"TVTopShelfInsetContent":
352+
case"TVTopShelfItem":
353+
case"TVTopShelfItemCollection":
354+
case"TVTopShelfNamedAttribute":
355+
case"TVTopShelfObject":
356+
case"TVTopShelfSectionedContent":
357+
case"TVTopShelfSectionedItem":
358+
returntrue;
347359
#endif
348360
}
349361
break;
@@ -550,6 +562,18 @@ protected override bool Skip (Type type, string protocolName)
550562
case"CLKSimpleGaugeProvider":
551563
case"CLKTimeIntervalGaugeProvider":
552564
returntrue;
565+
#elif__TVOS__
566+
case"TVTopShelfAction":
567+
case"TVTopShelfCarouselContent":
568+
case"TVTopShelfCarouselItem":
569+
case"TVTopShelfInsetContent":
570+
case"TVTopShelfItem":
571+
case"TVTopShelfItemCollection":
572+
case"TVTopShelfNamedAttribute":
573+
case"TVTopShelfObject":
574+
case"TVTopShelfSectionedContent":
575+
case"TVTopShelfSectionedItem":
576+
returntrue;
553577
#endif
554578
}
555579
break;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp