Join Now
Quality Rating:
  • Currently 0.0 / 5
(0.0 / 5 - 0 votes cast)
Expertise Level:
  • Currently 0.0 / 5
(0.0 / 5 - 0 votes cast)

This page was last modified 11:07, 10 September 2007.

TSS000729 - Adding custom menu items for a 3rd party MTM

From Forum Nokia Wiki

Subject: Adding custom menu items for a 3rd party MTM TSS000729
  Platform(s): Device(s), SW version(s):
S60 3rd Edition
S60 3rd Edition, FP1
 
Category: Symbian C++
Subcategory: Messaging, MTM
Description: Description:
It is possible to add custom menu items to the Options menu of the Messaging application for a 3rd party MTM message list.
Solution:
To add custom menu items to the message list:
  1) Specify either EMtudContextSpecific or EMtudRemoteOnly flag in the MTM-specific function array.
  2) Use the correct return value in the implementation of CBaseMtmUiData::OperationSupportedL() function.
This function is called by the messaging client to check if a particular operation is appropriate for the selected entries in the message list.
The following example code demonstrates these steps:
1) In UI Data MTM resource file:
    #include <mtud.rh>
    RESOURCE MTUD_FUNCTION r_mymtm_test_operation
        {
        functiontext = "Message command";
        command = ETxtuCommandMessage;
        flags = EMtudContextSpecific|
                EMtudAsynchronous|
                EMtudCommandTransferReceive;
        }
2) Implementation of OperationSupportedL() in the UI Data MTM:
    TInt CTxtiMtmUiData::OperationSupportedL( TInt aOperationId, const TMsvEntry& aContext ) const
      {
      TInt aReasonResourceId=0; // 0 means "operation is available"
      if (aContext.iMtm != KUidMsgTypeText)
        {
        return R_TEXTUD_NOT_SUPPORTED;
        }
    const TBool isMessage = (aContext.iType == KUidMsvMessageEntry);
    const TBool isService = (aContext.iType == KUidMsvServiceEntry);
    if (aOperationId == ETxtuCommandMessage)
        {
        // Only allow this command on local messages
        if ( (!isMessage) | (aContext.iServiceId != KMsvLocalServiceIndexEntryId) )
            aReasonResourceId = R_TEXTUD_ONLY_MESSAGES;
        }
    return aReasonResourceId;
        }
Creation date: August 23, 2007
Last modified: -
Related Discussions
Thread Thread Starter Forum Replies Last Post
Sync groups in phone book with categories in Outlook kabkab PC Suite API and PC Connectivity SDK 6 2006-10-26 02:16
Custom menu entry njonesy General Symbian C++ 0 2005-05-30 08:23
6021 GPRS Configuration Settings namlek12345 General Discussion 2 2006-07-06 19:49
MTM registering fails on certain rom versions (s60 3rd) blizzz Symbian Networking & Messaging 3 2006-05-22 16:52
custom menu control vickey Symbian User Interface 1 2008-02-18 15:28
 
Powered by MediaWiki
     
     RDF Facets:
     
     
     qfnZtopicQUqfnTopicZmessagingQ
     qfnZtypeQUqfnTypeZCommunityContentQ
     qfnZtypeQUqfnTypeZKnowledgeBaseContentQ
     qfnZtypeQUqfnTypeZTechnicalSolutionQ
     qfnZtypeQUqfnTypeZWebpageQ
     qfnZtypeQUqfnTypeZWikiContentQ
     qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX