⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mmsexample.h

📁 使用c编写的彩信mms程序。很不错
💻 H
字号:
/*

        MMSExample.H - header file for MMSExample application
        

*/

#ifndef __MMSEXAMPLE_H__
#define __MMSEXAMPLE_H__

#if !defined(__AKNVIEW_H__)
#include <aknview.h>                        // for CAknView
#endif

#if !defined(__AKNVIEWAPPUI_H__)
#include <aknviewappui.h>                   // for CAknViewAppUi
#endif

#if !defined(__EIKAPP_H__) 
#include <eikapp.h>                         // for CEikApplication
#endif

#if !defined(__EIKDOC_H__)
#include <eikdoc.h>                         // for CEikDocument
#endif

#if !defined(__MSVAPI_H__)
#include <msvapi.h>                         // for MMsvSessionObserver 
#endif

#if !defined(__MMSCLIENT_H__)
#include <mmsclient.h>                      // for CMmsClientMtm
#endif


// Forward declarations
class CClientMtmRegistry;
class CMsvSession;



//
// Container class to draw text on screen
//
class CMMSExampleContainer : public CCoeControl
    {
public:
    void ConstructL();
private:
    void Draw(const TRect& aRect) const;
    };

//
// Application View class
//
class CMMSExampleAppView : public CAknView
    {
public:
    static CMMSExampleAppView* NewL();
    static CMMSExampleAppView* NewLC(); 
    ~CMMSExampleAppView();
public:
    TUid Id() const;
protected:
private:
    void DoActivateL(const TVwsViewId& /*aPrevViewId*/, TUid /*aCustomMessageId*/, const TDesC8& /*aCustomMessage*/);
    void DoDeactivate();
private:
    CMMSExampleAppView();
    void ConstructL();
private:
    CMMSExampleContainer* iContainer;
    };


//
// Application Ui class, this contains all application functionality
//
class CMMSExampleAppUi : public CAknViewAppUi, public MMsvSessionObserver
    {
public:
    void ConstructL();
    ~CMMSExampleAppUi();
    void HandleCommandL(TInt aCommand);

private:
    void CompleteConstructL();
    void CmdSendL();
    void CmdExitL();
    TBool InitializeCommunicationsL();
    void CreateNewMessageL();
    TBool SendMessageL();

private:    // from MMsvSessionObserver
    void HandleSessionEventL(TMsvSessionEvent aEvent, TAny* aArg1, TAny* aArg2, TAny* aArg3);
    
private:
    HBufC* iRecipient;              // recipients address
    CMsvSession* iSession;          // Client session on the message server
    CMmsClientMtm* iMmsMtm;         // Message Type Module (MMS)
    CClientMtmRegistry* iMtmReg;    // Mtm client registry for creating new mtms
    };


//
// Application document class
//
class CMMSExampleDocument : public CEikDocument
    {
public:
    static CMMSExampleDocument* NewL(CEikApplication& aApp);
    CEikAppUi* CreateAppUiL();
protected:
private:
    CMMSExampleDocument(CEikApplication& aApp);
    void ConstructL();
    };


//
// Application class
//
class CMMSExampleApplication : public CEikApplication
    {
public:
    TUid AppDllUid() const;
private:
    CApaDocument* CreateDocumentL();
    };


#endif // __MMSEXAMPLE_H__

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -