Only reprocess markup-text in the TextView when the 'markup-enabled' property is changed to true
Change-Id: I9011af832a27fa4c6b5d3b9dfe59c9890f91725c
Signed-off-by: Javon Prince <javon.prince@samsung.com>
{
Internal::TextView& textViewImpl( GetImpl( textView ) );
bool newValue( value.Get<bool>() );
{
Internal::TextView& textViewImpl( GetImpl( textView ) );
bool newValue( value.Get<bool>() );
- textViewImpl.SetMarkupProcessingEnabled( newValue );
- if( newValue )
+ if( newValue != textViewImpl.IsMarkupProcessingEnabled() )
- const std::string& currentText( textViewImpl.GetText() );
- if( ! currentText.empty() )
+ textViewImpl.SetMarkupProcessingEnabled( newValue );
+ if( newValue )
- textViewImpl.SetText( currentText );
+ // If markup processing has been enabled, Ensure current text is reprocessed.
+ const std::string& currentText( textViewImpl.GetText() );
+ if( ! currentText.empty() )
+ {
+ textViewImpl.SetText( currentText );
+ }