mirror of
https://github.com/moparisthebest/Conversations
synced 2024-12-25 08:58:55 -05:00
Merge branch 'development' of https://github.com/siacs/Conversations into development
This commit is contained in:
commit
2abb57be34
@ -1,5 +1,11 @@
|
||||
###Changelog
|
||||
|
||||
####Version 0.2.2
|
||||
* Ability to take photos directly
|
||||
* Improved openPGP offline handling
|
||||
* Various bug fixes
|
||||
* Updated Translations
|
||||
|
||||
####Version 0.2.1
|
||||
* Various bug fixes
|
||||
* Updated Translations
|
||||
|
@ -7,5 +7,7 @@
|
||||
<item
|
||||
android:id="@+id/attach_take_picture"
|
||||
android:title="@string/attach_take_picture"/>
|
||||
|
||||
<item
|
||||
android:id="@+id/attach_record_voice"
|
||||
android:title="@string/attach_record_voice" />
|
||||
</menu>
|
@ -163,5 +163,6 @@
|
||||
<string name="mgmt_account_delete">Löschen</string>
|
||||
<string name="mgmt_account_disable">Vorübergehend abschalten</string>
|
||||
<string name="mgmt_account_enable">Anschalten</string>
|
||||
<string name="attach_record_voice">Sprache aufzeichnen</string>
|
||||
|
||||
</resources>
|
@ -163,5 +163,6 @@
|
||||
<string name="mgmt_account_delete">Delete</string>
|
||||
<string name="mgmt_account_disable">Temporarily disable</string>
|
||||
<string name="mgmt_account_enable">Enable</string>
|
||||
<string name="attach_record_voice">Record voice</string>
|
||||
|
||||
</resources>
|
@ -66,11 +66,13 @@ public class ConversationActivity extends XmppActivity {
|
||||
public static final int REQUEST_DECRYPT_PGP = 0x76783;
|
||||
private static final int REQUEST_ATTACH_FILE_DIALOG = 0x48502;
|
||||
private static final int REQUEST_IMAGE_CAPTURE = 0x33788;
|
||||
private static final int REQUEST_RECORD_AUDIO = 0x46189;
|
||||
private static final int REQUEST_SEND_PGP_IMAGE = 0x53883;
|
||||
public static final int REQUEST_ENCRYPT_MESSAGE = 0x378018;
|
||||
|
||||
private static final int ATTACHMENT_CHOICE_CHOOSE_IMAGE = 0x92734;
|
||||
private static final int ATTACHMENT_CHOICE_TAKE_PHOTO = 0x84123;
|
||||
private static final int ATTACHMENT_CHOICE_RECORD_VOICE = 0x75291;
|
||||
|
||||
protected SlidingPaneLayout spl;
|
||||
|
||||
@ -352,6 +354,9 @@ public class ConversationActivity extends XmppActivity {
|
||||
attachFileIntent.setAction(Intent.ACTION_GET_CONTENT);
|
||||
Intent chooser = Intent.createChooser(attachFileIntent, getString(R.string.attach_file));
|
||||
startActivityForResult(chooser, REQUEST_ATTACH_FILE_DIALOG);
|
||||
} else if (attachmentChoice==ATTACHMENT_CHOICE_RECORD_VOICE) {
|
||||
Intent intent = new Intent(MediaStore.Audio.Media.RECORD_SOUND_ACTION);
|
||||
startActivityForResult(intent, REQUEST_RECORD_AUDIO);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -452,6 +457,9 @@ public class ConversationActivity extends XmppActivity {
|
||||
case R.id.attach_take_picture:
|
||||
attachFile(ATTACHMENT_CHOICE_TAKE_PHOTO);
|
||||
break;
|
||||
case R.id.attach_record_voice:
|
||||
attachFile(ATTACHMENT_CHOICE_RECORD_VOICE);
|
||||
break;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
@ -583,7 +583,7 @@ public class ConversationFragment extends Fragment {
|
||||
ConversationActivity activity = (ConversationActivity) getActivity();
|
||||
if (this.conversation != null) {
|
||||
for (Message message : this.conversation.getMessages()) {
|
||||
if (message.getEncryption() == Message.ENCRYPTION_PGP) {
|
||||
if ((message.getEncryption() == Message.ENCRYPTION_PGP)&&((message.getStatus() == Message.STATUS_RECIEVED)||(message.getStatus() == Message.STATUS_SEND))) {
|
||||
decryptMessage(message);
|
||||
break;
|
||||
}
|
||||
|
@ -21,7 +21,6 @@ import java.util.HashSet;
|
||||
import java.util.Hashtable;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import javax.net.ssl.SSLContext;
|
||||
@ -547,7 +546,8 @@ public class XmppConnection implements Runnable {
|
||||
Log.d(LOGTAG,account.getJid()+": sending deprecated session");
|
||||
IqPacket startSession = new IqPacket(IqPacket.TYPE_SET);
|
||||
startSession.addChild("session","urn:ietf:params:xml:ns:xmpp-session"); //setContent("")
|
||||
this.sendIqPacket(startSession, null);
|
||||
startSession.setId(nextRandomId());
|
||||
this.sendPacket(startSession, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user