The Names Default To Here( 1 ); function makes all unscoped variables in the script local to that script and does not affect the global variable namespace. “Advanced Scoping and Namespaces” on page 252 provides more details.
注意:The Names Default to Here option is true by default for custom menus and toolbar buttons. A script that runs when you select a custom menu item or click a custom toolbar button does not affect global variables.