wxWidgets事件处理机制  被引量:2

The Mechanism of Handling Events in wxWidgets

在线阅读下载全文

作  者:张枫[1] 张晓民[1] 

机构地区:[1]南阳理工学院软件学院,河南南阳473000

出  处:《电脑与电信》2014年第4期43-45,48,共4页Computer & Telecommunication

摘  要:wxWidgets是一个可以在多个平台上进行图形用户界面开发的C++语言框架库。如同其它所有的GUI框架一样,wxWidgets的程序控制采用事件驱动的方式。wxWidgets主要有两种方法来处理事件:一种通过事件表宏定义静态地把事件和事件处理过程绑定在一起;另外一种通过函数动态地绑定事件和事件处理过程。本文介绍了这两种事件处理方法并对其作出分析比较,说明了动态事件处理机制代码量稍大但比静态事件表机制更加灵活方便。wxWidgets is a C++ framework providing GUI (Graphical User Interface) and other facilities on multi-platforms. Like other GUI frameworks, the control of flow in wxWidgets applications is event-based. There are two principal ways to handle events in wxWidgets. One of them uses event table macros and allows you to define the binding between events and their handlers only statically; the other way maps events and their handlers dynamically. The paper introduces and analyzes the two methods and summarizes that the dynamical way requires slightly more codes but is much more flexible than the static way.

关 键 词:跨平台 事件驱动 绑定 

分 类 号:TP311.52[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象