From: Chulheon Date: Thu, 29 Aug 2013 05:58:36 +0000 (+0900) Subject: fixed bug (N_SE-50040) X-Git-Tag: accepted/tizen/20131002.165803^2~287^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=97462fdfac3691516915b4eb31fefc498feda20f;p=platform%2Fframework%2Fnative%2Fuifw.git fixed bug (N_SE-50040) Change-Id: I6a48bf727b8df51a1cad0193425ac4f9d7b21a33 --- diff --git a/src/ui/controls/FUiCtrl_EditCopyPasteManager.cpp b/src/ui/controls/FUiCtrl_EditCopyPasteManager.cpp index 2a1e229..ff90611 100644 --- a/src/ui/controls/FUiCtrl_EditCopyPasteManager.cpp +++ b/src/ui/controls/FUiCtrl_EditCopyPasteManager.cpp @@ -1799,6 +1799,8 @@ _EditCopyPasteManager::CreateCopyPastePopup(void) FloatRectangle formClientBounds(0.0f, 0.0f, 0.0f, 0.0f); FloatRectangle panelAbsoulteBounds(0.0f, 0.0f, 0.0f, 0.0f); bool commandButtonExist = false; + bool formExist = false; + bool panelExist = false; FloatRectangle cursorRect = GetCursorBoundsF(true); float contextMenuHeight = 0.0f; @@ -1828,7 +1830,6 @@ _EditCopyPasteManager::CreateCopyPastePopup(void) } GET_SHAPE_CONFIG(EDIT::COPYPASTE_HANDLER_HEIGHT, orientation, handlerHeight); - GET_SHAPE_CONFIG(CONTEXTMENU::GRID_ITEM_HEIGHT, orientation, contextMenuHeight); GET_SHAPE_CONFIG(CONTEXTMENU::GRID_TOP_MARGIN, orientation, contextMenuTopMargin); GET_SHAPE_CONFIG(CONTEXTMENU::GRID_BOTTOM_MARGIN, orientation, contextMenuBottomMargin); @@ -1863,11 +1864,13 @@ _EditCopyPasteManager::CreateCopyPastePopup(void) if (pForm) { formClientBounds = pForm->GetClientBoundsF(); + formExist = true; } _ScrollPanel* pPanel = __pEditPresenter->GetParentPanel(); if (pPanel) { panelAbsoulteBounds = pPanel->GetAbsoluteBoundsF(true); + panelExist = true; } __pEdit->GetKeypadBounds(keypadBounds); @@ -1887,6 +1890,11 @@ _EditCopyPasteManager::CreateCopyPastePopup(void) editShowAreaAbsRect.height = textObjectBounds.height; } } + if (editShowAreaAbsRect.y < 0.0f) + { + editShowAreaAbsRect.height += editShowAreaAbsRect.y; + editShowAreaAbsRect.y = 0.0f; + } if (commandButtonExist) { @@ -1902,15 +1910,21 @@ _EditCopyPasteManager::CreateCopyPastePopup(void) editShowAreaAbsRect.height -= (editShowAreaAbsRect.y + editShowAreaAbsRect.height - keypadBounds.y); } } - if (editShowAreaAbsRect.y < formClientBounds.y) + if (formExist) { - editShowAreaAbsRect.y = formClientBounds.y; - editShowAreaAbsRect.height -= formClientBounds.y; + if (editShowAreaAbsRect.y < formClientBounds.y) + { + editShowAreaAbsRect.y = formClientBounds.y; + editShowAreaAbsRect.height -= formClientBounds.y; + } } - if (editShowAreaAbsRect.y < panelAbsoulteBounds.y) + if (panelExist) { - editShowAreaAbsRect.y = panelAbsoulteBounds.y; - editShowAreaAbsRect.height -= (panelAbsoulteBounds.y - editShowAreaAbsRect.y); + if (editShowAreaAbsRect.y < panelAbsoulteBounds.y) + { + editShowAreaAbsRect.y = panelAbsoulteBounds.y; + editShowAreaAbsRect.height -= (panelAbsoulteBounds.y - editShowAreaAbsRect.y); + } } __editVisibleArea = CoordinateSystem::AlignToDevice(editShowAreaAbsRect); }