بروتوكول <GCKUIImageChooseer> للبروتوكول
يشير ذلك المصطلح إلى عنصر يُستخدَم لاختيار صورة من عنصر GCKMediaMetadata لغرض معيّن.
ويتم استخدام التنفيذ التلقائي داخليًا من خلال إطار العمل الذي يختار دائمًا الصورة الأولى من البيانات الوصفية لجميع الاستخدامات. يمكن أن يوفّر التطبيق عملية تنفيذ مخصّصة من خلال ضبط السمة GCKCastContext::imagePicker.
- منذ
- 3.0
يكتسب <NSObject>.
لعرض صورة من النوع المحدد من البيانات الوصفية للوسائط.
- Parameters
-
imageHints | The hints about how to pick the image. |
metadata | The media metadata to pick from. |
- المرتجعات
- الصورة المحددة أو
nil
إذا لم تتوفر صورة مناسبة للنوع المطلوب.
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2023-12-01 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2023-12-01 (حسب التوقيت العالمي المتفَّق عليه)"],[[["`GCKUIImagePicker` protocol helps select images from `GCKMediaMetadata` objects for display within the Google Cast framework."],["By default, the first image in the metadata is used, but apps can customize image selection via `GCKCastContext::imagePicker`."],["`getImageWithHints:fromMetadata:` method fetches a specific image type from the metadata based on provided hints."],["If no suitable image is found matching the desired type, this method will return `nil`."]]],["The `GCKUIImagePicker` protocol selects an image from `GCKMediaMetadata`. It has a default implementation that selects the first image. Custom implementations can be provided via `GCKCastContext::imagePicker`. The key method, `getImageWithHints:fromMetadata:`, retrieves an image based on `GCKUIImageHints` from provided metadata. It returns the selected `GCKImage` or `nil` if no suitable image is found. This enables picking specific image types for different purposes.\n"]]