Source/Controls/ComboBoxEx.cs

(开头部分) 68KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using DevComponents.DotNetBar;
using DevComponents.DotNetBar.Rendering;
using DevComponents.DotNetBar.Controls;
using DevComponents.Editors;
using DevComponents.DotNetBar.TextMarkup;

namespace DevComponents.DotNetBar.Controls
{
	/// <summary>
	/// Represents enhanced Windows combo box control.
	/// </summary>
    [ToolboxBitmap(typeof(ComboBoxEx), "Controls.ComboBoxEx.ico"), ToolboxItem(true), Designer(typeof(Design.ComboBoxExDesigner))]
	public class ComboBoxEx : System.Windows.Forms.ComboBox, ICommandSource
	{
		/// <summary>
		/// Represents the method that will handle the DropDownChange event.
		/// </summary>
		public delegate void OnDropDownChangeEventHandler(object sender, bool Expanded);
		/// <summary>
		/// Occurs when drop down portion of combo box is shown or hidden.
		/// </summary>
		public event OnDropDownChangeEventHandler DropDownChange;

		private eDotNetBarStyle m_Style=eDotNetBarStyle.Office2007;
		private bool m_DefaultStyle=false;			// Disables our drawing in WndProc
		private bool m_MouseOver=false;
        private bool m_MouseOverThumb=false;
		private bool m_DroppedDown=false;
		//private System.Windows.Forms.Timer m_Timer;
		private bool m_WindowsXPAware=false;
		private bool m_DisableInternalDrawing=false;
		private ImageList m_ImageList=null;
		private int m_DropDownHeight=0;
		private IntPtr m_LastFocusWindow;
		private IntPtr m_DropDownHandle=IntPtr.Zero;
		private ComboTextBoxMsgHandler m_TextWindowMsgHandler=null;
        //private ComboListBoxMsgHandler m_ListBoxMsgHandler = null;

		[DllImport("user32")]
		private static extern bool ValidateRect(IntPtr hWnd,ref NativeFunctions.RECT pRect);

		[DllImport("user32",SetLastError=true, CharSet=CharSet.Auto)]
		private static extern IntPtr GetWindow(IntPtr hWnd, uint uCmd);
		private const uint GW_CHILD=5;

		private bool m_PreventEnterBeep=false;

        private string m_WatermarkText = "";
        private bool m_Focused = false;
        private Font m_WatermarkFont = null;
        private Color m_WatermarkColor = SystemColors.GrayText;
        private bool m_IsStandalone = true;
        private Timer m_MouseOverTimer = null;
后面还有 1921 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。