Method PickerBuilder.setOrigin
ตั้งค่าต้นทางของกล่องโต้ตอบเครื่องมือเลือก คุณควรตั้งค่าต้นทางเป็น
window.location.protocol + '//' + window.location.host ของหน้าเว็บด้านบนสุด หากแอปพลิเคชันของคุณทํางานใน iframe
ลายเซ็น
setOrigin(origin: string): PickerBuilder;
รายละเอียด
ไม่บังคับ |
ไม่ได้ |
รอบชิงชนะเลิศ |
ไม่ได้ |
มีการป้องกัน |
ไม่ได้ |
คงที่ |
ไม่ได้ |
พารามิเตอร์
ชื่อ |
ประเภท |
ไม่บังคับ |
คำอธิบาย |
origin |
string |
ไม่ได้ |
|
การคืนสินค้า
PickerBuilder
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-11-07 UTC
[null,null,["อัปเดตล่าสุด 2024-11-07 UTC"],[[["Sets the origin of the picker dialog, crucial for applications running in iframes to ensure proper functionality by specifying the top-most page's origin."],["The `setOrigin` method requires a single, mandatory parameter: `origin`, which is a string representing the desired origin."],["This method is not optional, final, protected, or static, offering flexibility in its implementation."],["Using this method returns a `PickerBuilder` instance, enabling further configuration of the picker dialog."]]],[]]