lauromoura pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=08d7d2b0645cc0c9e18269836c17a709e89c25f1

commit 08d7d2b0645cc0c9e18269836c17a709e89c25f1
Author: Xavi Artigas <[email protected]>
Date:   Fri Oct 25 18:00:31 2019 -0300

    Efl.Ui.Text: Fix Text Cursor composition
    
    Summary:
    This is a temporary fix while Text is being revamped.
    Efl.Ui.Text internally composites Efl.Text_Cursor (through some other 
interfaces)
    but this was not being advertised in the EO file.
    This caused no trouble to C but was preventing C# from using the Cursors API
    (because C# relies on the EO composites section).
    
    On top of this, the cursor_new() method has been removed, since it was 
redundant.
    
    Test Plan:
    Builds and passes tests, and C# is able to do things like:
    ```
    Efl.TextCursorCursor cursor = 
screen.GetTextCursor(Efl.TextCursorGetType.Main);
    screen.InsertCursorText(cursor, str);
    ```
    
    Reviewers: lauromoura, cedric, tasn
    
    Reviewed By: lauromoura
    
    Subscribers: #reviewers, #committers
    
    Tags: #efl
    
    Differential Revision: https://phab.enlightenment.org/D10465
---
 src/lib/elementary/efl_ui_text.c  | 7 -------
 src/lib/elementary/efl_ui_text.eo | 6 +-----
 2 files changed, 1 insertion(+), 12 deletions(-)

diff --git a/src/lib/elementary/efl_ui_text.c b/src/lib/elementary/efl_ui_text.c
index a57ca7e4f9..ec32ab3581 100644
--- a/src/lib/elementary/efl_ui_text.c
+++ b/src/lib/elementary/efl_ui_text.c
@@ -3389,13 +3389,6 @@ _efl_ui_text_efl_access_object_i18n_name_get(const Eo 
*obj, Efl_Ui_Text_Data *pd
    return ret;
 }
 
-EOLIAN static Efl_Text_Cursor_Cursor *
-_efl_ui_text_cursor_new(Eo *obj EINA_UNUSED, Efl_Ui_Text_Data *sd EINA_UNUSED)
-{
-   Eo *text_obj = sd->text_obj;
-   return efl_text_cursor_new(text_obj);
-}
-
 static void
 _edje_signal_emit(Efl_Ui_Text_Data *sd, const char *sig, const char *src)
 {
diff --git a/src/lib/elementary/efl_ui_text.eo 
b/src/lib/elementary/efl_ui_text.eo
index 2118babe50..e742053eb9 100644
--- a/src/lib/elementary/efl_ui_text.eo
+++ b/src/lib/elementary/efl_ui_text.eo
@@ -5,7 +5,7 @@ class @beta Efl.Ui.Text extends Efl.Ui.Layout_Base implements 
Efl.Input.Clickabl
                  Efl.Access.Text, Efl.Access.Editable.Text, Efl.File,
                  Efl.Ui.Text_Selectable
    composites
-                 Efl.Text_Interactive, Efl.Text_Markup
+                 Efl.Text_Interactive, Efl.Text_Markup, Efl.Text_Cursor
 {
    [[A flexible text widget which can be static (as a label) or editable by
      the user (as a text entry). It provides all sorts of editing facilities
@@ -279,10 +279,6 @@ class @beta Efl.Ui.Text extends Efl.Ui.Layout_Base 
implements Efl.Input.Clickabl
             @in data: const(void_ptr) @optional; [[The data to associate with 
the item for related functions.]]
          }
       }
-      cursor_new {
-         [[Creates and returns a new cursor for the text.]]
-         return: ptr(Efl.Text_Cursor_Cursor); [[Text cursor]]
-      }
    }
    implements {
       Efl.Object.constructor;

-- 


Reply via email to