예제 #1
0
 public void ScrollUpTo(Func <AppQuery, AppQuery> toQuery, Func <AppQuery, AppQuery> withinQuery = null,
                        ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67,
                        int swipeSpeed          = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     ScrollTo(WinQuery.FromQuery(toQuery), withinQuery == null ? null : WinQuery.FromQuery(withinQuery), timeout,
              down: false);
 }
예제 #2
0
 private void ScrollTo(
     Func <IAppQuery, IAppQuery> toQuery,
     ScrollStrategy strategy = ScrollStrategy.Auto,
     double swipePercentage  = 0.67,
     int swipeSpeed          = 500,
     bool withInertia        = true,
     TimeSpan?timeout        = null)
 => PerformActions(a => a.MoveToElement(GetSingleElement(toQuery)));
예제 #3
0
 public static void ScrollUpIntoView(this IApp app, string marked, string markedWithin = null,
                                     ScrollStrategy strategy = ScrollStrategy.Auto,
                                     double swipePercentage  = 0.67,
                                     int swipeSpeed          = 500,
                                     bool withInertia        = true)
 {
     ScrollUpIntoView(app, x => x.Marked(marked), markedWithin == null ? (Func <AppQuery, AppQuery>)null : x => x.Marked(markedWithin), strategy, swipePercentage, swipeSpeed, withInertia);
 }
예제 #4
0
        public void ScrollUp(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto,
                             double swipePercentage = 0.67, int swipeSpeed = 500,
                             bool withInertia       = true)
        {
            WinQuery winQuery = WinQuery.FromMarked(withinMarked);

            Scroll(winQuery, false);
        }
예제 #5
0
 void IApp.ScrollUpTo(string toMarked, string withinMarked, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia, TimeSpan?timeout)
 => ScrollTo(
     toQuery: q => q.Marked(toMarked),
     strategy: strategy,
     swipePercentage: swipePercentage,
     swipeSpeed: swipeSpeed,
     withInertia: withInertia,
     timeout: timeout
     );
예제 #6
0
 void IApp.ScrollUp(Func <IAppQuery, IAppQuery> query, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia)
 {
     if (query != null)
     {
         var element = GetSingleElement(query);
         _driver.ExecuteScript("arguments[0].scrollBy(0, -250)", element);
     }
     else
     {
         _driver.ExecuteScript("window.scrollBy(0, -250)");
     }
 }
예제 #7
0
        public void ScrollUp(Func <AppQuery, AppQuery> query = null, ScrollStrategy strategy = ScrollStrategy.Auto,
                             double swipePercentage          = 0.67, int swipeSpeed = 500,
                             bool withInertia = true)
        {
            if (query == null)
            {
                Scroll(null, false);
                return;
            }

            WinQuery winQuery = WinQuery.FromQuery(query);

            Scroll(winQuery, false);
        }
예제 #8
0
        public static void ScrollUpIntoView(this IApp app, Func <AppQuery, AppQuery> query, Func <AppQuery, AppQuery> withinQuery = null,
                                            ScrollStrategy strategy = ScrollStrategy.Auto,
                                            double swipePercentage  = 0.67,
                                            int swipeSpeed          = 500,
                                            bool withInertia        = true
                                            )
        {
            int loop = 0;

            while (!app.Exists(query))
            {
                app.ScrollUp(withinQuery, strategy, swipePercentage, swipeSpeed, withInertia);
                loop++;
                if (loop > 3)
                {
                    break;
                }
            }
        }
예제 #9
0
 public void ScrollDown(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67,
                        int swipeSpeed = 500, bool withInertia = true)
 {
     throw new NotImplementedException();
 }
예제 #10
0
 public void ScrollUp(Func <AppQuery, AppQuery> query = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500,
                      bool withInertia = true)
 {
     throw new NotImplementedException();
 }
예제 #11
0
 public void ScrollUpTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = default(TimeSpan?))
 {
 }
예제 #12
0
 public void ScrollUpTo(Func <AppQuery, AppWebQuery> toQuery, Func <AppQuery, AppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = default(TimeSpan?))
 {
 }
예제 #13
0
 public void ScrollUp(Func <AppQuery, AppQuery> query = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true)
 {
 }
예제 #14
0
 public void ScrollUp(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true)
 {
 }
예제 #15
0
 void IApp.ScrollUp(string withinMarked, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia)
 => ((IApp)this).ScrollUp(q => q.Marked(withinMarked), strategy, swipePercentage, swipeSpeed, withInertia);
예제 #16
0
 void IApp.ScrollUp(Func <IAppQuery, IAppQuery> query, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia) => throw new NotSupportedException();
 public void ScrollDown(Func <AppQuery, AppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67,
                        int swipeSpeed = 500, bool withInertia = true)
 {
     _app.ScrollDown(withinQuery, strategy, swipePercentage, swipeSpeed, withInertia);
 }
 public void ScrollDownTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto,
                          double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     _app.ScrollDownTo(toMarked, withinMarked, strategy, swipePercentage, swipeSpeed, withInertia, timeout);
 }
예제 #19
0
 void IApp.ScrollUpTo(string toMarked, string withinMarked, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia, TimeSpan?timeout) => throw new NotSupportedException();
예제 #20
0
 void IApp.ScrollDown(string withinMarked, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia) => throw new NotSupportedException();
예제 #21
0
 void IApp.ScrollUpTo(Func <IAppQuery, IAppQuery> toQuery, Func <IAppQuery, IAppQuery> withinQuery, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia, TimeSpan?timeout)
 => ScrollTo(
     toQuery: toQuery,
     strategy: strategy,
     swipePercentage: swipePercentage,
     swipeSpeed: swipeSpeed,
     withInertia: withInertia,
     timeout: timeout
     );
예제 #22
0
 public void ScrollDownTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto,
                          double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     throw new NotImplementedException();
 }
예제 #23
0
 public static global::Xamarin.UITest.ScrollStrategy ToXamarinScrollStrategy(this ScrollStrategy strategy)
 => (global::Xamarin.UITest.ScrollStrategy)(int) strategy;
예제 #24
0
 public void ScrollDownTo(Func <AppQuery, AppWebQuery> toQuery, Func <AppQuery, AppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67,
                          int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     throw new NotImplementedException();
 }
예제 #25
0
 void IApp.ScrollDownTo(Func <IAppQuery, IAppWebQuery> toQuery, Func <IAppQuery, IAppQuery> withinQuery, ScrollStrategy strategy, double swipePercentage, int swipeSpeed, bool withInertia, TimeSpan?timeout)
 => throw new NotSupportedException();
 public void ScrollDown(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500,
                        bool withInertia = true)
 {
     _app.ScrollDown(withinMarked, strategy, swipePercentage, swipeSpeed, withInertia);
 }
예제 #27
0
 public void ScrollUpTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto,
                        double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     ScrollTo(WinQuery.FromMarked(toMarked), withinMarked == null ? null : WinQuery.FromMarked(withinMarked), timeout,
              down: false);
 }
 public void ScrollDownTo(Func <AppQuery, AppWebQuery> toQuery, Func <AppQuery, AppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67,
                          int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = null)
 {
     _app.ScrollDownTo(toQuery, withinQuery, strategy, swipePercentage, swipeSpeed, withInertia, timeout);
 }
예제 #29
0
 public void ScrollDownTo(string keyToTap, string keyToScroll, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan?timeout = default(TimeSpan?))
 {
     _app.ScrollDownTo(getQueryFromKey(keyToTap), getQueryFromKey(keyToScroll), strategy, swipePercentage, swipeSpeed, withInertia, timeout);
 }