定义这个枚举 ,有什么用啊,我到现在不知道他有什么用,
QDialogButtonBox::InvalidRole -1 The
button is invalid.
QDialogButtonBox::AcceptRole 0 Clicking the button causes the
dialog to be accepted (e.g. OK).
QDialogButtonBox::RejectRole 1 Clicking the button causes the dialog to be rejected (e.g. Cancel).
QDialogButtonBox::DestructiveRole 2 Clicking the button causes a destructive change (e.g. for Discarding Changes) and closes the dialog.
QDialogButtonBox::ActionRole 3 Clicking the button causes changes to the elements within the dialog.
QDialogButtonBox::HelpRole 4 The button can be clicked to request help.
QDialogButtonBox::YesRole 5 The button is a "Yes"-like button.
QDialogButtonBox::NoRole 6 The button is a "No"-like button.
QDialogButtonBox::ApplyRole 8 The button applies current changes.
QDialogButtonBox::ResetRole 7 The button resets the dialog's fields to default values.
这些枚举值,对
按钮来说有什么意义啊,定义这个按钮功能的吗? 按钮功能不是 通过槽 来实现功能的吗??
[ 此帖被kanyou222在2011-04-18 21:41重新编辑 ]