Exemplo n.º 1
0
 private void showSectorNotes() {
   Intent intent = new Intent(this, SectorNotesActivity.class);
   intent.putExtra("system", currentSector.getSystem());
   intent.putExtra("alpha", currentSector.getAplhaCoord());
   intent.putExtra("num", currentSector.getNumCoord());
   startActivity(intent);
 }
Exemplo n.º 2
0
  @Override
  public void onPause() {
    super.onPause();
    // Save the needed preferences
    SharedPreferences.Editor editor = getSharedPreferences(PREFS_NAME, 0).edit();
    // Load the selected items
    Sector selected = getSelectedSector();
    // Dump them all into the right places and save
    editor.putString(PREF_LAST_SYSTEM, selected.getSystem());
    editor.putString(PREF_LAST_SECTOR_APLHA, selected.getAplhaCoord());
    editor.putString(PREF_LAST_SECTOR_NUM, selected.getNumCoord());
    editor.commit();

    data.close();
  }