Exemplo n.º 1
0
  private FilesActivityModel parseIntent() {
    FilesActivityModel model = new FilesActivityModel();

    model.setFolderId(getIntent().getIntExtra(KEY_FOLDER_ID, 0));

    model.setFolderName(getIntent().getStringExtra(KEY_FOLDER_NAME));

    String mode = getIntent().getStringExtra(KEY_MEDIA_MODE);
    model.setMediaFilterMode(MediaFilterMode.valueOf(mode));

    return model;
  }
Exemplo n.º 2
0
  private FilesActivityModel parseBundle(Bundle bundle) {
    FilesActivityModel model = new FilesActivityModel();

    model.setFolderId(bundle.getInt(KEY_FOLDER_ID, 0));

    model.setFolderName(bundle.getString(KEY_FOLDER_NAME));

    String mode = bundle.getString(KEY_MEDIA_MODE);
    model.setMediaFilterMode(MediaFilterMode.valueOf(mode));

    return model;
  }