Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私はphonegapの使用に慣れていません
phonegap を使用して Android アプリケーションを作成したいと考えています。プログラムを初めて実行するときの別の開始ページをロードしたい URL1 (ユーザーがアプリ構成を設定できるようにする) を実行し、その後の実行で URL2 (現在の設定をロードする) を実行したい
どうやってやるの??
以下のコードを使用できます。
if(first) super.loadUrl("URL1"); else super.loadUrl("URL2");
あなたのonCreate()方法で。SharedPreferences最初の実行を検出するためのフラグとして「first」パラメータを入れます。
onCreate()
SharedPreferences