~boiko/messaging-app/rtm-fix_1373479

« back to all changes in this revision

Viewing changes to src/qml/MMSDelegate.qml

Remove multiple entries all at once instead of using multiple calls. Fixes: #1404286

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 * Copyright 2012, 2013, 2014 Canonical Ltd.
 
2
 * Copyright 2012-2015 Canonical Ltd.
3
3
 *
4
4
 * This file is part of messaging-app.
5
5
 *
40
40
 
41
41
    function deleteMessage()
42
42
    {
43
 
        eventModel.removeEvent(messageData.accountId,
44
 
                               messageData.threadId,
45
 
                               messageData.eventId,
46
 
                               messageData.type)
 
43
        eventModel.removeEvents([messageData.properties]);
47
44
    }
48
45
 
49
46
    function resendMessage()
65
62
            attachment.push(item.filePath)
66
63
            newAttachments.push(attachment)
67
64
        }
68
 
        eventModel.removeEvent(messageData.accountId,
69
 
                               messageData.threadId,
70
 
                               messageData.eventId,
71
 
                               messageData.type)
 
65
        eventModel.removeEvents([messageData.properties]);
72
66
        // FIXME: export this information for MessageDelegate
73
67
        chatManager.sendMMS(participants, textMessage, newAttachments, messages.account.accountId)
74
68
    }