Quote:
Originally Posted by anakod
Okay, but I don't know how I could rewrite this. This is very simple
PHP Code:
switch(fork())
{
case 0:
{
execlp("/bin/sh", "sh", "-c", "/usr/bin/lipc-set-prop -s com.lab126.keyboard open net.fabiszewski.leafpad:Abc:1", NULL);
}
case -1:
perror("Failed to open keyboard\n");
exit(1);
}
switch(fork())
{
case 0:
{
execlp("/bin/sh", "sh", "-c", "/usr/bin/lipc-set-prop -s com.lab126.keyboard close net.fabiszewski.leafpad", NULL);
}
case -1:
perror("Failed to open keyboard\n");
exit(1);
}
It's all under GPL.
|
These commands use CLI interafce to
/usr/lib/liblipc.so. You can reverse engineer this library and link to it with using appropriate functions directly.