Ejemplo n.º 1
0
        public void DoubleClick(ICoordinates where)
        {
            var MRes = new ManualResetEventSlim(true);

            MRes.Reset();
            Exception exception = null;

            Task.Run(async() =>
            {
                try
                {
                    await mouse.DoubleClick(where).ConfigureAwait(false);
                }
                catch (Exception ex)
                {
                    exception = ex;
                }

                MRes.Set();
            }

                     );
            MRes.Wait();
            if (exception != null)
            {
                throw exception;
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Performs a DoubleClick event on the specified element via ILocatable interface.
        /// </summary>
        /// <param name="elementName">Element to operate on.</param>
        public void MouseDoubleClick(IWebElement element)
        {
            WaitForElementToBePresent(element);
            ILocatable locatable = (ILocatable)element;

            mouse.DoubleClick(locatable.Coordinates);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Double-clicks at the last coordinates set for the driver.
        /// </summary>
        /// <returns>This command always returns <see langword="null"/>.</returns>
        public override object Execute()
        {
            IHasInputDevices hasInputDevicesDriver = this.Session.Driver as IHasInputDevices;
            IMouse           mouse = hasInputDevicesDriver.Mouse;

            mouse.DoubleClick(null);
            return(null);
        }
Ejemplo n.º 4
0
        public void DoubleClick(ICoordinates where)
        {
            Location location = Location_(where);

            Logger.Verbose("DoubleClick({0})", location);

            MoveIfNeeded(where);
            AddMouseTrigger_(MouseAction.DoubleClick);

            Logger.Verbose("DoubleClick(): Location is {0}", mouseLocation_);
            mouse_.DoubleClick(where);
        }
Ejemplo n.º 5
0
        /// <summary>
        /// Performs a DoubleClick event on the specified element via ILocatable interface.
        /// </summary>
        /// <param name="elementName">Element to operate on.</param>
        public void MouseDoubleClick(IWebElement element)
        {
            ILocatable locatable = (ILocatable)element;

            mouse.DoubleClick(locatable.Coordinates);
        }