Fix for SetImageSource()
authorBongjoo Seo <bongjoo.seo@samsung.com>
Fri, 24 May 2013 11:50:02 +0000 (20:50 +0900)
committerBongjoo Seo <bongjoo.seo@samsung.com>
Fri, 24 May 2013 11:50:02 +0000 (20:50 +0900)
Change-Id: Ieb8ea1354d78833a2e76b62d9f70fa8e3490dfd2
Signed-off-by: Bongjoo Seo <bongjoo.seo@samsung.com>
src/ui/animations/FUiAnim_VisualElementImpl.cpp

index 68b14ff..c8441a0 100644 (file)
@@ -487,12 +487,16 @@ _VisualElementImpl::FlushI(void)
 result
 _VisualElementImpl::SetImageSource(const String& filePath)
 {
+       result r = E_SUCCESS;
        RebuildHierarchyProps(0, true, true);
 
        SysTryReturnResult(NID_UI_ANIM, HAVE_SURFACE(this), E_SYSTEM, "Realizing back-buffer surface failed.");
 
-       result r = GetSharedData().SetImage(filePath);
-       SysTryLog(NID_UI_ANIM, r == E_SUCCESS, "[%s] Propagating.", GetErrorMessage(r));
+       if (!filePath.IsEmpty())
+       {
+               r = GetSharedData().SetImage(filePath);
+               SysTryLog(NID_UI_ANIM, r == E_SUCCESS, "[%s] Propagating.", GetErrorMessage(r));
+       }
 
        __imageFilePath = filePath;