简体   繁体   English

使用Delphi XE2的AnimateWindow

[英]AnimateWindow with Delphi XE2

Hello I have a problem with the AnimateWindow function in Delphi XE2, the problem is when I use the skins offered XE2 found in the windows appearances, when using a skin any and combined with AnimateWindow, the program blends the normal design of the windows of part of the window with skins, the worst is that the window is frozen and can not move more. 您好我在Delphi XE2中的AnimateWindow函数有问题,问题是当我使用在Windows外观中找到的XE2提供的皮肤时,当使用任何皮肤并与AnimateWindow结合时,该程序混合了部分窗口的正常设计带有皮肤的窗户,最糟糕的是窗户被冻结而且不能移动得更多。 The code is only this: 代码只有这样:

procedure TForm1.FormCreate(Sender: TObject);
begin
  AnimateWindow(Form1.Handle,200, AW_CENTER);
end;

How do I fix this? 我该如何解决?

The problem seems to exist in all versions that provides 'Styles' (XE2 .. X Seattle) and can easily be repeated as follows: 问题似乎存在于提供“样式”(XE2 .. X Seattle)的所有版本中,并且可以轻松地重复如下:

  • New VCL project 新的VCL项目
  • Project Options - Appearance - Any available style 项目选项 - 外观 - 任何可用的样式

Add code as in the question 添加问题中的代码

procedure TForm2.FormCreate(Sender: TObject);
begin
  AnimateWindow(Form2.Handle,200, AW_CENTER);
end;

And run. 并运行。 The window appears on the screen but is totally unresponsive. 窗口出现在屏幕上,但完全没有响应。 Controls on the window do appear to work normally (so far only minimal testing). 窗口上的控件似乎正常工作(到目前为止只进行了最少的测试)。

A workaround is to set the Position property to something else than the default poDefault . 解决方法是将Position属性设置为默认poDefault以外的其他属性。

Embarcadero quality central search did not bring up any report. Embarcadero质量中心搜索没有提出任何报告。 I will file a report after I do some more investigation. 在我做了一些调查之后,我会提交一份报告。


Reported, RSP-13459, Window with style applied freezes on call to AnimateWindow 报告,RSP-13459,应用样式的窗口在调用AnimateWindow时冻结


Update 24.4.2016 Yesterday I received a notification regarding RSP-13459: 更新24.4.2016昨天我收到了有关RSP-13459的通知:

This issue is fixed for 10.1 Berlin, it does not reproduce it with build 24.0.22088.5349.1. 这个问题已针对10.1柏林修复,它不会使用build 24.0.22088.5349.1重现它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM