コード例 #1
0
ファイル: RowNode.cs プロジェクト: dinatale2/Datalist
        public RowNode(ListWnd parent)
        {
            m_Parent = parent;
            m_Row    = m_Parent.GetNewRow();

            m_PreviousNode = null;
            m_NextNode     = null;
        }
コード例 #2
0
ファイル: RowNode.cs プロジェクト: dinatale2/Datalist
        public RowNode(ListWnd parent, Row r)
        {
            m_Parent         = parent;
            m_Row            = r;
            m_Row.ParentNode = this;

            m_PreviousNode = null;
            m_NextNode     = null;
        }
コード例 #3
0
ファイル: ColumnComboBox.cs プロジェクト: dinatale2/Datalist
        protected override void Dispose(bool bDisposing)
        {
            if (bDisposing)
            {
                this.Items.Clear();
                m_ParentList.Controls.Remove(this);
                m_ParentList = null;
            }

            base.Dispose(bDisposing);
        }
コード例 #4
0
        internal Row(ListWnd parent)
        {
            m_Cells  = new CellCollection(this);
            m_Parent = parent;

            m_Height = 2 * m_Parent.CellPadding + m_Parent.Font.Height;

            for (int i = 0; i < m_Parent.Columns.Count; i++)
            {
                Cell JustAdded = m_Cells.Add(this, i);
            }
        }
コード例 #5
0
ファイル: ColumnHeader.cs プロジェクト: dinatale2/Datalist
        internal ColumnHeader(ListWnd ParentWnd)
        {
            m_Parent                  = ParentWnd;
            m_Columns                 = new ColumnCollection(ParentWnd);
            m_Columns.ColumnAdded    += new ColumnCollectionChanged(OnColumnAdded);
            m_Columns.ColumnRemoving += new ColumnCollectionChanged(OnColumnRemoving);
            m_Columns.ColumnRemoved  += new ColumnCollectionColumnChanged(OnColumnRemoved);

            m_bVisible           = false;
            m_bMouseDownInHeader = false;

            ColumnsDiag = new ThresholdDiag("ColumnHeader.OnPaint", null, 100.0);
        }
コード例 #6
0
ファイル: ColumnComboBox.cs プロジェクト: dinatale2/Datalist
        internal ColumnComboBox(ListWnd parent, string strComboSource)
        {
            m_ParentList = parent;
            m_ParentList.Controls.Add(this);
            m_IDtoComboValue = new Dictionary <long, ComboValue>();
            SetComboSource(strComboSource);
            this.DropDownStyle  = ComboBoxStyle.DropDownList;
            this.Visible        = false;
            this.DroppedDown    = false;
            m_bCancelOnDblClick = false;

            m_PendEdit          = new Timer();
            m_PendEdit.Interval = SystemInformation.DoubleClickTime;
            m_PendEdit.Tick    += new EventHandler(OnPendTimerTick);
        }
コード例 #7
0
ファイル: DropDownWnd.cs プロジェクト: dinatale2/Datalist
        internal DropDownWnd(DataList parent, ListWnd control)
        {
            m_Parent = parent;
            m_List   = control;

            m_host      = new ToolStripControlHost(control);
            m_host.Font = m_Parent.Font;

            Padding  = new Padding(0);
            Margin   = new Padding(0);
            AutoSize = true;

            this.DropShadowEnabled = false;
            this.Items.Add(m_host);
        }
コード例 #8
0
        protected override void Dispose(bool disposing)
        {
            if (!m_bDisposed)
            {
                if (disposing)
                {
                    m_ToolTipWnd.DestroyHandle();

                    m_ShowTimer.Dispose();
                    m_Parent     = null;
                    m_ParentCell = null;

                    m_bDisposed = true;
                }
            }

            base.Dispose(disposing);
        }
コード例 #9
0
        public CellToolTip(ListWnd parent)
        {
            m_Parent = parent;

            m_bDisposed  = false;
            m_ToolTipWnd = new ToolTipNativeWindow(this);

            m_Visible = false;

            m_ShowTimer = new Timer();
            m_ShowTimer.Stop();
            m_ShowTimer.Interval = SystemInformation.DoubleClickTime + 200;

            CreateToolTipWnd();

            m_ShowTimer.Tick += new EventHandler(m_ShowTimer_Tick);

            m_bTrackingMouseLeave = false;
        }
コード例 #10
0
ファイル: DataList.cs プロジェクト: dinatale2/Datalist
        public DataList()
        {
            SetStyle(
                ControlStyles.AllPaintingInWmPaint |
                ControlStyles.OptimizedDoubleBuffer |
                ControlStyles.UserPaint |
                ControlStyles.Selectable |
                ControlStyles.UserMouse,
                true);

            m_nStateId      = (int)ComboBoxState.Normal;
            m_nComboStateId = (int)ComboBoxState.Normal;
            m_bReadOnly     = false;

            m_bMouseDownInButton = false;
            m_nDropDownMaxHeight = 300;
            m_nDropDownWidth     = -1;
            m_strComboText       = "";

            m_ThemeManager = new MultiWindowUxThemeManager(this);

            m_ShowNull           = false;
            m_ShowGridLines      = true;
            m_bAllowEdit         = true;
            m_bIsComboBox        = false;
            m_bComboClosedButton = false;
            m_rButtonArea        = Rectangle.Empty;
            m_AllowRowColorCombo = false;

            m_RowWnd      = new ListWnd(this);
            m_RowWnd.Size = this.ClientRectangle.Size;
            this.Controls.Add(m_RowWnd);

            m_RowWnd.CellEditFinishing += new DataListCellEditFinishing(FireCellEditFinishing);
            m_RowWnd.CellEditStarting  += new DataListCellEditStarting(FireCellEditStarting);
            m_RowWnd.RowSelectionMade  += new DataListRowSelected(FireRowSelected);
            m_RowWnd.RowDoubleClicked  += new DataListRowClicked(FireRowDoubleClicked);
            m_RowWnd.RowClicked        += new DataListRowClicked(FireRowClicked);
            m_RowWnd.CellEditFinished  += new DataListCellEditFinished(FireCellEditFinished);
            m_RowWnd.CellEditStarted   += new DataListCellEditStarted(FireCellEditStarted);
            m_RowWnd.CellEditFailed    += new DataListCellEditFailed(FireCellEditFailed);
        }
コード例 #11
0
        internal CellTextBox(ListWnd parent)
        {
            m_Parent         = parent;
            base.BorderStyle = BorderStyle.FixedSingle;
            base.Multiline   = true;
            base.WordWrap    = true;

            // this is how to set margins, but you can only do it for the first time... may have to set up the datalist to destroy and recreate the handle each time
            //Win32.SendMessage(this.Handle, (uint)WindowsMessages.EM_SETMARGINS, 0x1 | 0x2, new IntPtr((m_Parent.CellPadding << 16) + m_Parent.CellPadding));

            m_CurrentRow = null;
            m_CurrentCol = -1;

            m_PendEdit          = new Timer();
            m_PendEdit.Interval = SystemInformation.DoubleClickTime;
            m_PendEdit.Tick    += new EventHandler(OnPendTimerTick);

            m_bCancelOnDblClick = false;
            //m_bNumericOnly = false;
            m_bCtrlDown = false;
        }
コード例 #12
0
 internal ColumnCollection(ListWnd parent)
     : base()
 {
     m_Parent = parent;
 }
コード例 #13
0
 internal RowColorManager(ListWnd Parent) : base()
 {
     m_Parent = Parent;
 }
コード例 #14
0
 internal CellColorManager(ListWnd Parent)
 {
     m_Parent = Parent;
 }
コード例 #15
0
ファイル: RowCollection.cs プロジェクト: dinatale2/Datalist
 internal RowCollection(ListWnd parent)
 {
     m_Parent          = parent;
     m_nCount          = 0;
     m_nTotalRowHeight = 0;
 }