Exemplo n.º 1
0
 public override void Update(GameTime time, MouseState mouse, Vector2 position)
 {
     if (IsIn(position, mouse))
     {
         if (previousState == ControlMS.None)
         {
             MouseEnter?.Invoke(this, mouse);
             State = ControlMS.Hot;
         }
         else if ((mouse.LeftButton == ButtonState.Pressed || mouse.RightButton == ButtonState.Pressed) && previousState != ControlMS.Pressed)
         {
             MouseDown?.Invoke(this, mouse);
             State = ControlMS.Pressed;
         }
         else if (mouse.LeftButton == ButtonState.Released && mouse.RightButton == ButtonState.Released && previousState == ControlMS.Pressed)
         {
             MouseUp?.Invoke(this, mouse);
             State = ControlMS.Hot;
         }
     }
     else
     {
         if (previousState != ControlMS.None)
         {
             MouseLeave?.Invoke(this, mouse);
             State = ControlMS.None;
         }
     }
     previousState = State;
 }
Exemplo n.º 2
0
        // this handler is called at each mouse Enter/Leave movement
        private void _mouseEnterLeave(object sender, System.EventArgs e)
        {
            Rectangle cr = RectangleToScreen(ClientRectangle);
            Point     mp = MousePosition;

            // actual state
            bool isOver = cr.Contains(mp);

            // test if status changed
            if (_mouseOver ^ isOver)
            {
                // update state
                _mouseOver = isOver;
                if (_mouseOver)
                {
                    MouseEnter?.Invoke(this, EventArgs.Empty);
                }
                else
                {
                    MouseLeave?.Invoke(this, EventArgs.Empty);
                }
            }

            // update UpDownButtons visibility
            if (_showUpDownButtons != ShowUpDownButtonsMode.Always)
            {
                UpdateUpDownButtonsVisibility();
            }
        }
Exemplo n.º 3
0
        public void UpdateControl(float dt)
        {
            var mouseState = Microsoft.Xna.Framework.Input.Mouse.GetState();

            if (Rectangle.Contains(mouseState.Position))
            {
                if (isHoverd == false)
                {
                    MouseEnter?.Invoke(this, EventArgs.Empty);
                }
                isHoverd = true;
                if (mouseState.LeftButton == Microsoft.Xna.Framework.Input.ButtonState.Pressed)
                {
                    isClicked = true;
                }
                else if (mouseState.LeftButton == Microsoft.Xna.Framework.Input.ButtonState.Released && isClicked)
                {
                    isClicked = false;
                    MouseClick?.Invoke(this, EventArgs.Empty);
                }
            }
            else
            {
                if (isHoverd)
                {
                    MouseLeave?.Invoke(this, EventArgs.Empty);
                }
                isHoverd = false;
            }
        }
Exemplo n.º 4
0
        public FileViewerInternal()
        {
            InitializeComponent();
            InitializeComplete();

            _currentViewPositionCache = new CurrentViewPositionCache(this);

            TextEditor.TextChanged += (s, e) => TextChanged?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.VScrollBar.ValueChanged += (s, e) => ScrollPosChanged?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.KeyUp          += (s, e) => KeyUp?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.DoubleClick    += (s, e) => DoubleClick?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseMove      += (s, e) => MouseMove?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseEnter     += (s, e) => MouseEnter?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseLeave     += (s, e) => MouseLeave?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseDown      += (s, e) =>
            {
                SelectedLineChanged?.Invoke(
                    this,
                    new SelectedLineEventArgs(
                        TextEditor.ActiveTextAreaControl.TextArea.TextView.GetLogicalLine(e.Y)));
            };

            HighlightingManager.Manager.DefaultHighlighting.SetColorFor("LineNumbers", new HighlightColor(Color.FromArgb(80, 0, 0, 0), Color.White, false, false));
            TextEditor.ActiveTextAreaControl.TextEditorProperties.EnableFolding = false;

            _lineNumbersControl = new DiffViewerLineNumberControl(TextEditor.ActiveTextAreaControl.TextArea);

            VRulerPosition = AppSettings.DiffVerticalRulerPosition;
        }
Exemplo n.º 5
0
        public override void Update(GameTime gameTime, Input input)
        {
            base.Update(gameTime, input);
            Content?.Update(gameTime, input);
            var currentMouseStatus       = input.MouseStatus;
            var containsCurrentPosition  = Bounds.Contains(currentMouseStatus.Position);
            var containsPreviousPosition = Bounds.Contains(_previousMouseStatus.Position);

            if (containsCurrentPosition && !containsPreviousPosition)
            {
                MouseEnter?.Invoke();
            }
            else if (!containsCurrentPosition && containsPreviousPosition)
            {
                MouseLeave?.Invoke();
            }
            else if (containsCurrentPosition)
            {
                MouseHover?.Invoke();
            }

            if (containsCurrentPosition && currentMouseStatus.IsButtonJustPressed(MouseButtons.Left))
            {
                Click?.Invoke();
            }
        }
Exemplo n.º 6
0
 /// <summary>
 /// マウスがでた時の処理です
 /// </summary>
 /// <param name="mouseEvent"></param>
 protected void OnMouseLeave(MouseEvent mouseEvent)
 {
     if (MouseLeave != null)
     {
         MouseLeave.Invoke(this, mouseEvent);
     }
 }
Exemplo n.º 7
0
 internal void OnMouseLeave(EventArgs e)
 {
     if (MouseLeave != null)
     {
         MouseLeave.Invoke(this, e);
     }
 }
Exemplo n.º 8
0
        private void Viewport_MouseMove(Ray3 ray, System.Windows.Forms.MouseEventArgs e)
        {
            if (SurfaceMesh == null)
            {
                return;
            }

            List <Intersection> Intersections = new List <Intersection>();

            Intersections.AddRange(SurfaceMesh.Intersect(ray));

            if (Intersections.Count == 0 && IsMouseOver)
            {
                IsMouseOver = false;
                MouseLeave?.Invoke(this, e);
            }
            else if (Intersections.Count > 0)
            {
                Intersections.Sort((i1, i2) => i1.Distance.CompareTo(i2.Distance));

                if (!IsMouseOver)
                {
                    IsMouseOver = true;
                    MouseEnter?.Invoke(this, Intersections, e);
                }

                MouseMove?.Invoke(this, Intersections, e);
            }
        }
Exemplo n.º 9
0
        public void Recycle()
        {
            _needVisualiseFlag = false;

            if (Visual == null)
            {
                return;
            }

            if (IsMouseHover)
            {
                MouseLeave?.Invoke();
                IsMouseHover       = false;
                _needVisualiseFlag = false;
                Layer.MouseHoverFragments.Remove(this);
            }

            Layer.RemoveVisual(Visual);
            Layer.VisibleFragments.Remove(this);

            Visual.SetDataContext(null);

            VisualPool.Recycle(Visual);

            Visual = null;
        }
Exemplo n.º 10
0
		public virtual void onMouseLeave(object sender, MouseMoveEventArgs e)
		{
			#if DEBUG_FOCUS
			Debug.WriteLine("MouseLeave => " + this.ToString());
			#endif
			MouseLeave.Raise (this, e);
		}
Exemplo n.º 11
0
        /// <summary>
        /// Handles most events of the control
        /// </summary>
        /// <param name="eventName">Type of event to raise</param>
        /// <remarks></remarks>
        public void DoEvent(LightweightEvents eventName)
        {
            switch (eventName)
            {
            case LightweightEvents.Click:
                DoClick();
                break;

            case LightweightEvents.MouseDown:
                if (canClick)
                {
                    isPressed = true;
                    Redraw();
                }
                MouseDown?.Invoke(this, new MouseEventArgs(MouseButtons.Left, 1, 0, 0, 0));

                break;

            case LightweightEvents.MouseUp:
                if (canClick)
                {
                    isPressed = false;
                    Redraw();
                }
                MouseUp?.Invoke(this, new MouseEventArgs(MouseButtons.Left, 1, 0, 0, 0));

                break;

            case LightweightEvents.MouseEnter:
                Scrolling = true;
                MouseEnter?.Invoke(this, new EventArgs());

                break;

            case LightweightEvents.MouseLeave:
                Scrolling = false;
                MouseLeave?.Invoke(this, new EventArgs());

                break;

            case LightweightEvents.Update:
                Update?.Invoke(this, null);

                break;

            case LightweightEvents.DoubleClick:
                DoubleClick?.Invoke(this, new EventArgs());

                break;

            case LightweightEvents.MouseMove:
                MouseMove?.Invoke(this, new MouseEventArgs(MouseButtons.Left, 1, 0, 0, 0));

                break;

            default:
                throw new NotImplementedException("The requested event for this control does not exist");
            }
        }
Exemplo n.º 12
0
        private static void ProcessWindowEvent(SdlEvent evt)
        {
            // Window Focus
            if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventFocusGained)
            {
                Engine.Active = true;

                if (!OsxUseSpaces)
                {
                    SDL_SetWindowFullscreen(
                        _window,
                        Engine.Fullscreen ?
                        (uint)SdlWindowFlags.SdlWindowFullscreenDesktop :
                        0
                        );
                }

                // Disable the screensaver when we're back.
                SDL_DisableScreenSaver();
            }
            else if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventFocusLost)
            {
                Engine.Active = false;

                if (!OsxUseSpaces)
                {
                    SDL_SetWindowFullscreen(_window, 0);
                }

                SDL_EnableScreenSaver();
            }

            // Window Resize
            else if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventSizeChanged)
            {
                var w = evt.window.data1;
                var h = evt.window.data2;
                _displayW = w;
                _displayH = h;

                Engine.HandleWindowResize();
            }

            else if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventExposed)
            {
                Engine.RunningGame.Tick();
            }

            else if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventEnter)
            {
                SDL_DisableScreenSaver();
                MouseEnter?.Invoke();
            }
            else if (evt.window.windowEvent == SdlWindowEventId.SdlWindoweventLeave)
            {
                SDL_EnableScreenSaver();
                MouseLeave?.Invoke();
            }
        }
Exemplo n.º 13
0
        protected virtual void OnLeave(MouseMoveActionInfo info)
        {
            State = ControlState.Normal;

            if (MouseLeave != null)
            {
                MouseLeave.Invoke(this, info);
            }
        }
Exemplo n.º 14
0
        protected virtual bool OnMouseLeave()
        {
            IsMouseOver = false;

            var args = new HandledEventArgs();

            MouseLeave?.Invoke(args);
            return(args.Handled);
        }
Exemplo n.º 15
0
 public virtual void OnMouseLeave(DxWindow window, DxControl ctl, MouseEventArgs args, Point pt)
 {
     if (!IsMouseOver)
     {
         return;
     }
     IsMouseOver = false;
     IsMouseDown = false;
     MouseLeave?.Invoke(ctl, args, pt);
 }
Exemplo n.º 16
0
        private void Gc_MouseLeave(object sender, EventArgs e)
        {
            if (EnsureCurrent)
            {
                glControl.MakeCurrent();
            }
            Point relcurpos = FindCursorFormCoords();
            var   ev        = new GLMouseEventArgs(relcurpos);

            MouseLeave?.Invoke(this, ev);
        }
Exemplo n.º 17
0
 private void OnDelayMouseLeaveEventTimerTick(object sender, EventArgs e)
 {
     if (_notifyIconMousePosition != Control.MousePosition)
     {
         if (MouseLeave != null)
         {
             MouseLeave.Invoke();
         }
         _delayMouseLeaveEventTimer.Stop();
     }
 }
Exemplo n.º 18
0
        protected virtual void OnMouseLeave(GLMouseEventArgs e)
        {
            //System.Diagnostics.Debug.WriteLine("leave " + Name + " " + e.Location);
            MouseLeave?.Invoke(this, e);

            if (InvalidateOnEnterLeave)
            {
                //System.Diagnostics.Debug.WriteLine($"Invalid on enter {Name}");
                Invalidate();
            }
        }
        /// <summary>
        /// Desenha o controle de acordo com as coordenadas.
        /// </summary>
        public void Draw()
        {
            if (!Visible)
            {
                return;
            }

            State = 0;

            if (Enabled)
            {
                if (InsideButton())
                {
                    if (!move)
                    {
                        move = true;
                        MouseMove?.Invoke(this, EventArgs.Empty);
                    }

                    State = 1;

                    if (EngineCore.MouseDown)
                    {
                        State = 2;

                        if (!click)
                        {
                            MouseDown?.Invoke(this, EventArgs.Empty); click = true;
                        }
                    }
                    else
                    {
                        if (click)
                        {
                            MouseUp?.Invoke(this, EventArgs.Empty);
                        }
                        click = false;
                        State = 1;
                    }
                }
                else
                {
                    if (move)
                    {
                        move = false;
                        MouseLeave?.Invoke(this, EventArgs.Empty);
                    }
                }
            }

            EngineCore.SpriteDevice.Begin(SpriteFlags);
            EngineCore.SpriteDevice.Draw(Texture[State], new Color(Color.R, Color.G, Color.B, Transparency), SourceRect, new Vector3(0, 0, 0), new Vector3(Position.X, Position.Y, 0));
            EngineCore.SpriteDevice.End();
        }
Exemplo n.º 20
0
        public virtual void OnMouseLeave()
        {
            if (!_Enabled)
            {
                return;
            }

            if (MouseLeave != null)
            {
                MouseLeave.Invoke(this, EventArgs.Empty);
            }
        }
Exemplo n.º 21
0
 public override void Dispose()
 {
     _aggregator.Unsubscribe(Entity);
     MouseEnter?.Dispose();
     MouseLeave?.Dispose();
     MouseMove?.Dispose();
     MouseClicked?.Dispose();
     MouseDoubleClicked?.Dispose();
     MouseDown?.Dispose();
     MouseUp?.Dispose();
     LostFocus?.Dispose();
     base.Dispose();
 }
Exemplo n.º 22
0
        private async Task onRepeatedlyExecute(object sender, EventArgs args)
        {
            if (!_enabled.Enabled || !_visible.Visible)
            {
                return;
            }
            IRoom room = _state.Room;

            if (room == null)
            {
                return;
            }

            PointF position = _input.MousePosition;

            var  obj     = room.GetObjectAt(position.X, position.Y);
            bool mouseIn = obj == _entity;

            bool leftMouseDown  = _input.LeftMouseButtonDown;
            bool rightMouseDown = _input.RightMouseButtonDown;

            bool fireMouseMove  = mouseIn && (_mouseX != position.X || _mouseY != position.Y);
            bool fireMouseEnter = mouseIn && !IsMouseIn;
            bool fireMouseLeave = !mouseIn && IsMouseIn;

            _mouseX   = position.X;
            _mouseY   = position.Y;
            IsMouseIn = mouseIn;

            bool wasLeftMouseDown  = _leftMouseDown;
            bool wasRightMouseDown = _rightMouseDown;

            _leftMouseDown  = leftMouseDown;
            _rightMouseDown = rightMouseDown;

            await handleMouseButton(_leftMouseClickTimer, _leftMouseDoubleClickTimer, wasLeftMouseDown, leftMouseDown, MouseButton.Left);
            await handleMouseButton(_rightMouseClickTimer, _rightMouseDoubleClickTimer, wasRightMouseDown, rightMouseDown, MouseButton.Right);

            if (fireMouseEnter)
            {
                await MouseEnter.InvokeAsync(_entity, new MousePositionEventArgs (position.X, position.Y));
            }
            else if (fireMouseLeave)
            {
                await MouseLeave.InvokeAsync(_entity, new MousePositionEventArgs (position.X, position.Y));
            }
            if (fireMouseMove)
            {
                await MouseMove.InvokeAsync(_entity, new MousePositionEventArgs(position.X, position.Y));
            }
        }
Exemplo n.º 23
0
        protected virtual void OnMouseLeave()
        {
            if (!_enabled)
            {
                return;
            }

            Redraw();

            if (MouseLeave != null)
            {
                MouseLeave.Invoke(this, EventArgs.Empty);
            }
        }
Exemplo n.º 24
0
        public FileViewerInternal()
        {
            InitializeComponent();
            InitializeComplete();

            Disposed += (sender, e) =>
            {
                //// _diffHighlightService not disposable
                //// _lineNumbersControl not disposable
                //// _currentViewPositionCache not disposable
                _findAndReplaceForm.Dispose();
            };

            _currentViewPositionCache = new CurrentViewPositionCache(this);
            TextEditor.ActiveTextAreaControl.TextArea.SelectionManager.SelectionChanged += SelectionManagerSelectionChanged;

            TextEditor.ActiveTextAreaControl.TextArea.PreviewKeyDown += (s, e) =>
            {
                if (e.KeyCode == Keys.Escape && !TextEditor.ActiveTextAreaControl.SelectionManager.HasSomethingSelected)
                {
                    EscapePressed?.Invoke();
                }
            };

            TextEditor.TextChanged += (s, e) => TextChanged?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.HScrollBar.ValueChanged += (s, e) => OnHScrollPositionChanged(EventArgs.Empty);
            TextEditor.ActiveTextAreaControl.VScrollBar.ValueChanged += (s, e) => OnVScrollPositionChanged(EventArgs.Empty);
            TextEditor.ActiveTextAreaControl.TextArea.KeyUp          += (s, e) => KeyUp?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.DoubleClick    += (s, e) => DoubleClick?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseMove      += (s, e) => MouseMove?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseEnter     += (s, e) => MouseEnter?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseLeave     += (s, e) => MouseLeave?.Invoke(s, e);
            TextEditor.ActiveTextAreaControl.TextArea.MouseDown      += (s, e) =>
            {
                SelectedLineChanged?.Invoke(
                    this,
                    new SelectedLineEventArgs(
                        TextEditor.ActiveTextAreaControl.TextArea.TextView.GetLogicalLine(e.Y)));
            };
            TextEditor.ActiveTextAreaControl.TextArea.MouseWheel += TextArea_MouseWheel;

            HighlightingManager.Manager.DefaultHighlighting.SetColorFor("LineNumbers",
                                                                        new HighlightColor(SystemColors.ControlText, SystemColors.Control, false, false));
            TextEditor.ActiveTextAreaControl.TextEditorProperties.EnableFolding = false;

            _lineNumbersControl = new DiffViewerLineNumberControl(TextEditor.ActiveTextAreaControl.TextArea);

            VRulerPosition = AppSettings.DiffVerticalRulerPosition;
        }
Exemplo n.º 25
0
        private void OnMouseMove(object s, MouseMove e)
        {
            var intersecting = Intersects(e.X, e.Y);

            if (intersecting && !mousePreviouslyIntersected)
            {
                MouseEnter?.Invoke(s, e);
            }
            else if (!intersecting && mousePreviouslyIntersected)
            {
                MouseLeave?.Invoke(s, e);
            }

            mousePreviouslyIntersected = intersecting;
        }
Exemplo n.º 26
0
        private void OnMouseEnterLeave(object sender, EventArgs e)
        {
            bool isOver = RectangleToScreen(ClientRectangle).Contains(MousePosition);

            if (_mouseOver != isOver)
            {
                _mouseOver = isOver;
                if (_mouseOver)
                {
                    MouseEnter?.Invoke(this, EventArgs.Empty);
                }
                else
                {
                    MouseLeave?.Invoke(this, EventArgs.Empty);
                }
            }
        }
Exemplo n.º 27
0
        public SessionCircle()
        {
            Ellipse = new Ellipse {
                Tag = this
            };
            selectedEllipse = new Ellipse();
            canvas          = new Canvas();
            canvas.Children.Add(Ellipse);
            canvas.Children.Add(selectedEllipse);

            UiElement = canvas;

            canvas.MouseEnter += (sender, e) => MouseOver?.Invoke(this);
            canvas.MouseLeave += (sender, e) => MouseLeave?.Invoke(this);
            canvas.MouseDown  += (sender, e) => MouseDown?.Invoke(this);
            canvas.MouseUp    += (sender, e) => MouseUp?.Invoke(this);
        }
Exemplo n.º 28
0
        private void InitMouseEvents()
        {
            _circle.MouseEnter           += (s, e) => MouseEnter?.Invoke(this, e);
            _circle.MouseLeave           += (s, e) => MouseLeave?.Invoke(this, e);
            _circle.MouseLeftButtonDown  += (s, e) => MouseLeftButtonDown?.Invoke(this, e);
            _circle.MouseLeftButtonUp    += (s, e) => MouseLeftButtonUp?.Invoke(this, e);
            _circle.MouseRightButtonDown += (s, e) => MouseRightButtonDown?.Invoke(this, e);
            _circle.MouseRightButtonUp   += (s, e) => MouseRightButtonUp?.Invoke(this, e);
            _circle.MouseMove            += (s, e) => MouseMove?.Invoke(this, e);

            _label.UILabel.MouseEnter           += (s, e) => MouseEnter?.Invoke(this, e);
            _label.UILabel.MouseLeave           += (s, e) => MouseLeave?.Invoke(this, e);
            _label.UILabel.MouseLeftButtonDown  += (s, e) => MouseLeftButtonDown?.Invoke(this, e);
            _label.UILabel.MouseLeftButtonUp    += (s, e) => MouseLeftButtonUp?.Invoke(this, e);
            _label.UILabel.MouseRightButtonDown += (s, e) => MouseRightButtonDown?.Invoke(this, e);
            _label.UILabel.MouseRightButtonUp   += (s, e) => MouseRightButtonUp?.Invoke(this, e);
            _label.UILabel.MouseMove            += (s, e) => MouseMove?.Invoke(this, e);
        }
Exemplo n.º 29
0
        public virtual void Update(GameTime gameTime)
        {
            var pre  = IsMouseOver;
            var cpos = ComputedPosition;
            var nmp  = MainGame.InputMonitor.MousePosition;

            IsMouseOver = nmp.X >= cpos.X &&
                          nmp.X < cpos.X + Size.X &&
                          nmp.Y >= cpos.Y &&
                          nmp.Y < (cpos.Y + Size.Y);
            if (pre && !IsMouseOver)
            {
                MouseLeave?.Invoke();
                Trigger(UiElementBehaviorTriggers.MouseLeave.I());
            }
            if (!pre && IsMouseOver)
            {
                MouseEnter?.Invoke();
                Trigger(UiElementBehaviorTriggers.MouseEnter.I());
            }
            if (nmp != lastMousePos)
            {
                MouseMove?.Invoke();
                Trigger(UiElementBehaviorTriggers.MouseMove.I());
            }

            var leftMouseDown = MainGame.InputMonitor.IsLeftMouseDown;

            if (IsMouseOver && leftMouseDown && !IsMouseDown)
            {
                IsMouseDown = true;
                MouseDown?.Invoke();
                Trigger(UiElementBehaviorTriggers.MouseDown.I());
            }
            if (IsMouseOver && !leftMouseDown && IsMouseDown)
            {
                IsMouseDown = false;
                MouseUp?.Invoke();
                Trigger(UiElementBehaviorTriggers.MouseUp.I());
            }

            lastMousePos = nmp;
        }
Exemplo n.º 30
0
        public void MouseButtons()
        {
            if (Enabled)
            {
                if (InsideButton())
                {
                    if (!move)
                    {
                        move = true;
                        MouseMove?.Invoke(this, EventArgs.Empty);
                    }

                    if (EngineCore.MouseDown)
                    {
                        if (!click)
                        {
                            MouseDown?.Invoke(this, EventArgs.Empty);
                            click = true;
                        }
                    }
                    else
                    {
                        if (click)
                        {
                            MouseUp?.Invoke(this, EventArgs.Empty);
                        }

                        click = false;
                    }
                }
                else
                {
                    if (move)
                    {
                        move = false;
                        MouseLeave?.Invoke(this, EventArgs.Empty);
                    }
                }
            }
        }