升级到Delphi 6 - 兼容性问题之三(完)

 

 

八.             TDesignWindow 的变化

许多变化都和类TDesignWindow有关。它的声明被移到单元DesignWindows中,并且FromClosed方法被替换为DesignerClosed。以往,在FromClosed事件中可以通过访问参数Aform来访问Form。而在新的事件DesignerClosed中,我们需要访问DesignerRoot属性来访问Form

FormClosed事件中,我们可以通过调用TDesignerSelectionList.Create 或者 TComponentList.Create来创建选择列表。而在DesignerClosed事件中作同样的事情,我们得使用IDesignerSelections接口。你可以调用CreateSelectionList函数来获得一个借口。

SelectionClosed方法的参数也和Delphi 5版本中的有所不同。

 

TDesignWindow changes

There have been a number of changes related to the class TDesignWindow. It has been moved to the DesignWindows unit, and its FormClosed method has been replaced by DesignerClosed. In the past, one could obtain access to the form within FormClosed by using the AForm parameter. In DesignerClosed, it is now necessary to use Designer's Root property to access the form.

       In FormClosed, one would create selection lists by calling TDesignerSelectionList.Create or TComponentList.Create. To create selection lists within DesignerClosed, it is necessary to use an IDesignerSelections interface. You can create one using the CreateSelectionList function.

Parameters for the SelectionClosed method are also different from what they were in Delphi 5.

       Borland wishes to thank field tester Matt Palcic for bringing these changes to our attention.

 

九.             VCL 包的变化

一些VCL相关的包已经被重新分配到其他的包里。假如你在工程中引用了vcl50.dcp,那么你需要将这个引用改为其他单元,如vcl.dcprtl.dcp

 

VCL package changes

The contents of some of the VCL-related packages have been redistributed into other packages. If you made references to vcl50.dcp in your project, you will need to change those references to other units, such as vcl.dcp and rtl.dcp.

Borland wishes to thank field tester Clay Shannon for bringing this change to our attention.

 

十.             OpenGL 接口单元改到rtl.dcp

Borland OpenGL接口单元(opengl.dcu)在Delphi 5的库单元目录中是一个独立的单元。在Delphi 6中它被合并到rtl.dcp中。这可能导致某些Delphi 5的工程升级到Delphi 6时引发一些问题。

举个例子来说。在Delphi 5的工程中,可能你会将与OpenGL单元同名的单元放置在工程目录中,以覆盖系统提供的OpenGL单元。而在Delphi 6中,假如有任何组件引用了rtl.dcp,则将导致命名冲突,得更改名称才行。

 

OpenGL interface unit moved to rtl.dcp

The Borland OpenGL interface unit (opengl.dcu) was an independent unit in the Delphi 5 Lib folder. It has been incorporated into rtl.dcp in Delphi 6. This may cause some problems for Delphi 5 projects ported to Delphi 6.

       Here is an example. In a Delphi 5 project, it was possible to make a project-specific override of the OpenGL unit by placing a unit with the same name somewhere in your project path. The same method used in Delphi 6 causes a name conflict in any component that uses rtl.dcp also, and a name change is now required.

Borland wishes to thank field tester John Williams for bringing this change to our attention.

 

十一.             HTTPApp.pas 单元中的一些类型声明移动到 HTTPProd.pas单元中

HTTPApp 单元中的一部分类型被移动到了HTTPProd 单元中。他们是THTMLBgColorTHTMLAlign THTMLVAlign。如果你的工程中使用了这些类,那么需要将引用的单元由HTTPProd改为 HTTPApp

 

Types moved from HTTPApp.pas to HTTPProd.pas

Several types in the HTTPApp unit have been moved to the HTTPProd unit. They are THTMLBgColor, THTMLAlign and THTMLVAlign. If your projects use any of these units, you should change your uses statements to refer to HTTPProd instead HTTPApp.

 

十二.             Search 单元被删除,SearchBuf例程做了修改并被移动

单元SearchDelphi 6中不再保留。SearchBuf例程,用来在一个文本的缓冲区中定位子串,已经被移动到StrUtils单元中,并且调用的参数也发生了变化。最后一个参数改为一个TstringSearchOptions的对象。如果你的工程因为不能找到Search单元而无法编译,请将引用Search改为引用StrUtils单元。同时你应当检查对SearchBuf的调用是否符合新的语法。

 

Search unit removed, SearchBuf moved and changed

The unit Search no longer exists in Delphi 6. The SearchBuf routine, which locates a substring within a text buffer, has been moved to the StrUtils unit and its parameters have changed. The final parameter is now a TStringSearchOptions object. If your project won't compile because the compiler can't find the Search unit, change your uses statement to include StrUtils instead of Search. You will also want to check your SearchBuf calls to ensure that your parameters match the new syntax.

 

[文终]

  • 0
    点赞
  • 0
    收藏
  • 打赏
    打赏
  • 0
    评论
<br> <img src=DownloadFilesdbf_activeximages ddataform_scr.gif> 让你开发的数据库程序更高效更快速地创建数据库表单!<br> <br> Neodeck Data Form ActiveX 控件 让你在数据库应用程序中加入自动针对各个数据表生成相应的录入界面的功能,你只要设置好数据库和需要用的数据表就可以了,剩下的工作它来成。Neodeck Data Form ActiveX控件既可以作为控件被别的程序调用,也可以当做一个整的应用程序来用;支持布尔运算,而且在用户输入数据时能自动搜索数据库之前输入的数据进行匹配比较供用户选择,大大加快了数据输入的速度;还支持用SQL语句来筛选输入数据。<br> <br> Neodeck Data Form ActiveX控件的界面如下,点击放大:<br> <br> <img src=DownloadFilesdbf_activeximages ddataform_scr1.jpg border="0"> <img src=DownloadFilesdbf_activeximages ddataform_scr2.jpg width="143" height="118" border="0"> <br> <br> Neodeck Data Form ActiveX控件的关键特色: 当需要输入文件路径时,提供一个“浏览”按钮让用户查找文件,并自动把文件的路径输入文本框中,极为方便; 本控件支持布尔运算,而且在用户输入数据时能自动搜索数据库之前输入的数据进行匹配比较供用户选择,大大加快了数据输入的速度; Neodeck Data Form ActiveX控件既可以作为控件被别的程序调用,也可以当做一个整的应用程序来用; Neodeck Data Form ActiveX控件还支持用SQL语句来筛选输入数据; Neodeck Data Form ActiveX 的下载: <br>

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
©️2022 CSDN 皮肤主题:大白 设计师:CSDN官方博客 返回首页
评论

打赏作者

musicwind

你的鼓励将是我创作的最大动力

¥2 ¥4 ¥6 ¥10 ¥20
输入1-500的整数
余额支付 (余额:-- )
扫码支付
扫码支付:¥2
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、C币套餐、付费专栏及课程。

余额充值