Display类:
Instances of this class are responsible for managing the connection between SWT and the underlying operating system.
一、Display.readAndDispatch(),方法从操作系统的事件队列读取事件,正确的分发(分配给正确的监听器listenner),如果还有潜在的事情可做,则返回true,就可以继续调用readAndDisplay(),否则可以调用sleep()函数。
问题:
1、操作系统的事件队列是怎么组织的。
2、sleep()后awake的时机是什么时候。
3、readAndDispatch()函数是给哪个线程分发任务,是user_interface Thread吗?
4、什么样的方法只能由the user-interface thread call.
5、代码中那些代码是有UI线程运行的。
most of the public methods in Widget and its subclasses
二、the differences between Display.asyncExec() and Display.syncExec()
the caller which calls Display.asyncExec run in parallel,and is not notified when the runnable has completed. Otherwise the caller which calls Display.syncExec() is suspended until the runnable completes.
三、Eclipse中启动采用什么类型是什么意思,怎么样能用命令行实现同样的功能。

没有评论:
发表评论