curPoint.X :=X;
curPoint.Y :=Y;
oldPoint.X :=Left;
oldPoint.Y :=Top;
end; //end with
end; //end if
end;
procedure Tfrm_long.imgCaptionMouseMove(Sender: TObject;
  Shift: TShiftState; X, Y: Integer);
begin
  if not canmove then exit;
  with Canvas do
  begin
    Rectangle(oldPoint.x,oldPoint.y,oldPoint.x+Width,oldPoint.y+Height);
    oldPoint.x :=Left +X-curPoint.x;
    oldPoint.y :=Top +Y-curPoint.y;
    Rectangle(oldPoint.x,oldPoint.y,oldPoint.x+Width,oldPoint.y+Height);
  end;
end;
procedure Tfrm_long.imgCaptionMouseUp(Sender: TObject;
  Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
  if not canmove then exit;
  with Canvas do
  begin
    Rectangle(oldPoint.x,oldPoint.y,oldPoint.x+Width,oldPoint.y+Height);
    Left :=oldPoint.x;
    Top :=oldPoint.y;
    Free;
  end;
  canmove:=not canmove;
end;
procedure Tfrm_long.FormCreate(Sender: TObject);
begin
  lbCaption.Caption :=Caption;
  dm.ado_user.open;
  dm.ADO_user.Sort:='编号';
  while not dm.ado_user.Eof do
    begin
     e_zzy.items.add(dm.ADO_user.fieldbyname('操作员').AsString);
     dm.ADO_user.Next;
    end;
    e_zzy.ItemIndex:=0
    
end;
procedure Tfrm_long.imgSysIconMouseDown(Sender: TObject;
  Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
  PopSystemMenu.Popup(Left+ImgSysIcon.Left,Top+ImgSysIcon.Top+ImgSysIcon.Height);
end;
procedure Tfrm_long.popSystemMenuPopup(Sender: TObject);
begin
  N_Restore.Enabled :=imgSizeButton.Visible and (WindowState =wsMaximized);
  N_Max.Enabled :=imgSizeButton.Visible and (WindowState =wsNormal);
  n_min.Enabled:=imgMinButton.Visible;
  N_Size.Enabled :=imgSizeButton.Visible ;
end;
procedure Tfrm_long.N_SizeClick(Sender: TObject);
begin
  DefWindowProc(Handle, WM_SYSCOMMAND, SC_SIZE, 0);
end;
procedure Tfrm_long.N_MoveClick(Sender: TObject);
begin
  DefWindowProc(Handle, WM_SYSCOMMAND, SC_MOVE, 0);
end;
procedure Tfrm_long.FormShow(Sender: TObject);
begin
  if WindowState=wsNormal then
    imgSizeButton.Picture.Bitmap :=imgMaxButton.Picture.Bitmap
  else if WindowState=wsMaximized then
    imgSizeButton.Picture.Bitmap :=imgRestoreButton.Picture.Bitmap
end;
procedure Tfrm_long.WMActivate(var Msg: TWMACTIVATE);
begin
  if (Msg.Active =WA_ACTIVE) or (Msg.Active =WA_CLICKACTIVE) then
  begin
    imgCaption.Picture.Bitmap :=imgColorCaption.Picture.Bitmap;
    imgLeftUp1.Picture.Bitmap :=imgColorLeftUp.Picture.Bitmap;
    imgRightUp1.Picture.Bitmap :=imgColorRightUp.Picture.
首页 上一页 2 3 4 5 6 7 8 下一页 尾页 5/12/12
delphi+AccessVCD租赁管理系统(开题报告+源程序+论文正文+外文翻译+答辩ppt)(五)由免费论文网(www.jaoyuw.com)会员上传。

