This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch master
in repository enlightenment.

View the commit online.

commit 3def50bd6a2e172ec18ad0569ad812d8e948ebc8
Author: rafspiny <rafsp...@gmail.com>
AuthorDate: Sun Feb 4 13:02:05 2024 +0100

    Use proper icon
    
    Add icon to edj file
    
    Correct icon
    
    Enable sync for edje keyboard lock/unlock
    Fix keyboard signals in icon
    Using the correct part from the edje
---
 src/modules/convertible/e-gadget-convertible.c   |  23 +++++++++++++++++------
 src/modules/convertible/e-module-convertible.edj | Bin 11127 -> 15359 bytes
 src/modules/convertible/e_mod_main.c             |   4 ++--
 3 files changed, 19 insertions(+), 8 deletions(-)

diff --git a/src/modules/convertible/e-gadget-convertible.c b/src/modules/convertible/e-gadget-convertible.c
index 83ae074e7..14ba9db80 100644
--- a/src/modules/convertible/e-gadget-convertible.c
+++ b/src/modules/convertible/e-gadget-convertible.c
@@ -17,9 +17,15 @@ _update_instances(const Instance *current_instance)
         {
             instance->locked_position = current_instance->locked_position;
             if (instance->locked_position == EINA_TRUE)
-                edje_object_signal_emit(instance->o_button, "lock,rotation,icon", "convertible/tablet");
+                edje_object_signal_emit(instance->o_button, "e,lock,rotation,icon", "convertible/tablet");
             else
-                edje_object_signal_emit(instance->o_button, "unlock,rotation,icon", "convertible/tablet");
+                edje_object_signal_emit(instance->o_button, "e,unlock,rotation,icon", "convertible/tablet");
+
+	        instance->disabled_keyboard = current_instance->disabled_keyboard;
+            if (instance->disabled_keyboard == EINA_TRUE)
+                edje_object_signal_emit(instance->o_button, "e,disable,keyboard,icon", "convertible/input");
+            else
+                edje_object_signal_emit(instance->o_button, "e,enable,keyboard,icon", "convertible/input");
         }
     }
 }
@@ -28,11 +34,10 @@ void
 _rotation_signal_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, const char *sig EINA_UNUSED,
                          const char *src EINA_UNUSED)
 {
-   DBG("Rotation: Signal %s received from %s", sig, src);
    Instance *inst = data;
-   if (eina_str_has_prefix(sig, "unlock"))
+   if (eina_str_has_prefix(sig, "e,unlock"))
       inst->locked_position = EINA_FALSE;
-   if (eina_str_has_prefix(sig, "lock"))
+   if (eina_str_has_prefix(sig, "e,lock"))
       inst->locked_position = EINA_TRUE;
    _update_instances(inst);
 }
@@ -41,5 +46,11 @@ void
 _keyboard_signal_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, const char *sig EINA_UNUSED,
                          const char *src EINA_UNUSED)
 {
-   DBG("Keyboard: Signal %s received from %s", sig, src);
+   Instance *inst = data;
+   if (eina_str_has_prefix(sig, "e,enable,keyboard"))
+      inst->disabled_keyboard = EINA_FALSE;
+   if (eina_str_has_prefix(sig, "e,disable,keyboard"))
+      inst->disabled_keyboard = EINA_TRUE;
+   _update_instances(inst);
+
 }
diff --git a/src/modules/convertible/e-module-convertible.edj b/src/modules/convertible/e-module-convertible.edj
old mode 100755
new mode 100644
index 0fb2f9b06..74f653d31
Binary files a/src/modules/convertible/e-module-convertible.edj and b/src/modules/convertible/e-module-convertible.edj differ
diff --git a/src/modules/convertible/e_mod_main.c b/src/modules/convertible/e_mod_main.c
index d4a347d89..cedcf400d 100644
--- a/src/modules/convertible/e_mod_main.c
+++ b/src/modules/convertible/e_mod_main.c
@@ -85,8 +85,8 @@ _gc_init(E_Gadcon *gc, const char *name, const char *id, const char *style)
     INF("Adding callback for creation and other events from EDJE");
     edje_object_signal_callback_add(evas_object, "e,lock,rotation", "tablet", _rotation_signal_cb, instance);
     edje_object_signal_callback_add(evas_object, "e,unlock,rotation", "tablet", _rotation_signal_cb, instance);
-    edje_object_signal_callback_add(evas_object, "e,enable,keyboard", "keyboard", _keyboard_signal_cb, instance);
-    edje_object_signal_callback_add(evas_object, "e,disable,keyboard", "keyboard", _keyboard_signal_cb, instance);
+    edje_object_signal_callback_add(evas_object, "e,enable,keyboard", "input", _keyboard_signal_cb, instance);
+    edje_object_signal_callback_add(evas_object, "e,disable,keyboard", "input", _keyboard_signal_cb, instance);
     
     inst->o_button = evas_object;
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to