blob: 243a2730890b7f1ea7aaa9d477e2bfc23b765a2b (
plain)
| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 | namespace Foo
{
  using System;
  using DBus;
  using Gtk;
  public class EchoServer
  {
    public static int Main(string [] args)
    {
      Application.Init();
      
      Connection connection = Bus.GetSessionBus();
      Service service = new Service(connection, "org.freedesktop.Test");
      Echoer echoer = new Echoer();
      service.RegisterObject(echoer, "/org/freedesktop/Test/Echoer");
      
      Application.Run();
      
      return 0;
    }
  }
}
 |