videocollection/hgmyvideos/src/vcxhgmyvideosvideodata.cpp
changeset 0 96612d01cf9f
equal deleted inserted replaced
-1:000000000000 0:96612d01cf9f
       
     1 /*
       
     2 * Copyright (c) 2008 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 the License "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:   CVcxHgMyVideosVideoData class implementation*
       
    15 */
       
    16 
       
    17 
       
    18 
       
    19 
       
    20 // INCLUDE FILES
       
    21 #include "vcxhgmyvideosvideodata.h"
       
    22 
       
    23 // ============================ MEMBER FUNCTIONS ===============================
       
    24 
       
    25 // -----------------------------------------------------------------------------
       
    26 // CVcxHgMyVideosVideoData::NewL()
       
    27 // -----------------------------------------------------------------------------
       
    28 //
       
    29 CVcxHgMyVideosVideoData* CVcxHgMyVideosVideoData::NewL()
       
    30     {
       
    31     CVcxHgMyVideosVideoData* self = 
       
    32         CVcxHgMyVideosVideoData::NewLC();
       
    33     CleanupStack::Pop( self );
       
    34     return self;
       
    35     }
       
    36 
       
    37 // -----------------------------------------------------------------------------
       
    38 // CVcxHgMyVideosVideoData::NewLC()
       
    39 // -----------------------------------------------------------------------------
       
    40 //
       
    41 CVcxHgMyVideosVideoData* CVcxHgMyVideosVideoData::NewLC()
       
    42     {
       
    43     CVcxHgMyVideosVideoData* self = 
       
    44         new (ELeave) CVcxHgMyVideosVideoData();
       
    45     CleanupStack::PushL( self );
       
    46     self->ConstructL();
       
    47     return self;
       
    48     }
       
    49 
       
    50 // -----------------------------------------------------------------------------
       
    51 // CVcxHgMyVideosVideoData::CVcxHgMyVideosVideoData()
       
    52 // -----------------------------------------------------------------------------
       
    53 //
       
    54 CVcxHgMyVideosVideoData::CVcxHgMyVideosVideoData()
       
    55     {
       
    56     }
       
    57 
       
    58 // -----------------------------------------------------------------------------
       
    59 // CVcxHgMyVideosVideoData::ConstructL()
       
    60 // -----------------------------------------------------------------------------
       
    61 //
       
    62 void CVcxHgMyVideosVideoData::ConstructL()
       
    63     {
       
    64     }
       
    65 
       
    66 // -----------------------------------------------------------------------------
       
    67 // CVcxHgMyVideosVideoData::~CVcxHgMyVideosVideoData()
       
    68 // -----------------------------------------------------------------------------
       
    69 //
       
    70 CVcxHgMyVideosVideoData::~CVcxHgMyVideosVideoData()
       
    71     {
       
    72     delete iThumbnail;
       
    73     }
       
    74 
       
    75 // -----------------------------------------------------------------------------
       
    76 // CVcxHgMyVideosVideoData::MPXItemId()
       
    77 // -----------------------------------------------------------------------------
       
    78 //
       
    79 TMPXItemId CVcxHgMyVideosVideoData::MPXItemId()
       
    80     {
       
    81     return iMPXItemId;
       
    82     }
       
    83 
       
    84 // -----------------------------------------------------------------------------
       
    85 // CVcxHgMyVideosVideoData::State()
       
    86 // -----------------------------------------------------------------------------
       
    87 //
       
    88 CVcxHgMyVideosVideoData::TVideoDataState CVcxHgMyVideosVideoData::State()
       
    89     {
       
    90     return iState;
       
    91     }   
       
    92 
       
    93 // -----------------------------------------------------------------------------
       
    94 // CVcxHgMyVideosVideoData::ThumbnailConversionId()
       
    95 // -----------------------------------------------------------------------------
       
    96 //
       
    97 TInt CVcxHgMyVideosVideoData::ThumbnailConversionId()
       
    98     {
       
    99     return iConversionId;
       
   100     }
       
   101 
       
   102 // -----------------------------------------------------------------------------
       
   103 // CVcxHgMyVideosVideoData::Thumbnail()
       
   104 // -----------------------------------------------------------------------------
       
   105 //
       
   106 CFbsBitmap* CVcxHgMyVideosVideoData::Thumbnail( TBool aGiveOwnership )
       
   107     {
       
   108     CFbsBitmap* thumbnail = iThumbnail;
       
   109     if ( aGiveOwnership )
       
   110         {
       
   111         iThumbnail = NULL;
       
   112         }
       
   113     return thumbnail;
       
   114     }
       
   115 
       
   116 // -----------------------------------------------------------------------------
       
   117 // CVcxHgMyVideosVideoData::DrmProtected()
       
   118 // -----------------------------------------------------------------------------
       
   119 //
       
   120 TBool CVcxHgMyVideosVideoData::DrmProtected()
       
   121     {
       
   122     return iDrmProtected;
       
   123     }
       
   124 
       
   125 // -----------------------------------------------------------------------------
       
   126 // CVcxHgMyVideosVideoData::ValidDrmRights()
       
   127 // -----------------------------------------------------------------------------
       
   128 //
       
   129 TBool CVcxHgMyVideosVideoData::ValidDrmRights()
       
   130     {
       
   131     return iValidDrmRights;
       
   132     }
       
   133 
       
   134 // -----------------------------------------------------------------------------
       
   135 // CVcxHgMyVideosVideoData::SetMPXItemId()
       
   136 // -----------------------------------------------------------------------------
       
   137 //
       
   138 void CVcxHgMyVideosVideoData::SetMPXItemId( TMPXItemId aMPXItemId )
       
   139     {
       
   140     iMPXItemId = aMPXItemId;  
       
   141     }
       
   142 
       
   143 // -----------------------------------------------------------------------------
       
   144 // CVcxHgMyVideosVideoData::SetState()
       
   145 // -----------------------------------------------------------------------------
       
   146 //
       
   147 void CVcxHgMyVideosVideoData::SetState( CVcxHgMyVideosVideoData::TVideoDataState aState )
       
   148     {
       
   149     iState = aState;
       
   150     }
       
   151 
       
   152 // -----------------------------------------------------------------------------
       
   153 // CVcxHgMyVideosVideoData::SetThumbnailConversionId()
       
   154 // -----------------------------------------------------------------------------
       
   155 //
       
   156 void CVcxHgMyVideosVideoData::SetThumbnailConversionId( TInt aConversionId )
       
   157     {
       
   158     iConversionId = aConversionId;
       
   159     }
       
   160 
       
   161 // -----------------------------------------------------------------------------
       
   162 // CVcxHgMyVideosVideoData::SetThumbnail()
       
   163 // -----------------------------------------------------------------------------
       
   164 //
       
   165 void CVcxHgMyVideosVideoData::SetThumbnail( CFbsBitmap* aThumbnail )
       
   166     {
       
   167     delete iThumbnail;
       
   168     iThumbnail = aThumbnail;
       
   169     }
       
   170 
       
   171 // -----------------------------------------------------------------------------
       
   172 // CVcxHgMyVideosVideoData::SetDrmProtected()
       
   173 // -----------------------------------------------------------------------------
       
   174 //
       
   175 void CVcxHgMyVideosVideoData::SetDrmProtected( TBool aDrmProtected )
       
   176     {
       
   177     iDrmProtected = aDrmProtected;
       
   178     }
       
   179 
       
   180 // -----------------------------------------------------------------------------
       
   181 // CVcxHgMyVideosVideoData::SetValidDrmRights()
       
   182 // -----------------------------------------------------------------------------
       
   183 //
       
   184 void CVcxHgMyVideosVideoData::SetValidDrmRights( TBool aValidDrmRights )
       
   185     {
       
   186     iValidDrmRights = aValidDrmRights;
       
   187     }