src/hbcore/devicedialogbase/hbtextresolversymbian.cpp
changeset 21 4633027730f5
parent 7 923ff622b8b9
child 23 e6ad4ef83b23
equal deleted inserted replaced
7:923ff622b8b9 21:4633027730f5
    39     HbTextResolverSymbianPrivate();    
    39     HbTextResolverSymbianPrivate();    
    40     virtual ~HbTextResolverSymbianPrivate();
    40     virtual ~HbTextResolverSymbianPrivate();
    41     static HbTextResolverSymbianPrivate* Instance();
    41     static HbTextResolverSymbianPrivate* Instance();
    42     TBool LoadTranslationFile();
    42     TBool LoadTranslationFile();
    43     TBool Initialize(const TDesC& aFilename, const TDesC& aPath);
    43     TBool Initialize(const TDesC& aFilename, const TDesC& aPath);
    44     HBufC* LoadLC(const TDesC& aMessageId, TInt aPlural); // Simple string. + %n message(s). Plural and replaces all occurances of %n in the string.
    44     HBufC* LoadLC(const TDesC& aMessageId, TInt aPlural); // Simple string. + %n message(s). Plural and replaces all occurrences of %n in the string.
    45     HBufC* LoadLC(const TDesC& aMessageId, const TDesC& aString, TInt aPlural); // One and %1. %n and %1. Plural and replaces all occurances of %n in the string.
    45     HBufC* LoadLC(const TDesC& aMessageId, const TDesC& aString, TInt aPlural); // One and %1. %n and %1. Plural and replaces all occurrences of %n in the string.
    46     HBufC* LoadLC(const TDesC& aMessageId, const MDesCArray& aStrings, TInt aPlural);
    46     HBufC* LoadLC(const TDesC& aMessageId, const MDesCArray& aStrings, TInt aPlural);
    47     HBufC* LoadLC(const TDesC& aMessageId, TInt aInt, TInt aPlural);
    47     HBufC* LoadLC(const TDesC& aMessageId, TInt aInt, TInt aPlural);
    48     HBufC* LoadLC(const TDesC& aMessageId, const RArray<TInt>& aInts, TInt aPlural);    
    48     HBufC* LoadLC(const TDesC& aMessageId, const RArray<TInt>& aInts, TInt aPlural);    
    49         
    49         
    50     QString ConvertToQString(const TDesC& aMessageId, TInt aPlural = -1);
    50     QString ConvertToQString(const TDesC& aMessageId, TInt aPlural = -1);
   203 
   203 
   204 /*!
   204 /*!
   205     \class HbTextResolverSymbian
   205     \class HbTextResolverSymbian
   206     \brief HbTextResolverSymbian implements translation support for Symbian OS applications.
   206     \brief HbTextResolverSymbian implements translation support for Symbian OS applications.
   207     
   207     
   208     HbTextResolverSymbian is class that provides convinience API for translation support and
   208     HbTextResolverSymbian is class that provides convenience API for translation support and
   209     is meant to be used only by pure Symbian OS applications. Dynamic strings and plurals are
   209     is meant to be used only by pure Symbian OS applications. Dynamic strings and plurals are
   210     also supported. 
   210     also supported. 
   211     
   211     
   212     Before using the translation support HbTextResolverSymbian must be initialized. Note that 
   212     Before using the translation support HbTextResolverSymbian must be initialized. Note that 
   213     the filename must not have language specific suffix, because that is handled internally by
   213     the filename must not have language specific suffix, because that is handled internally by
   322     Initializes the translator. 
   322     Initializes the translator. 
   323         
   323         
   324     \param aFilename specifies the used translation file. 
   324     \param aFilename specifies the used translation file. 
   325     \param aPath specifies path to translation file.
   325     \param aPath specifies path to translation file.
   326     
   326     
   327     Returns ETrue if initialization was succesful.     
   327     Returns ETrue if initialization was successful.
   328 */
   328 */
   329 EXPORT_C TBool HbTextResolverSymbian::Init(const TDesC& aFilename, const TDesC& aPath)
   329 EXPORT_C TBool HbTextResolverSymbian::Init(const TDesC& aFilename, const TDesC& aPath)
   330     {
   330     {
   331     HbTextResolverSymbianPrivate* resolver = HbTextResolverSymbianPrivate::Instance();
   331     HbTextResolverSymbianPrivate* resolver = HbTextResolverSymbianPrivate::Instance();
   332     return resolver->Initialize(aFilename, aPath);
   332     return resolver->Initialize(aFilename, aPath);