From the course: Android Development Essential Training: 2 User Interface Design
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Challenge: Load a network image - Android Tutorial
From the course: Android Development Essential Training: 2 User Interface Design
Challenge: Load a network image
(upbeat music) - [Instructor] Hey folks, challenge time. In this challenge, we're going to be loading an image from the network. Let's take a look at what you'll be building. Your application will have an image view and one switch. This switch will have a label toggle images. There will be no image displayed when the app first loads. However, when the user clicks on the switch, it's going to toggle between two images that are loaded from the network. You'll want to use the sample project provided in the Exercise Files for this challenge as I've already done a bit of the heavy lifting for you. Let's take a look. The first thing I've done is to declare the use of the internet permission in the Android manifest file. We can see that here on line number five. This permission is important because we want to display images that are downloaded from the network. Next, in the app's build.gradle file, I've added a new dependency…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Display image resources5m 10s
-
(Locked)
Load image resources at runtime6m 16s
-
(Locked)
Reduce file size with WebP images4m 26s
-
(Locked)
Use XML-based VectorDrawable images4m 37s
-
(Locked)
Create icons in Android Studio4m 45s
-
(Locked)
Challenge: Load a network image2m 43s
-
(Locked)
Solution: Load a network image1m 48s
-
(Locked)
-
-