equal
deleted
inserted
replaced
740 // ----------------------------------------------------------------------------- |
740 // ----------------------------------------------------------------------------- |
741 // |
741 // |
742 CAknIconSrvIconItem* CAknIconServer::CreateIconL( |
742 CAknIconSrvIconItem* CAknIconServer::CreateIconL( |
743 const TAknIconParams& aInfo ) |
743 const TAknIconParams& aInfo ) |
744 { |
744 { |
745 const TInt KMaxIconDataLimit = 0xFA000; |
|
746 CFbsBitmap* bitmap = new (ELeave) CFbsBitmap; |
745 CFbsBitmap* bitmap = new (ELeave) CFbsBitmap; |
747 CleanupStack::PushL( bitmap ); |
746 CleanupStack::PushL( bitmap ); |
748 |
747 |
749 CFbsBitmap* mask = NULL; |
748 CFbsBitmap* mask = NULL; |
750 |
749 |
764 |
763 |
765 CleanupStack::PushL( TCleanupItem( CleanupIconLoader, this ) ); |
764 CleanupStack::PushL( TCleanupItem( CleanupIconLoader, this ) ); |
766 |
765 |
767 TPtrC8 iconData = InitIconDataAndHandlerLC(aInfo, loader, handler); |
766 TPtrC8 iconData = InitIconDataAndHandlerLC(aInfo, loader, handler); |
768 |
767 |
769 if(iconData.Size()>KMaxIconDataLimit) |
|
770 { |
|
771 User::Leave(KErrTooBig); |
|
772 } |
|
773 |
|
774 bitmapDepth = (TDisplayMode)loader->IconDepthL( aInfo.iBitmapId ); |
768 bitmapDepth = (TDisplayMode)loader->IconDepthL( aInfo.iBitmapId ); |
775 |
769 |
776 handler->PrepareIconL( iconData, handle ); |
770 handler->PrepareIconL( iconData, handle ); |
777 |
771 |
778 // CleanupIconLoader, InitIconDataAndHandlerLC |
772 // CleanupIconLoader, InitIconDataAndHandlerLC |