X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=examples%2Fcontact-cards%2Fcontact-cards-example.cpp;h=c8eb8eb4f91d0d6f7a4f03453f489e47e448e2fa;hb=refs%2Fchanges%2F20%2F238120%2F4;hp=d48bff550eae89d07d27461059a5099242997b2e;hpb=ea9873b3235c9b0305aaf8463fd47ac03183dc6b;p=platform%2Fcore%2Fuifw%2Fdali-demo.git diff --git a/examples/contact-cards/contact-cards-example.cpp b/examples/contact-cards/contact-cards-example.cpp index d48bff5..c8eb8eb 100644 --- a/examples/contact-cards/contact-cards-example.cpp +++ b/examples/contact-cards/contact-cards-example.cpp @@ -19,7 +19,6 @@ #include #include #include -#include #include #include @@ -32,7 +31,7 @@ using namespace Dali::Toolkit; namespace { -const Vector4 STAGE_COLOR( 211.0f / 255.0f, 211.0f / 255.0f, 211.0f / 255.0f, 1.0f ); ///< The color of the stage +const Vector4 WINDOW_COLOR( 211.0f / 255.0f, 211.0f / 255.0f, 211.0f / 255.0f, 1.0f ); ///< The color of the window const char * const THEME_PATH( DEMO_STYLE_DIR "contact-cards-example-theme.json" ); ///< The theme used for this example } // unnamed namespace @@ -43,7 +42,7 @@ const char * const THEME_PATH( DEMO_STYLE_DIR "contact-cards-example-theme.json" * Additionally, this also shows how to morph between two different geometries. * * ContactCardLayouter: This class is used to lay out the different contact cards on the screen. - * This takes stage size into account but does not support relayouting. + * This takes window size into account but does not support relayouting. * ContactCard: This class represents each contact card on the screen. * Two animations are set up in this class which animate several properties with multiple start and stop times. * An overview of the two animations can be found in contact-card.cpp. @@ -79,15 +78,15 @@ private: */ void Create( Application& application ) { - // Set the stage background color and connect to the stage's key signal to allow Back and Escape to exit. - Stage stage = Stage::GetCurrent(); - stage.SetBackgroundColor( STAGE_COLOR ); - stage.KeyEventSignal().Connect( this, &ContactCardController::OnKeyEvent ); + // Set the window background color and connect to the window's key signal to allow Back and Escape to exit. + Window window = application.GetWindow(); + window.SetBackgroundColor( WINDOW_COLOR ); + window.KeyEventSignal().Connect( this, &ContactCardController::OnKeyEvent ); // Add all the contacts to the layouter for( size_t i = 0; i < ContactData::TABLE_SIZE; ++i ) { - mContactCardLayouter.AddContact( ContactData::TABLE[ i ].name, ContactData::TABLE[ i ].address, ContactData::TABLE[ i ].imagePath ); + mContactCardLayouter.AddContact( window, ContactData::TABLE[ i ].name, ContactData::TABLE[ i ].address, ContactData::TABLE[ i ].imagePath ); } }