סקר מחקר: נשמח לשמוע על החוויה שלך עם Blockly
לפתיחת הסקר
blockly > IConnectionPreviewer > previewReplacement
שיטת IConnectionPreviewer.previewReplacement()
הצגת תצוגה מקדימה של החיבור שבה ה- DraggedCon מתחבר ל-staticCon ומחליף את החליף בלוק (שמחובר כרגע ל-staticCon).
Signature:
previewReplacement(draggedConn: RenderedConnection, staticConn: RenderedConnection, replacedBlock: BlockSvg): void;
פרמטרים
פרמטר |
סוג |
תיאור |
draggedConn |
RenderedConnection |
|
staticConn |
RenderedConnection |
|
replacedBlock |
BlockSvg |
הבלוק שמחובר כרגע ל-staticCon שיוחלף. |
החזרות:
ריק
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2024-08-21 (שעון UTC).
[null,null,["עדכון אחרון: 2024-08-21 (שעון UTC)."],[[["The `previewReplacement` method visually displays how a dragged connection would connect to a static connection, replacing an existing block."],["It takes three parameters: the dragged connection, the static connection, and the block being replaced."],["This method is part of the `IConnectionPreviewer` interface and doesn't return any value."]]],["The `previewReplacement` method, part of the `IConnectionPreviewer` interface, shows a connection preview. This preview illustrates how a `draggedConn` would connect to a `staticConn`, effectively replacing a `replacedBlock` that is currently connected to the `staticConn`. The method takes three parameters: `draggedConn` (the connection being dragged), `staticConn` (the stationary connection), and `replacedBlock` (the block being replaced). The method returns void.\n"]]