Namespaces
Variants
Actions

Archived:シグナルインジケータを作成する方法

Jump to: navigation, search
Archived.png
Archived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.

We do not recommend Flash Lite development on current Nokia devices, and all Flash Lite articles on this wiki have been archived. Flash Lite has been removed from all Nokia Asha and recent Series 40 devices and has limited support on Symbian. Specific information for Nokia Belle is available in Flash Lite on Nokia Browser for Symbian. Specific information for OLD Series 40 and Symbian devices is available in the Flash Lite Developers Library.
Article Metadata

Compatibility
Platform(s): Flash Lite: 1.1, 2.x

Article
Translated:
Last edited: hamishwillee (14 May 2013)

シグナルインジケータの作成

  • 新しいムービークリップを作成します。
  • ムービークリップ中で、2つ以上のレイヤーを作成します。
    • ActionScript: このレイヤーでは、表示する必要があるレベル+1個(この例では8レベル選択するので、9フレーム作成する)のキーフレームを作成します。
    • Level:
      • 最初のフレームにおいて、最下位レベルに対応したレベルのバーを作成します。
      • 最後のフレームでキーフレームを作成し、最上位レベルに向けてレベルのバーを伸ばします。そして、モーショントゥイーンを追加します。
      • 最後のフレームで、状態"no network"に対応したインジケータを描画します。
    • Background: 全ての静的コンテンツを配置するためのレイヤーを追加します。
    • タイムラインは、次のようになります。Timeline signal.jpg
  • ActionScriptレイヤーの最初のキーフレームで、以下のコードを追加します。
levelsNumber=8;
signalMax = fscommand2("GetMaxSignalLevel");
signalLevel = Math.ceil(fscommand2("GetSignalLevel")*levelsNumber/signalMax);
networkstatus = fscommand2("GetNetworkStatus");
 
if (networkstatus == 0) { //If there is no network
signalLevel = levelsNumber + 1;
}
 
gotoAndPlay(signalLevel);
  • その他の全てのキーフレームで、以下のコードを追加します。
call(1);
  • このムービークリップを、シーン上に配置します。

Flash Lite 2.xで推奨するコードの改善

  • call(1): このアクションは、function ステートメントのために廃止されました。
This page was last modified on 14 May 2013, at 09:53.
124 page views in the last 30 days.
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved