コード例 #1
0
ファイル: Container.cs プロジェクト: LexTheGreat/EclipseSharp
        /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        /// <summary>
        /// Tells the widget that the mouse wheel has moved while the mouse was on top of the widget
        /// </summary>
        ///
        /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        protected internal override void OnMouseWheelMoved(MouseWheelEventArgs e)
        {
            // Adjust the mouse position of the event
            e.X = (int)(e.X - Position.X);
            e.Y = (int)(e.Y - Position.Y);

            // Send the event to the widget under the mouse
            Widget widget = null;

            if (MouseOnWhichWidget(ref widget, e.X, e.Y))
            {
                widget.OnMouseWheelMoved(e);
            }
        }