@Override
 protected void onPostExecute(Drawable result) {
   if (result != null) {
     if (skillView != null) skillView.setSkillImage(result);
     if (passiveSkillView != null) passiveSkillView.setSkillImage(result);
   }
 }
  @Override
  public View onCreateView(
      LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    HashMap<String, Integer> runes = new HashMap<String, Integer>();
    runes.put("a", R.drawable.rune_a);
    runes.put("b", R.drawable.rune_b);
    runes.put("c", R.drawable.rune_c);
    runes.put("d", R.drawable.rune_d);
    runes.put("e", R.drawable.rune_e);

    View view = inflater.inflate(R.layout.skills_fragment, container, false);
    List<Skill> activeSkills =
        CareerProfile.getActiveProfile().getActiveHero().getSkills(Skill.ACTIVE_SKILL);

    for (int i = 0; i < skillsViewsIds.length; i++) {
      SkillView skillView = (SkillView) view.findViewById(skillsViewsIds[i]);
      final Skill skill = activeSkills.get(i);
      if (skill.getSkillInfo() != null) {
        skillView.setSkillName(skill.getSkillInfo().getName());
        if (skill.getRune() != null) {
          skillView.setRuneImage(getResources().getDrawable(runes.get(skill.getRune().getType())));
          skillView.setRuneName(skill.getRune().getName());
        }

        skillView.setOnClickListener(
            new OnClickListener() {

              @Override
              public void onClick(View v) {
                Intent intent = new Intent(getActivity(), TooltipWebViewActivity.class);
                intent.putExtra(TooltipWebViewActivity.URL, skill.createTooltipLink());
                startActivity(intent);
              }
            });

        try {
          new SkillImageLoad(skillView).execute(skill.getSkillInfo().createImageLink());
        } catch (MalformedURLException e) {
          Log.d(TAG, e.getMessage());
        }
      }
    }

    List<Skill> passiveSkills =
        CareerProfile.getActiveProfile().getActiveHero().getSkills(Skill.PASSIVE_SKILL);
    for (int i = 0; i < passvieSkillsViewsIds.length; i++) {
      PassiveSkillView skillView = (PassiveSkillView) view.findViewById(passvieSkillsViewsIds[i]);
      final Skill skill = passiveSkills.get(i);
      if (skill.getSkillInfo() != null) {
        skillView.setSkillName(skill.getSkillInfo().getName());

        skillView.setOnClickListener(
            new OnClickListener() {

              @Override
              public void onClick(View v) {
                Intent intent = new Intent(getActivity(), TooltipWebViewActivity.class);
                intent.putExtra(TooltipWebViewActivity.URL, skill.createTooltipLink());
                startActivity(intent);
              }
            });

        try {
          new SkillImageLoad(skillView).execute(skill.getSkillInfo().createImageLink());
        } catch (MalformedURLException e) {
          Log.d(TAG, e.getMessage());
        }
      }
    }

    return view;
  }