DrawBitmap(FloatPoint) API Implementation
authorAyush <ayush.sriv@samsung.com>
Thu, 5 Sep 2013 11:25:39 +0000 (16:55 +0530)
committerAyush <ayush.sriv@samsung.com>
Wed, 11 Sep 2013 12:33:58 +0000 (18:03 +0530)
Change-Id: Ia3af75d4c6dac3b71fa8e4526cd6c14fbe425959
Signed-off-by: Ayush <ayush.sriv@samsung.com>
src/ui/controls/FUiCtrl_SearchBarPresenter.cpp

index 0a56ab1..5265e60 100644 (file)
@@ -464,7 +464,7 @@ _SearchBarPresenter::DrawIcon(void)
                        }
                        else
                        {
-                               pIconCanvas->DrawBitmap(FloatRectangle(0, 0, iconBounds.width, iconBounds.height), *__pReplacedSearchFieldNormalBitmap);
+                               pIconCanvas->DrawBitmap(FloatPoint((iconBounds.width - __pReplacedSearchFieldNormalBitmap->GetWidthF())/2.0f, (iconBounds.height - __pReplacedSearchFieldNormalBitmap->GetHeightF())/2.0f), *__pReplacedSearchFieldNormalBitmap);
                        }
                }
        }
@@ -478,7 +478,7 @@ _SearchBarPresenter::DrawIcon(void)
                        }
                        else
                        {
-                               pIconCanvas->DrawBitmap(FloatRectangle(0, 0, iconBounds.width, iconBounds.height), *__pReplacedSearchFieldDisabledBitmap);
+                               pIconCanvas->DrawBitmap(FloatPoint((iconBounds.width - __pReplacedSearchFieldDisabledBitmap->GetWidthF())/2.0f, (iconBounds.height - __pReplacedSearchFieldDisabledBitmap->GetHeightF())/2.0f), *__pReplacedSearchFieldDisabledBitmap);
                        }
                }
        }
@@ -491,7 +491,7 @@ _SearchBarPresenter::DrawIcon(void)
                }
                else
                {
-                       pIconCanvas->DrawBitmap(FloatRectangle(0, 0, iconBounds.width, iconBounds.height), *__pSearchFieldEffectBitmap);
+                       pIconCanvas->DrawBitmap(FloatPoint(0.0f, 0.0f), *__pSearchFieldEffectBitmap);
                }
        }