热情软件屋

 

怎样才能用这个MouseInControl的呢


编号:QA004111
建立日期: 2001年4月15日 最后修改日期:2001年4月15日
所属类别:

guzh:
    操作系统:win98
    编程工具:BCB5
    问题:我在BCB5的HELP查到TSpeedButton有这个属性
    Specifies whether the mouse pointer is over the speed button.
    __property bool MouseInControl = {read=FMouseInControl, nodefault};
    
    Description
    
    Use MouseInControl to determine whether the mouse pointer is over the speed button.
    但是我用SpeedButton1->时找不到这个属性呀,请问怎样才能用这个MouseInControl的呢!

回答:

    在C++BUILDER 中的TSpeedButton组件的MouseInControl属性是一个受保护的未发布的属性,所以,你直接是用不了的,你可以从此组件派生一个组件,在派生组件中将其发布,再安装这个派生组件,就可以了。如:
    class TMySpeedButton:public TSpeedButton{
    public:
     TMySpeedButon(TComponent* Owner)();
    __published:
     __property MouseInControl;
    }

此问题由李海回答。

 
把这个问题推荐给朋友
   
   
您的意见类别
您的名字
您的电子邮件
您的建议(请尽可能详细)
 
 

版权所有 1997-2008 热情软件屋
如果您有任何建议和意见, 请给我发个电子邮件 askpro@china-askpro.com
Web Designed by ZebraStudio