LSQ.DragHelper/Instance.cs
(开头部分) 13KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
using System.Drawing;
using System.Diagnostics;
// 下载于www.51aspx.com
namespace LSQ.DragHelper
{
/// <summary>
/// 拖拽帮助类,控件需要注册该类中的鼠标相关事件
/// </summary>
public class Instance
{
/// <summary>
/// 光标状态
/// </summary>
private enum EnumMousePointPosition
{
无,
左边框拉伸,
左上角拉伸,
上边框拉伸,
右上角拉伸,
右边框拉伸,
右下角拉伸,
下边框拉伸,
左下角拉伸,
拖拽
}
/// <summary>
/// 控件原背景色
/// </summary>
private static Color oldColor = default(Color);
/// <summary>
/// 控件点击时使用的背景色
/// </summary>
private static Color controlFocusedBackcolor = Color.Red;
/// <summary>
/// 鼠标拖拽使用的原始点
/// </summary>
private static Point mouseDragOldPoint = default(Point);
/// <summary>
/// 鼠标上一次改变大小后的位置点
/// </summary>
private static Point mouseSizeLastPoint = default(Point);
/// <summary>
/// 绘制边框的画笔
/// </summary>
private static Pen borderPen = new Pen(Color.Black);
/// <summary>
/// 光标变化临界的宽度
/// </summary>
private const int BAND = 3;
/// <summary>
/// 控件最小宽度
/// </summary>
private const int MINWIDTH = 10;
/// <summary>
后面还有 267 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
