|
Spec-Zone .ru
спецификации, руководства, описания, API
|
Pseudo-variables are pre-defined variable definitions. They are script-level defs and thus cannot be assigned to. Currently there are three:
__PROFILE__ is either one of "mobile", "desktop" or "browser" depending on which environment the script is executing in.
__FILE__ is the string representation of the URL from which the script containing the __FILE__ was loaded.
__DIR__ is the string representation of the URL of the directory from which the script containing the __DIR__ was loaded.
They are typically used to reference resource files stored along side the compiled sources. So if the script Foo.fx is compiled, and the resultant Foo.class is placed in the same directory with myIcon.gif, it might be accessed in Foo.fx with:
Image {
url: "{__DIR__}myIcon.gif"
}