summaryrefslogtreecommitdiff
path: root/examples/builder
diff options
context:
space:
mode:
authorKingsley Stephens <k.stephens@partner.samsung.com>2014-12-17 11:50:28 +0000
committerKingsley Stephens <k.stephens@partner.samsung.com>2014-12-17 11:50:28 +0000
commitd2aae157c8002cf0937a1fa38fb31a9d4b483f53 (patch)
treede41471b65f3eff5fce4e5ddf8d859f036f0c92e /examples/builder
parentb0038846a52760b38d409e0e7311131dd6ac1c2b (diff)
downloaddali-demo-d2aae157c8002cf0937a1fa38fb31a9d4b483f53.tar.gz
dali-demo-d2aae157c8002cf0937a1fa38fb31a9d4b483f53.tar.bz2
dali-demo-d2aae157c8002cf0937a1fa38fb31a9d4b483f53.zip
Fix builder.example to work with updated ItemView code.
Change-Id: Id2a566a93648690cd1a308302e0047149c8f2c31
Diffstat (limited to 'examples/builder')
-rw-r--r--examples/builder/examples.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/examples/builder/examples.cpp b/examples/builder/examples.cpp
index 1f98958f..0e26bdf9 100644
--- a/examples/builder/examples.cpp
+++ b/examples/builder/examples.cpp
@@ -280,6 +280,9 @@ public:
{
Stage stage = Stage::GetCurrent();
+ mTapDetector = TapGestureDetector::New();
+ mTapDetector.DetectedSignal().Connect( this, &ExampleApp::OnTap );
+
if( mItemView )
{
stage.Remove( mItemView );
@@ -361,15 +364,6 @@ public:
}
}
- mTapDetector = TapGestureDetector::New();
-
- for( unsigned int i = 0u; i < mItemView.GetChildCount(); ++i )
- {
- mTapDetector.Attach( mItemView.GetChildAt(i) );
- }
-
- mTapDetector.DetectedSignal().Connect( this, &ExampleApp::OnTap );
-
// Display item view on the stage
stage.Add( mItemView );
@@ -413,6 +407,10 @@ public:
t.SetText( fontString.str() );
t.SetTextAlignment( Alignment::HorizontalLeft );
+
+ // Hook up tap detector
+ mTapDetector.Attach( t );
+
return t;
}