Ejemplo n.º 1
0
 @Override
 protected void onResume() {
   CacheService.setCurConv(conversation);
   ChatManagerAdapterImpl chatManagerAdapter =
       (ChatManagerAdapterImpl) ChatManager.getInstance().getChatManagerAdapter();
   chatManagerAdapter.cancelNotification();
   super.onResume();
 }
Ejemplo n.º 2
0
 @Override
 protected void onActivityResult(int requestCode, int resultCode, Intent intent) {
   super.onActivityResult(requestCode, resultCode, intent);
   if (resultCode == RESULT_OK) {
     switch (requestCode) {
       case LOCATION_REQUEST:
         final double latitude = intent.getDoubleExtra(LocationActivity.LATITUDE, 0);
         final double longitude = intent.getDoubleExtra(LocationActivity.LONGITUDE, 0);
         final String address = intent.getStringExtra(LocationActivity.ADDRESS);
         if (!TextUtils.isEmpty(address)) {
           messageAgent.sendLocation(latitude, longitude, address);
         } else {
           toast(R.string.chat_cannotGetYourAddressInfo);
         }
         hideBottomLayout();
         break;
     }
   }
 }
Ejemplo n.º 3
0
 @Override
 protected void onDestroy() {
   CacheService.setCurConv(null);
   super.onDestroy();
 }
Ejemplo n.º 4
0
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   initLocation();
 }
Ejemplo n.º 5
0
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   addLocationBtn.setVisibility(View.VISIBLE);
   //    addLocationBtn.setVisibility(View.GONE);
 }