回 帖 发 新 帖 刷新版面

主题:[讨论]Re:事件的问题!关注一下!在线等待

测试了一下
发现NMFtpListItem(AnsiString Listing)这个方法只能为类方法,即只能定义在类中

回复列表 (共1个回复)

沙发

这个是事件函数关键字__closure的说明
The __closure keyword is used to declare a special type of pointer to a member function. In standard C++, the only way to get a pointer to a member function is to use the fully qualified member name, as shown in the following example:
class base
{
  public:
    void func(int x) { };
};
typedef void (base::* pBaseMember)(int);
int main(int argc, char* argv[])
{
  base        baseObject;
  pBaseMember m = &base::func; // Get pointer to member 'func'
  // Call 'func' through the pointer to member
  (baseObject.*m)(17);
  return 0;
}
指出了a pointer to a member function

我来回复

您尚未登录,请登录后再回复。点此登录或注册