Automate scrolling for an Android navigation app? - android

I've modified an Android navigation app (kind of like Google Maps), and I want to test it. Specifically, I want to do some things like scrolling around and zooming in and out (there are two zoom buttons at the bottom of the window that allow you to zoom). However, I want to do the same test run a few times in a row. For example, scroll all the way from right to left, then wait 10 seconds, then zoom in, then scroll twice all the way from bottom to top, then zoom out after 5 seconds, etc. The problem is that I can't possibly replicate the test run exactly every time due to human error.
Is there some way I can automate the test run? Sort of like a macro that you record on Excel, but with timing as well? Maybe a script of some sort? Basically, I want a way to automate the scrolling, zooming, timing, etc.
Any tips?

Related

Split-Screen in Android App Development

I was wondering if there was a way I can have part of my screen in android constantly display something, even something as simple as a piece of text or an image. I am fairly familiar with Android Development, so if there is a way to make an app that does that, it'd be great.
To be precise, I want the top third of my screen to stay constant, and the bottom two-thirds to work normally such that I can do anything I can normally do
Edit: I want the top third to display the constant text/image even if I exit the app. A widget is a good idea. I'll look more into that.

Altering the global/master UI from a background app in android

Is it possible for an android app to run in the background, listen to specific triggers and modify the visible application content in the screen (in both system and third party apps)?
For an example, A 2 finger tap should lead to a ripple effect on the screen. If the temperature is high, The screen turns more reddish. If I say "do a barrel roll", The entire UI does a "barrel-roll" like the google Easter egg. And this should happen whether the user is in the homescreen, settings or his Instagram.
The best working example I can give is the built-in "Magnification Gesture" provided by Android. Three taps anywhere will zoom everything up except for the keyboard and the navigation bar. And it doesn't zoom as an image, the touch points are preserved.
Is this possible to do without or with root? Do I need a framework like Xposed?
Thanks.

How to add multiple pages in AIR for Android

I want to add multiple pages in my Android App, similar to the home screen on my phone, I want to be able to swipe left and right to see multiple pages.
I'm developing my app in Adobe Flash CC 2014 using "AIR 16.0 for Android".
Anyone know how I can do this?
You can go with different approaches for this problem. You could create some SwipeGestures to detect that or you could go the way Flash went since 1999, setup a Movieclip (or many) and listen for onMouseDown (ontouchstart) events and then say mc.startDrag(); (you want to limit the drag-movement to the X axis). Then onMouseUp (ontouchend) you can determine if the current MC is relativly cented and then tween it into the middle of the screen, or if the page is to far left/right and therefore page to the next page. There is also a Touch Drag implementation out of the box with ontouchmove .
Basicly what you are looking for is some kind of coverflow for AS3 ... or something a lot less fancy. Please make yourself comfortable with startDrag and StopDrag and you will see how you get there my doing.

How do i include touch swipe? Dynamically load cross platform content and decrease page load times

The idea is to build a website which can grant a mobile and desktop user the full experience. 'The full experience' meaning the use of jquery.
The most important thing is accessibility, so I'm wondering if their is a cross platform way to build a slider/carousel which supports text, links and most importantly touch swipes.
To improve speed, I'd much prefer to load the slides seperately. I understand ajax maybe the solution.. but haven't a clue how. Can anyone direct me towards any basic tutorials that cover this?
A follow up question to the last.. Is ajax safe for dynamically loading content onto mobile devices too?
Also in terms of website layout. Most of the layout will change depending on css media rules when the page is resized. But there are a few elements that will need to teleport depending on the size of the screen.
I considered creating separate elements that would be hidden and shown with jquery/css, but not particularly liking the sound of the code being loaded when it's not needed.
This is slightly different to the sliders in the sense that this code needs to be instantly responsive if the screen size changes (for example, a tablet user changing from portrait to landscape.. or a desktop user zooming in.)
I just don't like the sound of code being loaded if it's hidden.. what is best practice for this?
Again the questions are..
How can i go about building a cross-platform slider, that allows text,links and touch swipe (literally have no idea where to start with touch swipes.)
How can I dynamically load content? (with ajax)? Will this work with smartphones too?
Do people load 'layout' code (on page load) that is only visible if certain parameters are met (eg screen-size.) An example being 2 different menus, one for a small screen and one for a large. Or is there a safe way to load layout code only when it is needed, which would reduce page load times (especially for mobile users.)
thanks
3) touch swipes work the same way as a click + drag, so you should be able to use the same code for mobile and desktop. Here is a great example of this: http://scripterlative.com/files/dragdivscroll.htm

Android Gestures to Replace Physical Arrow Keys

I'm starting from scratch and I don't even know where to look.. or even what to call this.. so any help would be appreciated.
I am working with the Snake example that Google supplies and I want it to work on Android devices without physical keys. How would I be able to use touch gestures (up/left/right/down) to make the snake turn and whatnot.
Again, I don't even know where to start looking.. I'm still slowly learning my way through programming for Android.
Thanks!
You could implement View.OnTouchListener. I think this page is the one you're looking for.
I would modify it so that touching the top part of the screen sent the snake up, the left side sent it left, etc.

Categories

Resources