2015-04-26 01:46:51 +00:00
|
|
|
import std.stdio;
|
|
|
|
import ddbus.c_lib;
|
2015-04-29 01:00:48 +00:00
|
|
|
import ddbus.thin;
|
2015-04-26 01:46:51 +00:00
|
|
|
|
|
|
|
void main()
|
|
|
|
{
|
2015-04-29 01:00:48 +00:00
|
|
|
Connection conn = connectToBus();
|
|
|
|
for(int i = 0; i < 50; i++) {
|
|
|
|
Message msg = new Message("ca.thume.transience","/ca/thume/transience/screensurface",
|
|
|
|
"ca.thume.transience.screensurface","testDot");
|
|
|
|
conn.sendBlocking(msg);
|
|
|
|
}
|
|
|
|
Message msg2 = new Message("ca.thume.transience","/ca/thume/transience/screensurface",
|
|
|
|
"ca.thume.transience.screensurface","testPing");
|
|
|
|
Message res = conn.sendWithReplyBlocking(msg2,3000);
|
|
|
|
int result = res.read!int();
|
|
|
|
writeln(result);
|
2015-04-26 01:46:51 +00:00
|
|
|
writeln("It worked!");
|
|
|
|
}
|