@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_help_er_call_details); Bundle extras = getIntent().getExtras(); String userID = extras.getString("USER_ID"); UserInterface mUser = UserManager.getInstance().getUserById(userID); if (mUser == null) { throw new NullPointerException( LOGTAG + ": User with ID " + userID + " could not be retrieved from Extras-Bundle at onCreate()"); } TextView name = (TextView) findViewById(R.id.tv_help_ee_name); name.setText(Html.fromHtml(name.getText() + " " + mUser.getName())); TextView age = (TextView) findViewById(R.id.tv_help_ee_age); age.setText(Html.fromHtml(age.getText() + " " + mUser.getAge())); TextView gender = (TextView) findViewById(R.id.tv_help_ee_gender); if (mUser.getGender().equalsIgnoreCase("female")) { gender.setText(Html.fromHtml(gender.getText() + " " + getString(R.string.female))); } else { gender.setText(Html.fromHtml(gender.getText() + " " + getString(R.string.male))); } ImageView picture = (ImageView) findViewById(R.id.iv_help_ee_picture); picture.setImageDrawable( new LayerDrawable( ImageUtility.retrieveDrawables(getApplicationContext(), mUser.getPicture()))); picture.setOnClickListener( new OnClickListener() { @Override public void onClick(View v) { setZoomLevel(); } }); mHandler = new Handler(); initMaps(mUser); TaskManager.getInstance().addTaskEventListener(this); }
@Override protected void onResume() { super.onResume(); setDefaulAppearance(); }