aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin/termio.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/termio.c')
-rw-r--r--src/bin/termio.c25
1 files changed, 19 insertions, 6 deletions
diff --git a/src/bin/termio.c b/src/bin/termio.c
index 65f6907..7c87a94 100644
--- a/src/bin/termio.c
+++ b/src/bin/termio.c
@@ -369,25 +369,38 @@ termio_title_get(const Evas_Object *obj)
{
Termio *sd = evas_object_smart_data_get(obj);
EINA_SAFETY_ON_NULL_RETURN_VAL(sd, NULL);
+ if (sd->pty->prop.user_title)
+ return sd->pty->prop.user_title;
return sd->pty->prop.title;
}
+const char *
+termio_user_title_get(const Evas_Object *obj)
+{
+ Termio *sd = evas_object_smart_data_get(obj);
+ EINA_SAFETY_ON_NULL_RETURN_VAL(sd, NULL);
+ return sd->pty->prop.user_title;
+}
+
void
-termio_title_set(Evas_Object *obj, const char *title)
+termio_user_title_set(Evas_Object *obj, const char *title)
{
Termio *sd = evas_object_smart_data_get(obj);
size_t len = 0;
EINA_SAFETY_ON_NULL_RETURN(sd);
- if (sd->pty->prop.title)
- eina_stringshare_del(sd->pty->prop.title);
+ if (sd->pty->prop.user_title)
+ {
+ eina_stringshare_del(sd->pty->prop.user_title);
+ sd->pty->prop.user_title = NULL;
+ }
if (title)
- len = strlen(title);
- if (len)
{
- sd->pty->prop.title = eina_stringshare_add_length(title, len);
+ len = strlen(title);
}
+ if (len)
+ sd->pty->prop.user_title = eina_stringshare_add_length(title, len);
if (sd->pty->cb.set_title.func)
sd->pty->cb.set_title.func(sd->pty->cb.set_title.data);
}