X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=examples%2Fsize-negotiation%2Fsize-negotiation-example.cpp;h=4856360fe04d9b6a4168b86ccc6d909d04e9643a;hb=refs%2Fchanges%2F70%2F155570%2F1;hp=7d2962aca3dac6f283007ad9596648fd5024b165;hpb=fe51b34a968be11d80b032030cf1a20ff8bf7e85;p=platform%2Fcore%2Fuifw%2Fdali-demo.git diff --git a/examples/size-negotiation/size-negotiation-example.cpp b/examples/size-negotiation/size-negotiation-example.cpp index 7d2962a..4856360 100644 --- a/examples/size-negotiation/size-negotiation-example.cpp +++ b/examples/size-negotiation/size-negotiation-example.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -114,11 +114,7 @@ public: Stage stage = Stage::GetCurrent(); // Respond to key events if not handled - Toolkit::KeyInputFocusManager keyInputFocusManager = Toolkit::KeyInputFocusManager::Get(); - if( keyInputFocusManager ) - { - keyInputFocusManager.UnhandledKeyEventSignal().Connect(this, &SizeNegotiationController::OnKeyEvent); - } + stage.KeyEventSignal().Connect(this, &SizeNegotiationController::OnKeyEvent); // Creates a default view with a default tool bar. // The view is added to the stage. @@ -823,19 +819,10 @@ private: }; -void RunTest( Application& application ) -{ - SizeNegotiationController test( application ); - - application.MainLoop(); -} - -// Entry point for Linux & SLP applications int DALI_EXPORT_API main( int argc, char **argv ) { Application application = Application::New( &argc, &argv, DEMO_THEME_PATH ); - - RunTest( application ); - + SizeNegotiationController test( application ); + application.MainLoop(); return 0; }