equal
deleted
inserted
replaced
46 |
46 |
47 #include <coecntrl.h> |
47 #include <coecntrl.h> |
48 #include <uiacceltk/huidisplaybackgrounditem.h> |
48 #include <uiacceltk/huidisplaybackgrounditem.h> |
49 #include "huiskinbackroundlayout.h" |
49 #include "huiskinbackroundlayout.h" |
50 #include "HuiFxEngine.h" |
50 #include "HuiFxEngine.h" |
|
51 #include "huiextension.h" |
51 |
52 |
52 const TUid KHuiInternalFbsBitmapBufferGcUid = {0x2000e5a3}; |
53 const TUid KHuiInternalFbsBitmapBufferGcUid = {0x2000e5a3}; |
53 |
54 |
54 //#define HUI_DEBUG_PRINT_PERFORMANCE_INTERVAL |
55 //#define HUI_DEBUG_PRINT_PERFORMANCE_INTERVAL |
55 |
56 |
930 iRosterObservers[i].NotifyRosterDrawEnd(*this); |
931 iRosterObservers[i].NotifyRosterDrawEnd(*this); |
931 } |
932 } |
932 |
933 |
933 if (iForegroundTexture) |
934 if (iForegroundTexture) |
934 { |
935 { |
|
936 UpdateForegroundTexture(dirtyRect); |
935 DrawForegroundTexture(); |
937 DrawForegroundTexture(); |
936 } |
938 } |
937 |
939 |
938 // Return to the clipping rectangle that was in use previously. |
940 // Return to the clipping rectangle that was in use previously. |
939 iGc->PopClip(); |
941 iGc->PopClip(); |
1523 iGc->Clear(); |
1525 iGc->Clear(); |
1524 iGc->PopClip(); |
1526 iGc->PopClip(); |
1525 } |
1527 } |
1526 break; |
1528 break; |
1527 case EClearWithSkinBackground: |
1529 case EClearWithSkinBackground: |
1528 TRect skinRect; |
|
1529 TRect dummy; |
|
1530 GetRectForItem(item.SkinBackground(), dummy, skinRect); |
|
1531 backgroundTexture = s60skin->BackgroundTexture(item.SkinBackground()); |
1530 backgroundTexture = s60skin->BackgroundTexture(item.SkinBackground()); |
|
1531 TRect skinRect = s60skin->SkinRect(item.SkinBackground()); |
1532 if (backgroundTexture) |
1532 if (backgroundTexture) |
1533 { |
1533 { |
1534 THuiImage background(*backgroundTexture); |
1534 THuiImage background(*backgroundTexture); |
1535 |
1535 |
1536 TPoint screenOrigin(0, 0); |
1536 TPoint screenOrigin(0, 0); |
1620 EXPORT_C CHuiTexture* CHuiDisplay::ForegroundTexture() const |
1620 EXPORT_C CHuiTexture* CHuiDisplay::ForegroundTexture() const |
1621 { |
1621 { |
1622 return iForegroundTexture; |
1622 return iForegroundTexture; |
1623 } |
1623 } |
1624 |
1624 |
|
1625 void CHuiDisplay::UpdateForegroundTexture(const TRect& aRect) |
|
1626 { |
|
1627 if (iForegroundTexture && iForegroundBitmap && !aRect.IsEmpty()) |
|
1628 { |
|
1629 TRAP_IGNORE(DoUpdateForegroundTextureL(aRect)); |
|
1630 } |
|
1631 } |
|
1632 |
|
1633 void CHuiDisplay::DoUpdateForegroundTextureL(const TRect& aRect) |
|
1634 { |
|
1635 // First try to upload with faster mechanism |
|
1636 THuiTexturePartialBitmapUploadParams params; |
|
1637 params.iErrorCode = KErrNotSupported; |
|
1638 params.iRect = aRect; |
|
1639 params.iBitmap = iForegroundBitmap; |
|
1640 TAny* ptr = ¶ms; |
|
1641 |
|
1642 MHuiTexture* texture = iForegroundTexture; |
|
1643 texture->TextureExtension(KHuiTexturePartialBitmapUploadUid, &ptr); |
|
1644 if ( params.iErrorCode != KErrNone ) |
|
1645 { |
|
1646 iForegroundTexture->UploadL(*iForegroundBitmap, NULL); |
|
1647 } |
|
1648 } |
1625 |
1649 |
1626 void CHuiDisplay::DrawForegroundTexture() |
1650 void CHuiDisplay::DrawForegroundTexture() |
1627 { |
1651 { |
1628 if (iForegroundTexture) |
1652 if (iForegroundTexture) |
1629 { |
1653 { |