// ***********************************************************************
// Assembly : HZH_Controls
// Created : 08-08-2019
//
// ***********************************************************************
//
// Copyright by Huang Zhenghui(黄正辉) All, QQ group:568015492 QQ:623128629 Email:623128629@qq.com
//
//
// Blog: https://www.cnblogs.com/bfyx
// GitHub:https://github.com/kwwwvagaa/NetWinformControl
// gitee:https://gitee.com/kwwwvagaa/net_winform_custom_control.git
//
// If you use this code, please keep this note.
// ***********************************************************************
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace HZH_Controls.Controls
{
///
/// Class UCPagerControlBase.
/// Implements the
/// Implements the
///
///
///
[ToolboxItem(false)]
public class UCPagerControlBase : UserControl, IPageControl
{
#region 构造
///
/// 必需的设计器变量。
///
private System.ComponentModel.IContainer components = null;
///
/// 清理所有正在使用的资源。
///
/// 如果应释放托管资源,为 true;否则为 false。
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region 组件设计器生成的代码
///
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
///
private void InitializeComponent()
{
this.SuspendLayout();
//
// UCPagerControlBase
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.Name = "UCPagerControlBase";
this.Size = new System.Drawing.Size(304, 58);
this.Load += new System.EventHandler(this.UCPagerControlBase_Load);
this.ResumeLayout(false);
}
#endregion
#endregion
private PageModel m_pm = PageModel.Soure;
///
/// 翻页控件模式
///
/// The page model.
public PageModel PageModel
{
get { return m_pm; }
set { m_pm = value; }
}
///
/// 总页数
///
/// The page count.
public virtual int PageCount
{
get;
set;
}
///
/// The m page index
///
private int m_pageIndex = 1;
///
/// 当前页码
///
/// The index of the page.
public virtual int PageIndex
{
get { return m_pageIndex; }
set { m_pageIndex = value; }
}
private List