| 401 | | [adiumOTREncryption notifyWithTitle:[NSString stringWithUTF8String:title] |
|---|
| 402 | | primary:[NSString stringWithUTF8String:primary] |
|---|
| 403 | | secondary:[NSString stringWithUTF8String:secondary]]; |
|---|
| | 399 | AIListContact *listContact = contactFromInfo(accountname, protocol, username); |
|---|
| | 400 | NSString *formattedUID = [listContact formattedUID]; |
|---|
| | 401 | |
|---|
| | 402 | [adiumOTREncryption notifyWithTitle:[adiumOTREncryption localizedOTRMessage:[NSString stringWithUTF8String:title] |
|---|
| | 403 | withUsername:formattedUID] |
|---|
| | 404 | primary:[adiumOTREncryption localizedOTRMessage:[NSString stringWithUTF8String:primary] |
|---|
| | 405 | withUsername:formattedUID] |
|---|
| | 406 | secondary:[adiumOTREncryption localizedOTRMessage:[NSString stringWithUTF8String:secondary] |
|---|
| | 407 | withUsername:formattedUID]]; |
|---|
| 786 | | } |
|---|
| 787 | | |
|---|
| 788 | | return localizedOTRMessage; |
|---|
| | 791 | |
|---|
| | 792 | } else if ([message isEqualToString:@"Private connection closed"]) { |
|---|
| | 793 | localizedOTRMessage = AILocalizedString(@"Private connectiion closed", nil); |
|---|
| | 794 | |
|---|
| | 795 | } else if ([message rangeOfString:@"has already closed his private connection to you"].location != NSNotFound) { |
|---|
| | 796 | localizedOTRMessage = [NSString stringWithFormat: |
|---|
| | 797 | AILocalizedString(@"%@'s private connection to you is closed.", "Statement that someone's private (encrypted) connection is closed."), |
|---|
| | 798 | username]; |
|---|
| | 799 | |
|---|
| | 800 | } else if ([message isEqualToString:@"Your message was not sent. Either close your private connection to him, or refresh it."]) { |
|---|
| | 801 | localizedOTRMessage = AILocalizedString(@"Your message was not sent. You should end the encrypted chat on your side or re-request encryption.", nil); |
|---|
| | 802 | } |
|---|
| | 803 | |
|---|
| | 804 | return (localizedOTRMessage ? localizedOTRMessage : message); |
|---|