{
Actor self = Self();
- mController = Text::Controller::New( *this );
+ mController = Text::Controller::New( this, this );
// When using the vector-based rendering, the size of the GLyphs are different
TextAbstraction::GlyphType glyphType = (Text::RENDERING_VECTOR_BASED == mRenderingBackend) ? TextAbstraction::VECTOR_GLYPH : TextAbstraction::BITMAP_GLYPH;
mRenderer = Backend::Get().NewRenderer( mRenderingBackend );
}
- EnableClipping( ( Dali::Toolkit::TextField::EXCEED_POLICY_CLIP == mExceedPolicy ), size );
+ EnableClipping( size );
RenderText( updateTextType );
}
return mController->KeyEvent( event );
}
-void TextField::AddDecoration( Actor& actor, bool needsClipping )
-{
- if( actor )
- {
- if( needsClipping )
- {
- mClippingDecorationActors.push_back( actor );
- }
- else
- {
- Self().Add( actor );
- }
- }
-}
-
void TextField::RequestTextRelayout()
{
RelayoutRequest();
mTextChangedSignal.Emit( handle );
}
+void TextField::MaxLengthReached()
+{
+ Dali::Toolkit::TextField handle( GetOwner() );
+ mMaxLengthReachedSignal.Emit( handle );
+}
+
void TextField::InputStyleChanged( Text::InputStyle::Mask inputStyleMask )
{
Dali::Toolkit::TextField handle( GetOwner() );
mInputStyleChangedSignal.Emit( handle, fieldInputStyleMask );
}
+void TextField::AddDecoration( Actor& actor, bool needsClipping )
+{
+ if( actor )
+ {
+ if( needsClipping )
+ {
+ mClippingDecorationActors.push_back( actor );
+ }
+ else
+ {
+ Self().Add( actor );
+ }
+ }
+}
+
void TextField::OnStageConnect( Dali::Actor actor )
{
if ( mHasBeenStaged )
}
}
-void TextField::MaxLengthReached()
-{
- Dali::Toolkit::TextField handle( GetOwner() );
- mMaxLengthReachedSignal.Emit( handle );
-}
-
ImfManager::ImfCallbackData TextField::OnImfEvent( Dali::ImfManager& imfManager, const ImfManager::ImfEventData& imfEvent )
{
DALI_LOG_INFO( gLogFilter, Debug::Verbose, "TextField::OnImfEvent %p eventName %d\n", mController.Get(), imfEvent.eventName );
}
}
-void TextField::EnableClipping( bool clipping, const Vector2& size )
+void TextField::EnableClipping( const Vector2& size )
{
- if( clipping )
+ if( Dali::Toolkit::TextField::EXCEED_POLICY_CLIP == mExceedPolicy )
{
// Not worth to created clip actor if width or height is equal to zero.
if( size.width > Math::MACHINE_EPSILON_1000 && size.height > Math::MACHINE_EPSILON_1000 )