瀏覽代碼

pastojs: typecast function to TJSFunction

git-svn-id: trunk@39208 -
Mattias Gaertner 7 年之前
父節點
當前提交
118ec57000
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      utils/pas2js/docs/translation.html

+ 4 - 0
utils/pas2js/docs/translation.html

@@ -2540,6 +2540,10 @@ End.
       <li>An external class can descend from another external class.</li>
       <li>Since class types are JS objects it is possible to typecast a class type
       to the JS Object, e.g. TJSObject(TObject)</li>
+      <li>You can typecast function addresses and function references to JS
+      function, e.g. <i>TJSFunction(@SomeProc)</i>, <i>TJSFunction(OnClick)</i>.
+      Keep in mind that typecasting a method address creates a function wrapper
+      to bind the Self argument.</li>
     </ul>
     </div>