Пример #1
0
        static void HandleKeyPress(object sender, KeyPressEventArgs args)
        {
            uint symbol = args.Event.Symbol;

            Gdk.Key key = (Gdk.Key)Enum.Parse(typeof(Gdk.Key), symbol.ToString());

            switch (key)
            {
            case Gdk.Key.s:
                timeline.Start();

                TestThreadData data    = new TestThreadData(count_label, timeline);
                ThreadWrapper  wrapper = new ThreadWrapper(data);

                Thread thread = new Thread(wrapper.ThreadMethod);
                thread.Start();
                break;

            case Gdk.Key.q:
                Clutter.Main.Quit();
                break;
            }
        }
Пример #2
0
 public ThreadWrapper(TestThreadData data)
 {
     this.data = data;
 }
Пример #3
0
 public TestUpdate(int count, TestThreadData data)
 {
     this.count = count;
     this.data  = data;
 }