@Override
    public void onReceive(Context context, Intent intent) {
      // TODO Auto-generated method stub
      Log.d("Session:", intent.getAction());
      if (ACTION_FRIENDED.equals(intent.getAction())) {
        initAdaperView();
      } else if (NotifyChatMessage.ACTION_NOTIFY_CHAT_MESSAGE.equals(intent.getAction())) {
        SessionList sessionList =
            (SessionList)
                intent.getSerializableExtra(NotifyChatMessage.EXTRAS_NOTIFY_SESSION_MESSAGE);
        if (sessionList == null) {
          return;
        }

        SessionVo tempSessionVo = new SessionVo();
        tempSessionVo.setSessionList(sessionList);
        List<SessionVo> sessionVos = adapter.getSessionVos();
        int index = sessionVos.indexOf(tempSessionVo);
        if (index != -1) {
          SessionVo mySessionVo = sessionVos.get(index);
          tempSessionVo.setCustomerVo(mySessionVo.getCustomerVo());
          sessionVos.remove(mySessionVo);
          sessionVos.add(index, tempSessionVo);
        } else {
          CustomerVo customerVo = getFinalDb().findById(sessionList.getFuid(), CustomerVo.class);
          if (customerVo != null) {
            tempSessionVo.setCustomerVo(customerVo);
            sessionVos.add(0, tempSessionVo);
          }
        }

        Collections.sort(sessionVos, mSessionComparator);

        handler.post(
            new Runnable() {

              @Override
              public void run() {
                adapter.notifyDataSetInvalidated();
                try {
                  // IndexTabActivity.getInstance()
                  // .sessionPromptUpdate();
                  getActivity().sendBroadcast(new Intent(IndexTabActivity.ACTION_REFRESH_SESSION));
                } catch (Exception e) {

                }
              }
            });
      }
    }