added presence selection

This commit is contained in:
Daniel Gultsch 2014-05-13 17:42:23 +02:00
parent 888de850cf
commit a1a90a03e0

View File

@ -354,11 +354,25 @@ public class ConversationActivity extends XmppActivity {
} }
private void takePicture() { private void takePicture() {
selectPresence(getSelectedConversation(), new OnPresenceSelected() {
@Override
public void onPresenceSelected(boolean success, String presence) {
if (success) {
Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, ImageProvider.getIncomingContentUri()); takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, ImageProvider.getIncomingContentUri());
if (takePictureIntent.resolveActivity(getPackageManager()) != null) { if (takePictureIntent.resolveActivity(getPackageManager()) != null) {
startActivityForResult(takePictureIntent, REQUEST_IMAGE_CAPTURE); startActivityForResult(takePictureIntent, REQUEST_IMAGE_CAPTURE);
} }
}
}
@Override
public void onSendPlainTextInstead() {
// TODO Auto-generated method stub
}
},"file");
} }