0

Flash オブジェクトではない別のオブジェクトによって、Flash オブジェクト内のアクション スクリプトをどのようにトリガーしますか? たとえば、フラッシュ ベースのナビゲーション バーがあります。各ナビゲーション ボタンにカーソルを合わせると、そのボタンの目的を示すメッセージが表示ウィンドウに表示されます。このメッセージは情報提供のみを目的としています。ボタンをクリックしないと何も起こりません。

Web ページ上の別のオブジェクト (別の画像やボタンなど) にカーソルを合わせたときに、同じフラッシュ メッセージ領域に同じメッセージ表示効果を持たせたいと考えています。ただし、これらはフラッシュ ナビゲーション バーの一部ではありません。

4

1 に答える 1

0

You can create an interface on your SWF using ExternalInterface callbacks. That way, any script on the container - e.g. a JavaScript function on an HTML page - can call your SWF and pass it parameters or call a method to display your message.

If it's Flash to Flash (e.g. one SWF communicating with a different SWF) you can also go the ExternalInterface route (SWF->JS->SWF), but it's probably simpler to just use a LocalConnection instead. It also allows SWF in different pages to talk to each other.

于 2013-09-29T13:37:06.040 に答える