Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2005.11.13;
Скачать: CL | DM;

Вниз

ControlAtPos   Найти похожие ветки 

 
Vladimir88 ©   (2005-10-20 17:34) [0]

procedure TfmMain.ApplicationEvents1Hint(Sender: TObject);
var
Control:TControl;
begin
Control:=ControlAtPos(ScreenToClient(Mouse.CursorPos),false);
showmessage(Control.Name);
end;


Почему-то Control всегда нил, в чём может быть проблема.


 
begin...end ©   (2005-10-20 17:40) [1]

> Vladimir88 ©   (20.10.05 17:34)
> Почему-то Control всегда нил, в чём может быть проблема.

Ну... Например, приведённый код не будет находить контролы, являющиеся потомками TWinControl. Может быть, в этом дело?


 
Vladimir88 ©   (2005-10-20 17:47) [2]

Хм, а почему TWinControl же потомок контрола.


 
begin...end ©   (2005-10-20 17:49) [3]

> Vladimir88 ©   (20.10.05 17:47) [2]

function ControlAtPos(const Pos: TPoint; AllowDisabled: Boolean, AllowWinControls:Boolean=False): TControl;

The AllowWinControls parameter determines whether descendants of TWinControl are considered when looking for the child control.


 
Vladimir88 ©   (2005-10-20 17:50) [4]

А, точно, стормозил, сенкс.



Страницы: 1 вся ветка

Текущий архив: 2005.11.13;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.06 c
2-1130072381
tmc
2005-10-23 16:59
2005.11.13
Переменные среды Windows и TIniFile.Create


6-1122973910
stud
2005-08-02 13:11
2005.11.13
idHTTP настройки прокси


8-1110227158
Sash1988
2005-03-07 23:25
2005.11.13
Графика в OpenGL


3-1128068250
KeyC
2005-09-30 12:17
2005.11.13
Direct access to MS Access


14-1130003274
midori
2005-10-22 21:47
2005.11.13
groups.google.ru