Guest User

Untitled

a guest
Jun 23rd, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.13 KB | None | 0 0
  1. @Override
  2. public View getView(int position, View convertView, ViewGroup parent) {
  3.  
  4. MenuList item = menuItemList.get(position); // getItem(position);
  5. View view = convertView;
  6. // if (convertView == null) {
  7. view = inflater.inflate(resourceid, null);
  8. // view.getBackground().setAlpha(15);
  9. synchronized (view) {
  10. ImageView imgBg = (ImageView) view
  11. .findViewById(R.id.ivCotnentItem);
  12. // view.setLayoutParams(mParam);
  13. view.setPadding(5, 0, 5, 0);
  14. if (position >= imageList.size()) {
  15. imageList.add(Utils.getImageFromApplicationFolder(
  16. thisContext, item.bgImage, null));
  17. }
  18. imgBg.setImageDrawable(imageList.get(position));
  19. imgBg.setLayoutParams(mParamImage);
  20. TextView tvCaption = (TextView) view
  21. .findViewById(R.id.tvCaption);
  22. tvCaption.setText(item.caption);
  23. if (!textColor.equals(""))
  24. tvCaption.setTextColor(Color.parseColor("#" + textColor));
  25. // tvCaption.setTypeface(tfItemFont);
  26. tvCaption.setTextSize(20);
  27. // tvCaption.setPadding(0, 0, 0, 5);
  28. // Log.v("tvCaption" + tvCaption.getText(), "log1");
  29. return view;
  30. }
  31. }
Add Comment
Please, Sign In to add comment