X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=automated-tests%2Fsrc%2Fdali-toolkit-internal%2Futc-Dali-LogicalModel.cpp;h=46dbc2f574d48428563b2b9323460e7c9a520027;hb=8ae521ab64a3922f3419fbbfb83dde57e6135cf5;hp=9fe39c02a0f434577309c3d1ebe984d242c13114;hpb=f1fd8ae285533109596e90f5598e91c5ce009659;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/automated-tests/src/dali-toolkit-internal/utc-Dali-LogicalModel.cpp b/automated-tests/src/dali-toolkit-internal/utc-Dali-LogicalModel.cpp old mode 100644 new mode 100755 index 9fe39c0..46dbc2f --- a/automated-tests/src/dali-toolkit-internal/utc-Dali-LogicalModel.cpp +++ b/automated-tests/src/dali-toolkit-internal/utc-Dali-LogicalModel.cpp @@ -22,7 +22,7 @@ #include #include #include -#include +#include using namespace Dali; @@ -100,8 +100,9 @@ struct GetLogicalCursorIndexData bool CreateParagraphTest( const CreateParagraphData& data ) { // 1) Create the model. - LogicalModelPtr logicalModel = LogicalModel::New(); - VisualModelPtr visualModel = VisualModel::New(); + LogicalModelPtr logicalModel; + VisualModelPtr visualModel; + MetricsPtr metrics; Size textArea(100.f, 60.f); Size layoutSize; @@ -113,7 +114,9 @@ bool CreateParagraphTest( const CreateParagraphData& data ) options, layoutSize, logicalModel, - visualModel ); + visualModel, + metrics, + false ); // 2) Clear the paragraphs. Vector& paragraphs = logicalModel->mParagraphInfo; @@ -158,8 +161,9 @@ bool CreateParagraphTest( const CreateParagraphData& data ) bool FindParagraphTest( const FindParagraphData& data ) { // 1) Create the model. - LogicalModelPtr logicalModel = LogicalModel::New(); - VisualModelPtr visualModel = VisualModel::New(); + LogicalModelPtr logicalModel; + VisualModelPtr visualModel; + MetricsPtr metrics; Size textArea(100.f, 60.f); Size layoutSize; @@ -171,7 +175,9 @@ bool FindParagraphTest( const FindParagraphData& data ) options, layoutSize, logicalModel, - visualModel ); + visualModel, + metrics, + false ); // 2) Find the paragraphs. Vector paragraphs; @@ -204,8 +210,9 @@ bool FetchBidirectionalLineInfoTest( const FetchBidirectionalLineInfoData& data { std::cout << " testing : " << data.description << std::endl; // Create the model. - LogicalModelPtr logicalModel = LogicalModel::New(); - VisualModelPtr visualModel = VisualModel::New(); + LogicalModelPtr logicalModel; + VisualModelPtr visualModel; + MetricsPtr metrics; Size textArea( 100.f, 300.f ); Size layoutSize; @@ -218,7 +225,9 @@ bool FetchBidirectionalLineInfoTest( const FetchBidirectionalLineInfoData& data options, layoutSize, logicalModel, - visualModel ); + visualModel, + metrics, + false ); for( unsigned int index = 0; index < data.numberOfTests; ++index ) { @@ -247,8 +256,9 @@ bool GetLogicalCharacterIndexTest( const GetLogicalCharacterIndexData& data ) { std::cout << " testing : " << data.description << std::endl; // Create the model. - LogicalModelPtr logicalModel = LogicalModel::New(); - VisualModelPtr visualModel = VisualModel::New(); + LogicalModelPtr logicalModel; + VisualModelPtr visualModel; + MetricsPtr metrics; Size layoutSize; // Create the model with the whole text. @@ -260,7 +270,9 @@ bool GetLogicalCharacterIndexTest( const GetLogicalCharacterIndexData& data ) options, layoutSize, logicalModel, - visualModel ); + visualModel, + metrics, + false ); for( unsigned int index = 0u; index < data.numberOfIndices; ++index ) { @@ -287,8 +299,9 @@ bool GetLogicalCursorIndexTest( const GetLogicalCursorIndexData& data ) { std::cout << " testing : " << data.description << std::endl; // Create the model. - LogicalModelPtr logicalModel = LogicalModel::New(); - VisualModelPtr visualModel = VisualModel::New(); + LogicalModelPtr logicalModel; + VisualModelPtr visualModel; + MetricsPtr metrics; Size layoutSize; // Create the model with the whole text. @@ -300,7 +313,9 @@ bool GetLogicalCursorIndexTest( const GetLogicalCursorIndexData& data ) options, layoutSize, logicalModel, - visualModel ); + visualModel, + metrics, + false ); for( unsigned int index = 0u; index < data.numberOfIndices; ++index ) { @@ -852,8 +867,8 @@ int UtcDaliGetLogicalCursorIndex(void) unsigned int characterIndex06[] = { 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 12u, 12u, 12u, 12u, 12u, 12u }; - unsigned int logicalIndex06[] = { 10u, 9u, 8u, 7u, 6u, 5u, 4u, 3u, 2u, 1u, 0u, - 16u, 15u, 14u, 13u, 12u, 11u }; + unsigned int logicalIndex06[] = { 11u, 10u, 9u, 8u, 7u, 6u, 5u, 4u, 3u, 2u, 1u, + 13u, 16u, 15u, 14u, 13u, 12u }; unsigned int bidirectionalLineIndex06[] = { 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u, 1u, 1u, 1u, 1u, 1u, 1u };