messagingapp/msgui/unifiedviewer/inc/univiewerattachmentcontainer.h
branchGCC_SURGE
changeset 47 5b14749788d7
parent 35 a32b19fb291e
parent 44 36f374c67aa8
equal deleted inserted replaced
35:a32b19fb291e 47:5b14749788d7
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  This holds all the attachments inside convergedmessage
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef UNIVIEWERATTACHMENTCONTAINER_H
       
    19 #define UNIVIEWERATTACHMENTCONTAINER_H
       
    20 
       
    21 // SYSTEM INCLUDES
       
    22 #include <HbWidget>
       
    23 #include <QList>
       
    24 
       
    25 // FORWARD DECLARATIONS
       
    26 class QGraphicsLinearLayout;
       
    27 class UniViewerMediaWidget;
       
    28 
       
    29 //const int MAX_ATTACHMENT = 10;
       
    30 
       
    31 /**
       
    32  * Container widget for all attachment inside message
       
    33  */
       
    34 
       
    35 class UniViewerAttachmentContainer: public HbWidget
       
    36 {
       
    37 Q_OBJECT
       
    38 
       
    39 public:
       
    40 
       
    41     /**
       
    42      * Constructor
       
    43      */
       
    44     explicit UniViewerAttachmentContainer(QGraphicsItem *parent = 0);
       
    45 
       
    46     /**
       
    47      * Destructor
       
    48      */
       
    49     virtual ~UniViewerAttachmentContainer();
       
    50 
       
    51     /**
       
    52      * Add one more attachment into the widget
       
    53      */
       
    54     void addAttachmentWidget(QString type, QString fileName);
       
    55 
       
    56     /**
       
    57      * Clears the content of the widget
       
    58      */
       
    59     void clearContent();
       
    60 
       
    61 private:
       
    62 
       
    63     /**
       
    64      * This contains total number of attacmnets added
       
    65      */
       
    66     int mTotalAttachment;
       
    67 
       
    68     /**
       
    69      * Main layout reference.
       
    70      * Own
       
    71      */
       
    72     QGraphicsLinearLayout *mMainLayout;
       
    73 
       
    74     /**
       
    75      * From widget reference.
       
    76      * Own
       
    77      */
       
    78     QList<UniViewerMediaWidget *> mUniViewerMediaWidgetList;
       
    79 
       
    80 };
       
    81 
       
    82 #endif // UNIVIEWERATTACHMENTCONTAINER_H
       
    83 //eof