gfxconversion/mifconv/inc/mifconv_bitmapheaderconverter.h
author William Roberts <williamr@symbian.org>
Mon, 08 Feb 2010 17:20:11 +0000
changeset 2 53df912d30f4
parent 0 f453ebb75370
permissions -rw-r--r--
Added debugging info to mifconv.exe 'Bug 1414 - mifconv system() call to svgtbinencode seems to have a timing issue with Raptor 2.9.2+', which seems to alleviate the symptoms...

/*
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:  Mifconv bitmap to header converter class.
*
*/


#ifndef __MIFCONVBITMAPHEADERCONVERTER_H__
#define __MIFCONVBITMAPHEADERCONVERTER_H__

#include "mifconv_fileconverter.h"
#include <fstream>

/**
 * Converter class for converting source files to .mbg header files
 */
class MifConvBitmapHeaderConverter : public MifConvFileConverter
{
public:
    /**
     * Default constructor
     */
    MifConvBitmapHeaderConverter();

    /**
     * Destructor
     */
    virtual ~MifConvBitmapHeaderConverter();

    // From MifConvFileConverter
    virtual void AppendFile( const MifConvSourceFile& sourcefile );
    virtual void Convert();
    virtual void Cleanup(bool err = false);
    virtual void Init();
    virtual void CleanupTargetFiles();

protected:

    /**
     * Writes the beginning of the header
     */ 
    void WriteStart();

    /**
     * Writes source file information to the header file
     * @param source Source file object representing the file to be 
     * added to the header.
     */
    void WriteItemToHeader( const MifConvSourceFile& source );

    /**
     * Writes the end of the header.
     */
    void WriteEnd();

    MifConvString iHeaderFilename;
    fstream* iDestFile;
    int iCurrentSourceId;
};

#endif