Пример #1
0
  @Override
  protected void onResume() {
    super.onResume();

    EpiTime.getInstance().setCurrentActivity(this);
    EpiTime.getInstance().sendScreen("com.epitime.groupList");
    EpiTime.getInstance().sendEvent("GroupList", this.school, "");
  }
Пример #2
0
  public String readString(String key, String defaultValue) {
    if (!this.integerConfigs.containsKey(key)) {
      SaveUtils save = new SaveUtils(EpiTime.getInstance().getCurrentActivity());
      this.stringConfigs.put(key, save.readString(TAG + key, defaultValue));
    }

    return this.stringConfigs.get(key);
  }
Пример #3
0
  public Boolean readBoolean(String key, Boolean defaultValue) {
    if (!this.integerConfigs.containsKey(key)) {
      SaveUtils save = new SaveUtils(EpiTime.getInstance().getCurrentActivity());
      this.booleanConfigs.put(key, save.readBoolean(TAG + key, defaultValue));
    }

    return this.booleanConfigs.get(key);
  }
Пример #4
0
  @Override
  public void onCreate(Bundle savedInstanceState) {
    this.hasNoGroup = this.getIntent().getExtras().getBoolean("NoGroup");
    this.school = this.getIntent().getExtras().getString("School");
    this.layout = R.layout.activity_group_select;

    super.onCreate(savedInstanceState);
    EpiTime.getInstance().setCurrentActivity(this);

    if (hasNoGroup) {
      this.drawerToggle.isDrawerOpened = true;
      this.drawerLayout.openDrawer(Gravity.LEFT);
    }

    this.groupList = (ListView) this.findViewById(R.id.group_list);
    this.groupList.setOnItemClickListener(new OnGroupListItemClick());

    this.addHeaders();
    this.reloadListView();
  }
Пример #5
0
 public void writeString(String key, String val) {
   SaveUtils save = new SaveUtils(EpiTime.getInstance().getCurrentActivity());
   save.putString(TAG + key, val);
   save.commit();
   this.stringConfigs.put(key, val);
 }
Пример #6
0
 public void writeBoolean(String key, Boolean val) {
   SaveUtils save = new SaveUtils(EpiTime.getInstance().getCurrentActivity());
   save.putBoolean(TAG + key, val);
   save.commit();
   this.booleanConfigs.put(key, val);
 }
Пример #7
0
 public void writeInt(String key, Integer val) {
   SaveUtils save = new SaveUtils(EpiTime.getInstance().getCurrentActivity());
   save.putInt(TAG + key, val);
   save.commit();
   this.integerConfigs.put(key, val);
 }