|
1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 #include "SENDAS2MTM.H" |
|
17 |
|
18 |
|
19 TInt CSendMtm::QueryCapability(TUid aCapability, TInt& aResponse) |
|
20 { |
|
21 TInt ret=KErrNone; |
|
22 switch (aCapability.iUid) |
|
23 { |
|
24 // supported |
|
25 case KUidMtmQuerySendAsMessageSendSupportValue: |
|
26 case KUidMtmQueryCanSendMsgValue: |
|
27 case KUidMtmQuerySupportAttachmentsValue: |
|
28 break; |
|
29 // supported with responses |
|
30 case KUidMtmQueryMaxBodySizeValue: |
|
31 aResponse = 0x100; |
|
32 break; |
|
33 case KUidMtmQuerySupportedBodyValue: |
|
34 aResponse = KMtm7BitBody|KMtm8BitBody|KMtm16BitBody; |
|
35 break; |
|
36 case KUidMtmQueryMaxTotalMsgSizeValue: |
|
37 aResponse = 0x2000; |
|
38 break; |
|
39 // not supported |
|
40 case KUidMtmQuerySupportsRecipientTypeValue: |
|
41 case KUidMtmQueryCanReceiveMsgValue: |
|
42 case KUidMtmQueryOffLineAllowedValue: |
|
43 default: |
|
44 ret=KErrNotSupported; |
|
45 break; |
|
46 } |
|
47 return ret; |
|
48 } |
|
49 |
|
50 void CSendMtm::SetSubjectL(const TDesC& /*aSubject*/) |
|
51 { |
|
52 } |
|
53 |
|
54 TUint CSendMtm::ValidateMessage(TMsvPartList /*aPartList*/) |
|
55 { |
|
56 return 0; |
|
57 } |
|
58 |
|
59 void CSendMtm::AddAddresseeL(TMsvRecipientType /*aType*/, const TDesC& /*aRealAddress*/) |
|
60 { |
|
61 User::Leave(KErrNotSupported); |
|
62 } |
|
63 |
|
64 void CSendMtm::AddAddresseeL(TMsvRecipientType /*aType*/, const TDesC& /*aRealAddress*/, const TDesC& /*aAlias*/) |
|
65 { |
|
66 User::Leave(KErrNotSupported); |
|
67 } |