Back to project page Do-not-get-annoyed.
The source code is released under:
Apache License
If you think the Android project Do-not-get-annoyed listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package mn100013d.pmu; //from w w w . ja va 2 s . c om import mn100013d.pmu.exceptions.PlayerNotRegisteredException; import mn100013d.pmu.services.FragmentProvider; import mn100013d.pmu.services.SoundService; import android.os.Bundle; import android.support.v4.app.FragmentActivity; import android.view.Menu; public class BeginingActivity extends FragmentActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_begining); FragmentProvider.getInstance().setContext(this); FragmentProvider.getInstance().setContainerId(R.id.fragment_container); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.begining, menu); return true; } @Override protected void onPause() { try { SoundService.getInstance().stop(SoundService.JINGLE); } catch (PlayerNotRegisteredException e) { // TODO Auto-generated catch block e.printStackTrace(); } finish(); super.onPause(); } @Override protected void onResume() { try { SoundService.getInstance().play(SoundService.JINGLE, true); } catch (PlayerNotRegisteredException e) { // TODO Auto-generated catch block e.printStackTrace(); } super.onResume(); } }