*/
#include <dali-toolkit/dali-toolkit.h>
-#include <dali-toolkit/devel-api/controls/renderer-factory/renderer-factory.h>
-#include <dali-toolkit/devel-api/controls/renderer-factory/control-renderer.h>
+#include <dali/devel-api/actors/actor-devel.h>
#include <string.h>
using namespace Dali;
ImageSvgController( Application& application )
: mApplication( application ),
mScale( 1.f ),
+ mScaleAtPinchStart( 1.0f ),
mIndex( 0 )
{
// Connect to the Application's Init signal
Vector2 stageSize = stage.GetSize();
mActorSize = stageSize/2.f;
+ // Hide the indicator bar
+ application.GetWindow().ShowIndicator( Dali::Window::INVISIBLE );
+
stage.KeyEventSignal().Connect(this, &ImageSvgController::OnKeyEvent);
// Background, for receiving gestures
// Push button, for changing the image set for displaying
Toolkit::PushButton changeButton = Toolkit::PushButton::New();
- changeButton.SetLabelText( "Next" );
+ changeButton.SetProperty( Toolkit::Button::Property::LABEL, "Next" );
changeButton.SetAnchorPoint( AnchorPoint::TOP_RIGHT );
changeButton.SetParentOrigin( ParentOrigin::TOP_RIGHT );
stage.Add( changeButton );
// Push button, for resetting the actor size and position
Toolkit::PushButton resetButton = Toolkit::PushButton::New();
- resetButton.SetLabelText( "Reset" );
+ resetButton.SetProperty( Toolkit::Button::Property::LABEL, "Reset" );
resetButton.SetAnchorPoint( AnchorPoint::TOP_LEFT );
resetButton.SetParentOrigin( ParentOrigin::TOP_LEFT );
stage.Add( resetButton );
{
mSvgActor[i] = Toolkit::ImageView::New(SVG_IMAGES[mIndex+i]);
mSvgActor[i].SetSize( mActorSize );
+ mSvgActor[i].TranslateBy( Vector3( 0.0, stageSize.height * 0.05, 0.0f ) );
stage.Add( mSvgActor[i] );
}
mSvgActor[0].SetParentOrigin( ParentOrigin::CENTER );
mPinchGestureDetector = PinchGestureDetector::New();
mPinchGestureDetector.Attach( mStageBackground);
mPinchGestureDetector.DetectedSignal().Connect(this, &ImageSvgController::OnPinch);
+
+ DevelActor::RaiseToTop(changeButton);
+ DevelActor::RaiseToTop(resetButton);
}
// Callback of push button, for changing image set
// Entry point for Linux & Tizen applications
//
-int main( int argc, char **argv )
+int DALI_EXPORT_API main( int argc, char **argv )
{
Application application = Application::New( &argc, &argv );