Skip to content
This repository has been archived by the owner on Sep 21, 2021. It is now read-only.

Commit

Permalink
fix(application): check installed package on realtime
Browse files Browse the repository at this point in the history
Signed-off-by: Rafa Hernandez <[email protected]>
  • Loading branch information
rafaelje authored and Hector Rondon committed May 11, 2018
1 parent 4650170 commit b85a827
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,15 @@ public View getView(int position, View convertView, ViewGroup parent) {

TextView txtStatus = vi.findViewById(R.id.txtStatus);

String status = parent.getResources().getString(R.string.app_installed);
String status;
if(app.appStatus.equals("1")) {
status = parent.getResources().getString(R.string.app_pending);
} else {
if(Helpers.isPackageInstalled(parent.getContext(), app.appPackage)) {
status = parent.getResources().getString(R.string.app_installed);
} else {
status = parent.getResources().getString(R.string.app_not_installed);
}
}

txtStatus.setText(status);
Expand Down

0 comments on commit b85a827

Please sign in to comment.