Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member

Adding functionality for mobile

From: Creating Drag-and-Drop Functionality with Edge Animate

Video: Adding functionality for mobile

If you are targeting mobile, of course you need to test out on mobile devices. So, launch your browser and go to touchpunch.furf, F-U-R-F .com.

Adding functionality for mobile

If you are targeting mobile, of course you need to test out on mobile devices. Now, here I have this project posted to paultrani.com that's the URL. And I'm just going to go ahead and play around with this on my iPhone and I'll try to click and drag the eyes. As I do you can see it, it actually just selects the eyes and that's not what I want. So this is not optimized for mobile. I need to convert these mouseovers and mousedowns into touch events. And what I can do in order to make that happen is use something called Touch Punch.

So, launch your browser and go to touchpunch.furf, F-U-R-F .com. And, here, you'll see this actually gives the ability to take jQuery UI and convert into touch-enabled functionality. And, you can see, right down here, it says that it works by mapping the touch events to mouse events. And that is what going on. So I don't have to write these touch events, I could use this small library. I do encourage you to donate. In essence what you want to do is use you want to use this particular file.

This is a jQuery JavaScript file I'm just saving to my Downloads folder. Click Save, there it is. Now I actually want to use this in Edge Animate. Go to my project and right over here in your Library panel under Scripts, just grab add jQuery UI, well I want to make that touch enabled. So, Add JS File from Disk. Locating that particular file that I've just downloaded. Selecting open and now it's added it. So that's what I'm going to do. That's quite frankly half the battle. So if we take a look at the eyes.

Again, it's going to take, you know, some mouse downs, it might not do the mouse over, so it does what it can, but really it's dealing with the jQuery UI functionality. So I could test this out, not quite everything will work. Because this mouseover actually doesn't work. What I want to do, is I actually want to take this code right here and I want to copy it, because I'm going to add a new one, that's called TouchStart. This will give me the ability to drag and drop that item on mobile devices.

So we can do that for the eyes, we can do that for the ears, again the same process taking mouseover, copying it, adding touchstart, pasting it in, just like that. And we will do one more item. This mouth here, mouseover, taking those lines, adding touchstart, pasting it in. So, I've added some touch enabled functionality. And, not only that, I have my touch, punch, added as well, so I can Publish this out, upload it, and then test it on my mobile device again.

Here I am, back on my mobile device, and now if we take those eyes for instance, just with my finger, I can grab and touch it and move it around. The depth looks good, dropping them on the monster body. The ears, grabbing them and then placing them on the head. And lastly, it's going to be that mouth. Grabbing that mouth, placing it right over here. All right, there we have it. And keep in mind, with touch punch, all of my clicks will actually be interpreted as touch events. So if I take a look at this PLAY button, this PLAY button as I click it, you could see the animation takes place.

All right. So far, so good. I'd say, actually, this is pretty much done. I can test it on more devices. But, in general, there's your project complete, working on mobile. And, lastly, don't forget that there's other events that you can do, specific to mobile. Like, swipes that are actually built into Edge Animate.

Show transcript

This video is part of

Image for Creating Drag-and-Drop Functionality with Edge Animate
Creating Drag-and-Drop Functionality with Edge Animate

19 video lessons · 1743 viewers

Paul Trani
Author

 

Start learning today

Get unlimited access to all courses for just $25/month.

Become a member
Sometimes @lynda teaches me how to use a program and sometimes Lynda.com changes my life forever. @JosefShutter
@lynda lynda.com is an absolute life saver when it comes to learning todays software. Definitely recommend it! #higherlearning @Michael_Caraway
@lynda The best thing online! Your database of courses is great! To the mark and very helpful. Thanks! @ru22more
Got to create something yesterday I never thought I could do. #thanks @lynda @Ngventurella
I really do love @lynda as a learning platform. Never stop learning and developing, it’s probably our greatest gift as a species! @soundslikedavid
@lynda just subscribed to lynda.com all I can say its brilliant join now trust me @ButchSamurai
@lynda is an awesome resource. The membership is priceless if you take advantage of it. @diabetic_techie
One of the best decision I made this year. Buy a 1yr subscription to @lynda @cybercaptive
guys lynda.com (@lynda) is the best. So far I’ve learned Java, principles of OO programming, and now learning about MS project @lucasmitchell
Signed back up to @lynda dot com. I’ve missed it!! Proper geeking out right now! #timetolearn #geek @JayGodbold
Share a link to this course

What are exercise files?

Exercise files are the same files the author uses in the course. Save time by downloading the author's files instead of setting up your own files, and learn by following along with the instructor.

Can I take this course without the exercise files?

Yes! If you decide you would like the exercise files later, you can upgrade to a premium account any time.

Become a member Download sample files See plans and pricing

Please wait... please wait ...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ .

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

Join now Already a member? Log in

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed Creating Drag-and-Drop Functionality with Edge Animate.

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member ?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferences from the dropdown menu.

Continue to classic layout Stay on new layout
Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Learn more, save more. Upgrade today!

Get our Annual Premium Membership at our best savings yet.

Upgrade to our Annual Premium Membership today and get even more value from your lynda.com subscription:

“In a way, I feel like you are rooting for me. Like you are really invested in my experience, and want me to get as much out of these courses as possible this is the best place to start on your journey to learning new material.”— Nadine H.

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked
Terms and conditions of use

We've updated our terms and conditions (now called terms of service).Go
Review and accept our updated terms of service.