← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #251433]: dragDrop behavior changed in 1.0.1 (ServiceUpdate 1.0.1) release for Java

 

Question #251433 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/251433

Description changed to:
In my last version of sikuli I was able to drag screen on simulators and
emulators around using the following code:

		Screen s = new Screen();
		// scroll page down to unitl a greyed out video with a lock icon appears
		Pattern SCROLL_LOCKED_VIDEO = new Pattern(Images.SCROLL_LOCKED_VIDEO)
				.similar((float) .93);
		for (int i = 0; i < 20; i++) {
                         
                         //starting from this coordinate align the mouse 60 pixels out from the edge
			s.dragDrop(SCROLL_LOCKED_VIDEO.targetOffset(60, 0),

                            //this is where the mouse would grab from 850 pixels below and drag to 0 pixels
					SCROLL_LOCKED_VIDEO.targetOffset(60, 850));

                        //stop scrolling when this image appears
			if (s.exists("imgsAndroid/LockedVideo.png", 0) != null) {
				break;

                        }

                }

With the latest upgrade of Sikuli jar file this method only moves the
mouse to the first coordinate "60, 850" and does not drag the screen. Is
there an updated way to write this method?

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.