menufw/hierarchynavigator/hnpresentationmodel/inc/hnextbmpiconholder.h
branchRCL_3
changeset 50 137ebc85284b
parent 0 f72a12da539e
equal deleted inserted replaced
47:7be2816dbabd 50:137ebc85284b
     9 * Initial Contributors:
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    10 * Nokia Corporation - initial contribution.
    11 *
    11 *
    12 * Contributors:
    12 * Contributors:
    13 *
    13 *
    14 * Description:  
    14 * Description:
    15 *
    15 *
    16 */
    16 */
    17 
    17 
    18 
    18 
    19 #ifndef MMEXTBMPICONHOLDER_H
    19 #ifndef MMEXTBMPICONHOLDER_H
    24 class CLiwBitmapBuffer;
    24 class CLiwBitmapBuffer;
    25 
    25 
    26 /**
    26 /**
    27  * This is an extended version of @c CHnIconHolder which holds a CGulIcon that does
    27  * This is an extended version of @c CHnIconHolder which holds a CGulIcon that does
    28  * not own the bitmaps and CLiwBitmapBuffer objects that do.
    28  * not own the bitmaps and CLiwBitmapBuffer objects that do.
    29  * 
    29  *
    30  * Such class was needed because some of the bitmaps for icons are obtained from
    30  * Such class was needed because some of the bitmaps for icons are obtained from
    31  * CLiwBitmapBuffer objects and there is no way to transfer ownership of that
    31  * CLiwBitmapBuffer objects and there is no way to transfer ownership of that
    32  * bitmaps from them. It is not possible to make copies of that bitmaps either,
    32  * bitmaps from them. It is not possible to make copies of that bitmaps either,
    33  * because some of them are not CFbsBitmaps but CAknBitmaps.
    33  * because some of them are not CFbsBitmaps but CAknBitmaps.
    34  */
    34  */
    38     /**
    38     /**
    39      * Sets the icon to be stored in this icon holder along with the bitmap buffers.
    39      * Sets the icon to be stored in this icon holder along with the bitmap buffers.
    40      * This method should be called only once. If you want to store another icon
    40      * This method should be called only once. If you want to store another icon
    41      * simply call Close() on this icon holder and then create a new icon holder
    41      * simply call Close() on this icon holder and then create a new icon holder
    42      * to store the new icon.
    42      * to store the new icon.
    43      * 
    43      *
    44      * @param aGulIcon Icon to store in this icon holder.
    44      * @param aGulIcon Icon to store in this icon holder.
    45      * @param aBmpBuffer The buffer that owns the primary bitmap.
    45      * @param aBmpBuffer The buffer that owns the primary bitmap.
    46      * @param aMaskBuffer The buffer that owns the mask bitmap. 
    46      * @param aMaskBuffer The buffer that owns the mask bitmap.
    47      */
    47      */
    48     IMPORT_C void SetGulIcon( CGulIcon* aGulIcon, CLiwBitmapBuffer* aBmpBuffer, CLiwBitmapBuffer* aMaskBuffer );
    48     IMPORT_C void SetGulIcon( CGulIcon* aGulIcon, CLiwBitmapBuffer* aBmpBuffer, CLiwBitmapBuffer* aMaskBuffer );
    49     
    49 
       
    50     /**
       
    51      * Clean both liw bitmap buffer and liw maskbitmap buffer.
       
    52      * Allows set new mask and new bitmap for the icon.
       
    53      */
       
    54     virtual void CleanBmpBuffer();
       
    55 
    50     /**
    56     /**
    51      * Standard C++ virtual destructor.
    57      * Standard C++ virtual destructor.
    52      */
    58      */
    53     virtual ~CHnExtBmpIconHolder();
    59     virtual ~CHnExtBmpIconHolder();
    54 
    60 
    55 private: // data
    61 private: // data
    56     
    62 
    57     /**
    63     /**
    58      * Liw bitmap buffer that owns the primary bitmap for the icon.
    64      * Liw bitmap buffer that owns the primary bitmap for the icon.
    59      * Co-owns (CLiwBitmapBuffer are ref-counted).
    65      * Co-owns (CLiwBitmapBuffer are ref-counted).
    60      */
    66      */
    61     CLiwBitmapBuffer* iBmpBuffer;
    67     CLiwBitmapBuffer* iBmpBuffer;
    62     
    68 
    63     /**
    69     /**
    64      * Liw bitmap buffer that owns the mask bitmap for the icon.
    70      * Liw bitmap buffer that owns the mask bitmap for the icon.
    65      * Co-owns (CLiwBitmapBuffer are ref-counted).
    71      * Co-owns (CLiwBitmapBuffer are ref-counted).
    66      */
    72      */
    67     CLiwBitmapBuffer* iMaskBuffer;
    73     CLiwBitmapBuffer* iMaskBuffer;