Closed GoogleCodeExporter closed 9 years ago
I can confirm the beginning of the issue, but I don't see what your last point
about the outbox means.
Original comment by chm.duquesne
on 19 Sep 2010 at 8:26
When you send a long sms, it is appended in full multiple time in the sms
outbox.
En français, je réussirais peut-être mieux... quand on envoie un SMS, il
apparaît bien dans les messages envoyés de l'application SMS. S'il est trop
gros (>160 caractères), il est coupé à l'envoi mais pas à l'ajout dans les
messages envoyés : il y a donc plusieurs fois le même gros message à la fois
dans les archives, ce qui ne facilite pas forcément leur consultation.
Pour tester : envoyer un gros message (genre 5-6 sms) à quelqu'un, puis
regarder dans l'application la façon dont ils ont été enregistrés. Mais il
s'agit en fait de deux "issues" distinctes !
Original comment by neam...@gmail.com
on 19 Sep 2010 at 8:56
Ok, I get it.
Well, the top priority is not on this right now, because there are bugs that
are more annoying, but this one will be fixed.
Original comment by chm.duquesne
on 19 Sep 2010 at 9:23
Issue 66 has been merged into this issue.
Original comment by chm.duquesne
on 6 Oct 2010 at 1:37
This is a very obvious (annoying) bug with a very simple code fix.
The method that sends SMSes splits them up, then loops through each part, and
sends a separate SMS for each part (why?!). Furthermore, for a reason unknown,
in each iteration of the loop the *FULL* SMS is added to your phone's sent
items. This is why you get duplicates.
The SmsManager class has a method to send a multipart SMS, passing it an
ArrayList<String> containing the parts (as returned by the method that splits
them up) so I don't know why the author decided to completely ignore this
feature and use the basic SMS sending method instead.
Original comment by sea...@gmail.com
on 7 Oct 2010 at 9:46
Yeah, I'll fix that. My only problem is when I do that it messes up the
emulator. Maybe it does not do that on real phones...
Original comment by chm.duquesne
on 7 Oct 2010 at 9:53
@chm.duquesne That's a known bug in the emulator, multipart sms works well on
devices though: http://code.google.com/p/android/issues/detail?id=3539
Original comment by erikdeno...@gmail.com
on 7 Oct 2010 at 10:57
Why are you using telephony.gsm.SmsManager anyway, it's deprecated?
telephony.SmsManager supports GSM and CDMA.
Original comment by anonym1970
on 7 Oct 2010 at 11:47
Because I aim at supporting every phones starting from 1.5. (I personally have
an old android phone).
Original comment by chm.duquesne
on 7 Oct 2010 at 11:54
can be easily done with the sms divide or send multi part msg
Original comment by atlrudeb...@gmail.com
on 7 Oct 2010 at 10:35
There is the patch for this purpose : in revision a4320279b9e9 (before drastic
changes of talkmyphone core (i.e. Beta 2.06)) change sendSMSByPhoneNumber
function from com.googlecode.talkmyphone.SmsMmsManager.java by :
public static void sendSMSByPhoneNumber(String message, String phoneNumber) {
//send("Sending sms to " + getContactName(phoneNumber));
SmsManager sms = SmsManager.getDefault();
ArrayList<String> messages = sms.divideMessage(message);
//création des liste d'instents
ArrayList<PendingIntent> listOfSentIntents = new ArrayList<PendingIntent>();
listOfSentIntents.add(sentPI);
ArrayList<PendingIntent> listOfdelIntents = new ArrayList<PendingIntent>();
listOfdelIntents.add(deliveredPI);
for (int i=1; i < messages.size(); i++){
listOfSentIntents.add(null);
listOfdelIntents.add(null);
}
sms.sendMultipartTextMessage(phoneNumber, null, messages, listOfSentIntents, listOfdelIntents);
addSmsToSentBox(message, phoneNumber);
}
This will send the long sms in a multipart manner, add only one instance in the
outbox, and display only one notification for "message sent" and "delivered"
And it should work from Android 1.5 ...
Regards,
Y.
Original comment by yoanjacq...@gmail.com
on 2 Dec 2010 at 2:56
Fix with yoanjacquemin solution.
The project has migrate at http://code.google.com/p/gtalksms
Original comment by Florent....@gmail.com
on 11 Dec 2010 at 11:39
Original issue reported on code.google.com by
neam...@gmail.com
on 18 Sep 2010 at 12:02