亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bsbuttongroup.pas

?? BusinessSkinForm Ver3.95 full source_漢化版_最新
?? PAS
?? 第 1 頁 / 共 4 頁
字號:
  end;
end;

procedure TbsSkinButtonGroup.DoFillRect(const Rect: TRect);
begin
  Canvas.FillRect(Rect);
end;

procedure TbsSkinButtonGroup.DrawSkinButton(Index: Integer; Canvas: TCanvas;
      Rct: TRect; State: TbsButtonDrawState); 
var
  R, SR: TRect;
  ButtonData: TbsDataSkinButtonControl;
  Buffer: TBitMap;
  CIndex: Integer;
  NewLTPoint, NewRTPoint, NewLBPoint, NewRBPoint: TPoint;
  NewClRect: TRect;
  XO, YO: Integer;
  C: TColor;
  FSkinPicture: TBitMap;
  ButtonItem: TbsGrpButtonItem;
begin
  Buffer := TBitMap.Create;
  Buffer.Width := RectWidth(Rct);
  Buffer.Height := RectHeight(Rct);

  CIndex := SkinData.GetControlIndex('resizebutton');
  ButtonData := SkinData.CtrlList[CIndex];
  with ButtonData do
  begin
    if bsbdsDown in State then
    begin
      SR := DownSkinRect;
      C := DownFontColor;
    end
    else
    if bsbdsSelected in State
    then
      begin
        SR := ActiveSkinRect;
        C := ActiveFontColor;
      end
    else
    if bsbdsHot in State
    then
      begin
        SR := ActiveSkinRect;
        C := ActiveFontColor;
      end
   else
    begin
      SR := SkinRect;
      C := FontColor;
    end;
    if IsNullRect(SR) then SR := SkinRect;
    XO := RectWidth(Rct) - RectWidth(SR);
    YO := RectHeight(Rct) - RectHeight(SR);
    NewLTPoint := LTPoint;
    NewRTPoint := Point(RTPoint.X + XO, RTPoint.Y);
    NewLBPoint := Point(LBPoint.X, LBPoint.Y + YO);
    NewRBPoint := Point(RBPoint.X + XO, RBPoint.Y + YO);
    NewClRect := Rect(CLRect.Left, ClRect.Top,
      CLRect.Right + XO, ClRect.Bottom + YO);

    FSkinPicture := TBitMap(FSD.FActivePictures.Items[ButtonData.PictureIndex]);

    CreateSkinImage(LTPoint, RTPoint, LBPoint, RBPoint, CLRect,
         NewLtPoint, NewRTPoint, NewLBPoint, NewRBPoint, NewCLRect,
         Buffer, FSkinPicture, SR, Buffer.Width, Buffer.Height, True);

    //
    if (bsbdsFocused in State) and FShowFocus
    then
      begin
        R := NewClRect;
        InflateRect(R, 1, 1);
        Buffer.Canvas.DrawFocusRect(R);
      end;
    // draw glpyh and text
    Buffer.Canvas.Font.Name := FontName;
    Buffer.Canvas.Font.Style := FontStyle;
    Buffer.Canvas.Font.Height := FontHeight;
    Buffer.Canvas.Font.Color := C;
    if SkinData.ResourceStrData <>  nil
    then
      Buffer.Canvas.Font.Charset := SkinData.ResourceStrData.CharSet
    else
      Buffer.Canvas.Font.Charset := Font.CharSet;
    //
    ButtonItem := FButtonItems[Index];

    if gboShowCaptions in FButtonOptions
    then
      DrawImageAndText(Buffer.Canvas, NewClRect, -1, 2, blGlyphLeft,
         ButtonItem.Caption, ButtonItem.ImageIndex, FImages, bsbdsDown in State, True)
    else
      DrawImageAndText(Buffer.Canvas, NewClRect, -1, 0, blGlyphLeft,
         '', ButtonItem.ImageIndex, FImages, bsbdsDown in State, True);
  end;
  Canvas.Draw(Rct.Left, Rct.Top, Buffer);
  Buffer.Free;
end;

procedure TbsSkinButtonGroup.DrawButton(Index: Integer; Canvas: TCanvas;
  Rect: TRect; State: TbsButtonDrawState);
var
  ButtonItem: TbsGrpButtonItem;
  FillColor: TColor;
  EdgeColor: TColor;
  TextRect: TRect;
  R, OrgRect: TRect;
  CIndex: Integer;
begin
  if Assigned(FOnDrawButton) and (not (csDesigning in ComponentState)) then
    FOnDrawButton(Self, Index, Canvas, Rect, State)
  else
  begin
    if (SkinData <> nil) and not (SkinData.Empty)
    then
      begin
        CIndex := SkinData.GetControlIndex('resizebutton');
        if CIndex <> -1
        then
          begin
            DrawSkinButton(Index, Canvas, Rect, State);
            Exit;
          end;
      end;

    OrgRect := Rect;
    Canvas.Font := Font;

    if bsbdsDown in State then
    begin
      EdgeColor := BS_XP_BTNFRAMECOLOR;
      Canvas.Brush.Color := BS_XP_BTNDOWNCOLOR;
      Canvas.Font.Color := clBtnText;
    end
    else
    if bsbdsHot in State then
    begin
       EdgeColor := BS_XP_BTNFRAMECOLOR;
      Canvas.Brush.Color := BS_XP_BTNACTIVECOLOR;
      Canvas.Font.Color := clBtnText;
    end
    else
    if bsbdsSelected in State then
    begin
      EdgeColor := BS_XP_BTNFRAMECOLOR;
      Canvas.Brush.Color := BS_XP_BTNACTIVECOLOR;
      Canvas.Font.Color := clBtnText;
    end

    else
    begin
      EdgeColor := clBtnShadow;
      Canvas.Brush.Color := clBtnFace;
      Canvas.Font.Color := clBtnText;
    end;

    if Assigned(FOnBeforeDrawButton) then
      FOnBeforeDrawButton(Self, Index, Canvas, Rect, State);

    FillColor := Canvas.Brush.Color;
    Canvas.FillRect(Rect);

    InflateRect(Rect, -2, -1);

    { Draw the edge outline }
    Canvas.Brush.Color := EdgeColor;
    Canvas.FrameRect(Rect);
    Canvas.Brush.Color := FillColor;

    TextRect := Rect;
    InflateRect(TextRect, -4, -4);

    if (bsbdsFocused in State) and FShowFocus
    then
      begin
        R := Rect;
        InflateRect(R, -2, -2);
        Canvas.DrawFocusRect(R);
      end;

    ButtonItem := FButtonItems[Index];

    if gboShowCaptions in FButtonOptions
    then
      DrawImageAndText(Canvas, TextRect, -1, 2, blGlyphLeft,
         ButtonItem.Caption, ButtonItem.ImageIndex, FImages, bsbdsDown in State, True)
    else
      DrawImageAndText(Canvas, TextRect, -1, 0, blGlyphLeft,
         '', ButtonItem.ImageIndex, FImages, bsbdsDown in State, True);


    if Assigned(FOnAfterDrawButton) then
      FOnAfterDrawButton(Self, Index, Canvas, OrgRect, State);
  end;
  Canvas.Brush.Color := Color; { Restore the original color }
end;

procedure TbsSkinButtonGroup.SetOnDrawButton(const Value: TbsGrpButtonDrawEvent);
begin
  FOnDrawButton := Value;
  Invalidate;
end;

procedure TbsSkinButtonGroup.SetOnDrawIcon(const Value: TbsGrpButtonDrawIconEvent);
begin
  FOnDrawIcon := Value;
  Invalidate;
end;

procedure TbsSkinButtonGroup.CreateHandle;
begin
  inherited CreateHandle;
  { Make sure that we are showing the scroll bars, if needed }
  Resize;
end;

procedure TbsSkinButtonGroup.WMMouseLeave(var Message: TMessage);
begin
  FMouseInControl := False;
  if FHotIndex <> -1 then
  begin
    UpdateButton(FHotIndex);
    FHotIndex := -1;
    DoHotButton;
  end;
  if FDragImageList.Dragging then
  begin
    FDragImageList.HideDragImage;
    RemoveInsertionPoints;
    UpdateWindow(Handle);
    FDragImageList.ShowDragImage;
  end;
  DoMouseLeave;
end;

procedure TbsSkinButtonGroup.MouseDown(Button: TMouseButton; Shift: TShiftState;
  X, Y: Integer);
begin
  inherited;
  if Button = mbLeft then
  begin
    { Focus ourselves, when clicked, like a button would }
    if not Focused then
      Windows.SetFocus(Handle);

    FDragStarted := False;
    FDownIndex := IndexOfButtonAt(X, Y);
    if FDownIndex <> -1 then
    begin
      if bsgboAllowReorder in ButtonOptions then
        FDragIndex := FDownIndex;
      FDragStartPos := Point(X, Y);
      { If it is the same as the selected, don't do anything }
      if FDownIndex <> FItemIndex then
        UpdateButton(FDownIndex)
      else
        FDownIndex := -1;
    end;
  end;
end;

procedure TbsSkinButtonGroup.MouseMove(Shift: TShiftState; X, Y: Integer);
var
  NewHotIndex, OldHotIndex: Integer;
  EventTrack: TTrackMouseEvent;
  DragThreshold: Integer;
begin
  inherited;
  { Was the drag threshold met? }
  if (bsgboAllowReorder in ButtonOptions) and (FDragIndex <> -1) then
  begin
    DragThreshold := Mouse.DragThreshold;
    if (Abs(FDragStartPos.X - X) >= DragThreshold) or
        (Abs(FDragStartPos.Y - Y) >= DragThreshold) then
    begin
      FDragStartPos.X := X; { Used in the start of the drag }
      FDragStartPos.Y := Y;
      FDownIndex := -1; { Stops repaints and clicks }
      if FHotIndex <> -1 then
      begin
        OldHotIndex := FHotIndex;
        FHotIndex := -1;
        UpdateButton(OldHotIndex);
        { We must have the window process the paint message before
          the drag operation starts }
        UpdateWindow(Handle);
        DoHotButton;
      end;
      FDragStarted := True;
      BeginDrag(True, -1);
      Exit;
    end;
  end;

  NewHotIndex := IndexOfButtonAt(X, Y);
  if NewHotIndex <> FHotIndex then
  begin
    OldHotIndex := FHotIndex;
    FHotIndex := NewHotIndex;
    UpdateButton(OldHotIndex);
    if FHotIndex <> -1 then
      UpdateButton(FHotIndex);
    DoHotButton;
  end;
  if not FMouseInControl then
  begin
    FMouseInControl := True;
    EventTrack.cbSize := SizeOf(TTrackMouseEvent);
    EventTrack.dwFlags := TME_LEAVE;
    EventTrack.hwndTrack := Handle;
    EventTrack.dwHoverTime := 0;
    TrackMouseEvent(EventTrack);
  end;
end;

procedure TbsSkinButtonGroup.MouseUp(Button: TMouseButton; Shift: TShiftState; X,
  Y: Integer);
var
  LastDown: Integer;
begin
  inherited;
  if (Button = mbLeft) and (not FDragStarted) then
  begin
    LastDown := FDownIndex;
    FDownIndex := -1;
    FDragIndex := -1;
    if (LastDown <> -1) and (IndexOfButtonAt(X, Y) = LastDown)
      and (FDragIndex = -1) then
    begin
      UpdateButton(LastDown);
      DoItemClicked(LastDown);
      if bsgboGroupStyle in ButtonOptions then
        ItemIndex := LastDown;
    end
    else if LastDown <> -1 then
      UpdateButton(LastDown);
    if Assigned(FOnClick) then
      FOnClick(Self);
  end;
  FDragStarted := False;
end;

function TbsSkinButtonGroup.IndexOfButtonAt(const X, Y: Integer): Integer;
var
  ButtonsPerRow: Integer;
  HiddenCount: Integer;
  Row, Col: Integer;
begin
  Result := -1;
  { Is it within our X and Y bounds first? }
  if (X >= 0) and (X < ClientWidth) and (Y >= 0) and (Y < Height) then
  begin
    ButtonsPerRow := CalcButtonsPerRow;
    HiddenCount := FHiddenItems*ButtonsPerRow;
    Row := Y div FButtonHeight;
    if bsgboFullSize in FButtonOptions then
      Col := 0
    else
      Col := X div FButtonWidth;

    Result := HiddenCount + Row*ButtonsPerRow + Col;

    if Result >= FButtonItems.Count then
      Result := -1
    else if (Row+1)*FButtonHeight > Height then
      Result := -1 { Item is clipped }
    else if not (bsgboFullSize in FButtonOptions)
    then
      begin
        if (Col + 1) * FButtonWidth > ClientWidth - GetScrollSize
        then
          Result := -1;
      end;
  end;
end;

procedure TbsSkinButtonGroup.DoItemClicked(const Index: Integer);
begin
  if Assigned(FButtonItems[Index].OnClick) then
    FButtonItems[Index].OnClick(Self)
  else if Assigned(FOnButtonClicked) then
    FOnButtonClicked(Self, Index);
end;

procedure TbsSkinButtonGroup.DragDrop(Source: TObject; X, Y: Integer);
var
  TargetIndex: Integer;
begin
  if (Source = Self) and (bsgboAllowReorder in ButtonOptions) then
  begin
    RemoveInsertionPoints;
    TargetIndex := TargetIndexAt(X, Y);
    if TargetIndex > FDragIndex then
      Dec(TargetIndex); { Account for moving ourselves }
    if TargetIndex <> -1 then
      DoReorderButton(FDragIndex, TargetIndex);
    FDragIndex := -1;
  end
  else
    inherited;
end;

const
  cScrollBuffer = 6;

procedure TbsSkinButtonGroup.DragOver(Source: TObject; X, Y: Integer;
  State: TDragState; var Accept: Boolean);
var
  OverIndex: Integer;
begin
  if (Source = Self) and (bsgboAllowReorder in ButtonOptions) then
  begin
    { If the mouse is within the bottom cScrollBuffer pixels,
      then "auto-scroll" }
    if (FHiddenItems < FScrollBarMax) and (Y <= Height) and
         (Y >= Height - cScrollBuffer) and (X >= 0) and (X <= Width) then
      AutoScroll(scLineDown)
    else if (FHiddenItems > 0) and (Y >= 0) and
         (Y <= cScrollBuffer) and (X >= 0) and (X <= Width) then
      AutoScroll(scLineUp);

    OverIndex := TargetIndexAt(X, Y);
    { Don't accept when it is the same as the start or right after us }
    Accept := (OverIndex <> -1) and (OverIndex <> FDragIndex) and
      (OverIndex <> FDragIndex + 1) and (Items.Count > 1);
    FDragImageList.HideDragImage;
    if Accept and (State <> dsDragLeave) then
      SetInsertionPoints(OverIndex)
    else
      RemoveInsertionPoints;
    UpdateWindow(Handle);
    FDragImageList.ShowDragImage;
  end
  else
    inherited DragOver(Source, X, Y, State, Accept);
end;

procedure TbsSkinButtonGroup.DoHotButton;
begin
  if Assigned(FOnHotButton) then
    FOnHotButton(Self, FHotIndex);
end;

procedure TbsSkinButtonGroup.DoStartDrag(var DragObject: TDragObject);
var
  ButtonRect: TRect;
  State: TbsButtonDrawState;
  DragImage: TBitmap;
begin
  inherited DoStartDrag(DragObject);
  if FDragIndex <> -1 then
  begin
    DragImage := TBitmap.Create;
    try
      ButtonRect := GetButtonRect(FDragIndex);
      DragImage.Width := ButtonRect.Right - ButtonRect.Left;
      DragImage.Height := ButtonRect.Bottom - ButtonRect.Top;
      State := [bsbdsDragged];
      if FItemIndex = FDragIndex then
        State := State + [bsbdsSelected];
      DrawButton(FDragIndex, DragImage.Canvas,
        Rect(0, 0, DragImage.Width, DragImage.Height), State);
      FDragImageList.Clear;
      FDragImageList.Width := DragImage.Width;
      FDragImageList.Height := DragImage.Height;
      FDragImageList.Add(DragImage, nil);
{      with FDragImageList.DragHotspot do
      begin
        X := FDragStartPos.X - ButtonRect.Left - Mouse.DragThreshold;
        Y := FDragStartPos.Y - ButtonRect.Top - Mouse.DragThreshold;
      end;}
    finally
      DragImage.Free;
    end;
  end
  else
    FDragImageList.Clear; { No drag image } 
end;

function TbsSkinButtonGroup.GetDragImages: TDragImageList;
begin
  Result := FDragImageList;
end;

procedure TbsSkinButtonGroup.RemoveInsertionPoints;
  procedure ClearSelection(var Index: Integer);
  var
    OldIndex: Integer;
  begin
    if Index <> -1 then
    begin
      OldIndex := Index;
      Index := -1;
      UpdateButton(OldIndex);
    end;
  end;

begin

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产成人在线影院| 日韩女同互慰一区二区| 欧美日韩一区不卡| 国产视频亚洲色图| 日韩国产成人精品| 一本一道波多野结衣一区二区 | 2021国产精品久久精品| 亚洲精品国产视频| 波多野结衣91| 国产日产欧美一区二区视频| 日韩高清国产一区在线| 在线免费精品视频| 国产精品毛片久久久久久| 麻豆精品新av中文字幕| 欧美丰满美乳xxx高潮www| 一二三区精品视频| 色婷婷综合中文久久一本| 欧美国产成人精品| 国产91色综合久久免费分享| 久久久久久久综合日本| 国产最新精品免费| 精品久久一二三区| 极品美女销魂一区二区三区| 欧美tickling网站挠脚心| 奇米888四色在线精品| 91精品国产福利| 日产国产高清一区二区三区| 欧美视频自拍偷拍| 亚洲福利一区二区| 777a∨成人精品桃花网| 日韩精品福利网| 欧美精品一二三四| 日本伊人精品一区二区三区观看方式| 欧美日韩一级视频| 日本不卡中文字幕| 精品免费日韩av| 国产精品中文字幕一区二区三区| 久久影音资源网| 懂色一区二区三区免费观看| 中文字幕精品三区| 91论坛在线播放| 亚洲国产精品一区二区久久恐怖片| 欧美曰成人黄网| 亚洲国产aⅴ天堂久久| 欧美美女bb生活片| 久久国产精品色| 久久久激情视频| 91看片淫黄大片一级在线观看| 伊人婷婷欧美激情| 欧美精品视频www在线观看| 秋霞电影网一区二区| 精品久久久三级丝袜| 高清不卡一区二区在线| 亚洲三级在线播放| 欧美日韩午夜影院| 国产一区二区三区免费播放 | av中文字幕亚洲| 亚洲免费三区一区二区| 欧美日韩第一区日日骚| 精品在线你懂的| 国产精品蜜臀在线观看| 欧美日韩在线综合| 国内精品伊人久久久久av一坑| 亚洲欧洲另类国产综合| 欧美精品乱人伦久久久久久| 国产精品77777| 亚洲一区二区精品3399| 久久久久免费观看| 欧美性三三影院| 粉嫩嫩av羞羞动漫久久久 | 亚洲欧洲精品天堂一级| 7777精品伊人久久久大香线蕉的| 国内久久精品视频| 亚洲成年人影院| 国产精品日韩精品欧美在线| 欧美一区二区视频在线观看2020 | **网站欧美大片在线观看| 欧美精品在欧美一区二区少妇| 国产一本一道久久香蕉| 亚洲午夜激情av| 国产精品色眯眯| 日韩一级大片在线观看| 色综合天天综合色综合av| 经典三级视频一区| 性做久久久久久久免费看| 国产精品久久久久久久浪潮网站| 日韩欧美国产高清| 在线免费观看一区| 99麻豆久久久国产精品免费 | www国产精品av| 欧美四级电影在线观看| 成a人片国产精品| 国产精品资源在线观看| 免费成人在线视频观看| 亚洲成人自拍一区| 亚洲乱码中文字幕综合| 欧美激情中文不卡| 日韩免费看网站| 日韩一区二区精品在线观看| 欧美丝袜丝交足nylons| 日本道精品一区二区三区| 不卡视频免费播放| 风间由美中文字幕在线看视频国产欧美| 麻豆久久久久久久| 日韩精品成人一区二区在线| 亚洲国产日产av| 亚洲综合丁香婷婷六月香| 亚洲欧美一区二区三区国产精品| 国产精品日产欧美久久久久| 国产精品国产三级国产a| 国产色产综合产在线视频| 国产性做久久久久久| 国产欧美综合色| 国产精品国产三级国产普通话三级| 久久综合色一综合色88| 国产日韩欧美不卡| 中文字幕免费不卡| 中文字幕一区av| 亚洲日本成人在线观看| 亚洲激情校园春色| 一区二区三区不卡视频| 亚洲gay无套男同| 亚洲国产精品视频| 日本不卡视频在线| 精品一区二区久久| 成人黄色av电影| 日本高清免费不卡视频| 欧美日韩国产电影| 日韩欧美一区中文| 久久久亚洲精华液精华液精华液| 国产亚洲欧美中文| 亚洲精品视频在线观看免费| 天堂午夜影视日韩欧美一区二区| 蓝色福利精品导航| 成人性色生活片免费看爆迷你毛片| 92国产精品观看| 欧美一区二区三区白人| 国产三级欧美三级日产三级99 | 久久精品国产在热久久| 国产精品一区免费视频| 一本到不卡免费一区二区| 正在播放一区二区| 久久久精品天堂| 夜夜嗨av一区二区三区网页 | 色域天天综合网| 日韩一区二区三区电影在线观看| 中文字幕免费一区| 偷窥少妇高潮呻吟av久久免费| 国产在线不卡视频| 欧美午夜不卡在线观看免费| 久久你懂得1024| 亚洲777理论| av高清不卡在线| 欧美mv日韩mv国产网站| 亚洲欧美国产三级| 精品一区二区三区不卡| 在线观看网站黄不卡| 国产蜜臀97一区二区三区| 丝瓜av网站精品一区二区| 成人av免费在线播放| 日韩一区二区三| 亚洲综合一区二区| 成人午夜av在线| 欧美刺激脚交jootjob| 伊人开心综合网| 波多野结衣视频一区| 欧美大片在线观看一区| 午夜精品成人在线视频| 99精品欧美一区二区三区综合在线| 欧美成人精品高清在线播放| 亚洲一区二区美女| 99国产欧美另类久久久精品| 国产三级精品视频| 久久av资源网| 91精品国产色综合久久久蜜香臀| 午夜精品在线看| 国产精品影视在线观看| 欧美一区二区播放| 亚洲精品成人精品456| 国产a级毛片一区| 欧美精品一区在线观看| 亚洲国产精品一区二区www在线| 99久久综合99久久综合网站| 国产日韩欧美a| 国产精品一区一区三区| 精品久久久久久久久久久久包黑料| 视频在线在亚洲| 欧美三级乱人伦电影| 亚洲一区二区三区自拍| 91久久一区二区| 亚洲一区二区欧美| 欧美日韩一级二级| 婷婷成人综合网| 91精品国产欧美一区二区成人| 亚洲一区二区精品久久av| 欧美性欧美巨大黑白大战| 亚洲影院久久精品| 欧美日韩色一区| 蜜桃av一区二区三区| 日韩欧美国产不卡|