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

Вниз

shift: TShiftState;   Найти похожие ветки 

 
Noway ©   (2004-03-16 11:13) [0]

как работать с shift: TShiftState в событиии OnMouseMove?


 
serge ©   (2004-03-16 11:18) [1]

Все очень просто - жмешь Ф1 а там есть пунктик такой - екзампле


procedure TForm1.FormMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
begin
 if ssLeft in Shift then { make sure button is down }
 begin
   if Y > StartY then
     begin
     StatusBar1.Panels[0].Text := "Top: " + IntToStr(StartY);
     StatusBar1.Panels[2].Text := "Bottom: " + IntToStr(Y);
     end
   else
     begin
     StatusBar1.Panels[0].Text := "Top: " + IntToStr(Y);
     StatusBar1.Panels[2].Text := "Bottom: " + IntToStr(StartY);

     end;
   if X > StartX then
     begin
     StatusBar1.Panels[1].Text := "Left: " + IntToStr(StartX);
     StatusBar1.Panels[3].Text := "Right: " + IntToStr(X);
     end
   else
     begin
     StatusBar1.Panels[1].Text := "Left: " + IntToStr(X);
     StatusBar1.Panels[3].Text := "Right: " + IntToStr(StartX);
     end;
 end;
end;


 
miwa ©   (2004-03-16 11:18) [2]

if (ssShift in shift) of (ssCtrl in Shift) then...


 
Agent13 ©   (2004-03-16 11:19) [3]

if ssShift in Shift then нажата клавиша Shift и т.п.


 
miwa ©   (2004-03-16 11:20) [4]

Упс...
Не только не успел, но еще и ошибся :о((
Имел в виду

if (ssShift in Shift) OR (ssCtrl in Shift) then...



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

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

Наверх




Память: 0.47 MB
Время: 0.032 c
1-1079670705
MPS
2004-03-19 07:31
2004.04.04
Всплывающая подсказка > 128 символов в трее


14-1079013019
Nikolay M.
2004-03-11 16:50
2004.04.04
Злоумышленники в интернете: кони и куки! :))))


3-1078483923
Vic
2004-03-05 13:52
2004.04.04
Выделенная запись в Grid


1-1079612266
Сниф
2004-03-18 15:17
2004.04.04
Где можно взять подробный пример создания Com-объекта?


1-1079156477
Kair
2004-03-13 08:41
2004.04.04
Splash screen