summaryrefslogtreecommitdiff
path: root/src/lib/elput/elput_manager.c
diff options
context:
space:
mode:
authorChris Michael <cpmichael@osg.samsung.com>2016-05-09 11:35:48 -0400
committerChris Michael <cpmichael@osg.samsung.com>2016-05-09 11:35:48 -0400
commitf9149c1699515c060d004225c6a2c5653cebe322 (patch)
treed334079803dda24320ac438e07ee4859a3cb37e3 /src/lib/elput/elput_manager.c
parenta96266c42272bd6b8d3a27d7fdd7575199772c85 (diff)
elput: Add API function to switch to a given vt
This patch adds a new API function to Elput that can be used to switch to a given VT. This allows drm2 or enlightenment to switch to a given virtual terminal in response to keybindings. @feature Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
Diffstat (limited to 'src/lib/elput/elput_manager.c')
-rw-r--r--src/lib/elput/elput_manager.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/lib/elput/elput_manager.c b/src/lib/elput/elput_manager.c
index 3dc67d9594..e267951b30 100644
--- a/src/lib/elput/elput_manager.c
+++ b/src/lib/elput/elput_manager.c
@@ -62,3 +62,16 @@ elput_manager_close(Elput_Manager *manager, int fd)
62 if (manager->interface->close) 62 if (manager->interface->close)
63 manager->interface->close(manager, fd); 63 manager->interface->close(manager, fd);
64} 64}
65
66EAPI Eina_Bool
67elput_manager_vt_set(Elput_Manager *manager, int vt)
68{
69 EINA_SAFETY_ON_NULL_RETURN_VAL(manager, EINA_FALSE);
70 EINA_SAFETY_ON_NULL_RETURN_VAL(manager->interface, EINA_FALSE);
71 EINA_SAFETY_ON_TRUE_RETURN_VAL((vt < 0), EINA_FALSE);
72
73 if (manager->interface->vt_set)
74 return manager->interface->vt_set(manager, vt);
75
76 return EINA_FALSE;
77}