From f57ed04c229af9bdc8c10d2ef35a8723a9c0319f Mon Sep 17 00:00:00 2001 From: raster Date: Mon, 27 Oct 2008 03:12:59 +0000 Subject: [PATCH] dont repeat code git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@37191 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/canvas/evas_object_textblock.c | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/src/lib/canvas/evas_object_textblock.c b/src/lib/canvas/evas_object_textblock.c index 4124caf..14f5507 100644 --- a/src/lib/canvas/evas_object_textblock.c +++ b/src/lib/canvas/evas_object_textblock.c @@ -2682,22 +2682,11 @@ static inline void _prepend_escaped_char(Evas_Textblock_Cursor *cur, const char *s, const char *s_end) { - const char *map_itr, *map_end; - - map_itr = escape_strings; - map_end = map_itr + sizeof(escape_strings); - - while (map_itr < map_end) - { - if (_is_eq_and_advance(s, s_end, &map_itr, map_end)) - { - evas_textblock_cursor_text_prepend(cur, map_itr); - return; - } - - if (map_itr < map_end) - _advance_after_end_of_string(&map_itr); - } + const char *escape; + + escape = _escaped_char_get(s, s_end); + if (escape) + evas_textblock_cursor_text_prepend(cur, escape); } /** -- 2.7.4