SlideShare a Scribd company logo
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Agenda
✓ What is Android Studio?
✓ Android Stack
✓ Installation
✓ What is an Activity?
✓ Activity Life Cycle
✓ Event Listeners
✓ Intents
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Event Listeners
Let’s look at various event listeners in an activity
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Event Listeners
 An event listener is an interface in the View class that contains a single callback method.
 These are the tickets to capture the user interaction with your UI.
This is called when the user either touches the item when in touch mode.
 onClick()
This is called when the user navigates onto or away from the item, using the navigation-keys or
trackball.
 onFocusChange()
1
2
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Event Listeners
 onLongClick()
 onKey()
 onTouch()
The user either touches and holds the item when in touch mode. Say it holds the suitable "enter" key
and holds down on the trackball (for one second).
This is called when the user is focused on the item and presses or releases a hardware key on the
device.
This is called when the user performs an action qualified as a touch event, including a press, a
release, or any movement gesture on the screen (within the bounds of the item).
3
4
5
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Intents
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Intents
An intent is a messaging object you can use to request
an action from another app component.
➢ Methods are used to deliver intents to different
components:
• context.startActivity()
• context.startService()
• context.sendBroadcast()
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Intents
 An intent can carry data bundle to perform any activity
 For example if an activity has to launch an email operation, we can use an
intent with ACTION_SEND.
Types of Intent:
Implicit Intent
Explicit Intent
1
2
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Implicit Intent
Implicit intent is when the target component is not defined in the intent and the android
system has to evaluate the registered components based on the intent data.
Intent i = new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.edureka.co"));
startActivity(i);
Action Specification
Copyright © 2017, edureka and/or its affiliates. All rights reserved.
Explicit Intent
Explicit intent is when an application defines the target component directly in the
intent.
Intent i = new Intent(this, ActivityTwo.class);
i.putExtra("Value1", "This is ActivityTwo ");
i.putExtra("Value2", "This value two for ActivityTwo");
startActivity(i);
Target component
Slide 11 Course Url

More Related Content

PDF
React Components Lifecycle | React Tutorial for Beginners | ReactJS Training ...
PDF
Android Studio Tutorial For Beginners | Android Tutorial | Android Training |...
PDF
Docker Compose | Containerizing MEAN Stack Application | DevOps Tutorial | Ed...
PDF
Dockerizing An Angular Application Using Git, Jenkins & Docker! | DevOps Tuto...
PDF
Top 10 Programming Languages | Programming Languages For Beginners | Computer...
PDF
Azure Virtual Network Tutorial | Azure Virtual Machine Tutorial | Azure Train...
PDF
Python Django tutorial | Getting Started With Django | Web Development With D...
PDF
Top 10 Reasons to Learn Microsoft Azure | Azure Certification Training | Edureka
React Components Lifecycle | React Tutorial for Beginners | ReactJS Training ...
Android Studio Tutorial For Beginners | Android Tutorial | Android Training |...
Docker Compose | Containerizing MEAN Stack Application | DevOps Tutorial | Ed...
Dockerizing An Angular Application Using Git, Jenkins & Docker! | DevOps Tuto...
Top 10 Programming Languages | Programming Languages For Beginners | Computer...
Azure Virtual Network Tutorial | Azure Virtual Machine Tutorial | Azure Train...
Python Django tutorial | Getting Started With Django | Web Development With D...
Top 10 Reasons to Learn Microsoft Azure | Azure Certification Training | Edureka

Viewers also liked (20)

PDF
Angular 4 Components | Angular 4 Tutorial For Beginners | Learn Angular 4 | E...
PDF
Bitcoin Blockchain Explained | Understanding Bitcoin and Blockchain | Blockch...
PDF
Angular 4 Tutorial For Beginners | Angular 4 Introduction | Angular 4 Trainin...
PDF
Artificial Neural Network Tutorial | Deep Learning With Neural Networks | Edu...
PDF
Power BI Training | Getting Started with Power BI | Power BI Tutorial | Power...
PDF
Docker Swarm For High Availability | Docker Tutorial | DevOps Tutorial | Edureka
PDF
Big Data Use Cases | Hadoop Tutorial for Beginners | Hadoop Training | Edureka
PDF
What Is DevOps? | Introduction To DevOps | DevOps Tools | DevOps Tutorial | D...
PDF
Django Rest Framework | How to Create a RESTful API Using Django | Django Tut...
PDF
Selenium Page Object Model Using Page Factory | Selenium Tutorial For Beginne...
PDF
Introduction To TensorFlow | Deep Learning Using TensorFlow | TensorFlow Tuto...
PDF
Cloud Computing Tutorial For Beginners | What is Cloud Computing | AWS Traini...
PDF
Angular 4 Data Binding | Two Way Data Binding in Angular 4 | Angular 4 Tutori...
PDF
Azure Interview Questions And Answers | Azure Tutorial For Beginners | Azure ...
PDF
ReactJS Tutorial For Beginners | ReactJS Redux Training For Beginners | React...
PDF
Machine Learning In Python | Python Machine Learning Tutorial | Deep Learning...
PDF
Big Data Tutorial For Beginners | What Is Big Data | Big Data Tutorial | Hado...
PDF
Data Science Training | Data Science Tutorial | Data Science Certification | ...
PDF
Data Science Tutorial | Introduction To Data Science | Data Science Training ...
PDF
Introduction to Data Science
Angular 4 Components | Angular 4 Tutorial For Beginners | Learn Angular 4 | E...
Bitcoin Blockchain Explained | Understanding Bitcoin and Blockchain | Blockch...
Angular 4 Tutorial For Beginners | Angular 4 Introduction | Angular 4 Trainin...
Artificial Neural Network Tutorial | Deep Learning With Neural Networks | Edu...
Power BI Training | Getting Started with Power BI | Power BI Tutorial | Power...
Docker Swarm For High Availability | Docker Tutorial | DevOps Tutorial | Edureka
Big Data Use Cases | Hadoop Tutorial for Beginners | Hadoop Training | Edureka
What Is DevOps? | Introduction To DevOps | DevOps Tools | DevOps Tutorial | D...
Django Rest Framework | How to Create a RESTful API Using Django | Django Tut...
Selenium Page Object Model Using Page Factory | Selenium Tutorial For Beginne...
Introduction To TensorFlow | Deep Learning Using TensorFlow | TensorFlow Tuto...
Cloud Computing Tutorial For Beginners | What is Cloud Computing | AWS Traini...
Angular 4 Data Binding | Two Way Data Binding in Angular 4 | Angular 4 Tutori...
Azure Interview Questions And Answers | Azure Tutorial For Beginners | Azure ...
ReactJS Tutorial For Beginners | ReactJS Redux Training For Beginners | React...
Machine Learning In Python | Python Machine Learning Tutorial | Deep Learning...
Big Data Tutorial For Beginners | What Is Big Data | Big Data Tutorial | Hado...
Data Science Training | Data Science Tutorial | Data Science Certification | ...
Data Science Tutorial | Introduction To Data Science | Data Science Training ...
Introduction to Data Science
Ad

Similar to Android Studio Tutorial For Beginners -2 | Android Development Tutorial | Android Training | Edureka (20)

PPTX
B2. activity and intent
PPTX
Event Handling in Mobile Application Development.pptx
DOCX
Android intents in android application-chapter7
PDF
[Android] Widget Event Handling
PDF
Intents in Android
PPTX
Tk2323 lecture 3 intent
PDF
Ch5 intent broadcast receivers adapters and internet
PDF
Android Lesson 3 - Intent
PPTX
Data Transfer between activities and Database
ODP
Ppt 2 android_basics
PDF
Android development - Activities, Views & Intents
PPTX
11.11.2020 - Unit 5-3 ACTIVITY, MENU AND SQLITE DATABASE.pptx
PDF
Mobile Application Development
PPT
Level 1 & 2
PPTX
MAD unit 5.pptxyfc8yct7xugxigc8yc8c7yc7gc8yc
PDF
Lab1-android
PDF
Intents are Awesome
PDF
android_mod_3.useful for bca students for their last sem
PPTX
Data Transfer between Activities & Databases
PPTX
W5_Lec09_Lec10_Intents.pptx
B2. activity and intent
Event Handling in Mobile Application Development.pptx
Android intents in android application-chapter7
[Android] Widget Event Handling
Intents in Android
Tk2323 lecture 3 intent
Ch5 intent broadcast receivers adapters and internet
Android Lesson 3 - Intent
Data Transfer between activities and Database
Ppt 2 android_basics
Android development - Activities, Views & Intents
11.11.2020 - Unit 5-3 ACTIVITY, MENU AND SQLITE DATABASE.pptx
Mobile Application Development
Level 1 & 2
MAD unit 5.pptxyfc8yct7xugxigc8yc8c7yc7gc8yc
Lab1-android
Intents are Awesome
android_mod_3.useful for bca students for their last sem
Data Transfer between Activities & Databases
W5_Lec09_Lec10_Intents.pptx
Ad

More from Edureka! (20)

PDF
What to learn during the 21 days Lockdown | Edureka
PDF
Top 10 Dying Programming Languages in 2020 | Edureka
PDF
Top 5 Trending Business Intelligence Tools | Edureka
PDF
Tableau Tutorial for Data Science | Edureka
PDF
Python Programming Tutorial | Edureka
PDF
Top 5 PMP Certifications | Edureka
PDF
Top Maven Interview Questions in 2020 | Edureka
PDF
Linux Mint Tutorial | Edureka
PDF
How to Deploy Java Web App in AWS| Edureka
PDF
Importance of Digital Marketing | Edureka
PDF
RPA in 2020 | Edureka
PDF
Email Notifications in Jenkins | Edureka
PDF
EA Algorithm in Machine Learning | Edureka
PDF
Cognitive AI Tutorial | Edureka
PDF
AWS Cloud Practitioner Tutorial | Edureka
PDF
Blue Prism Top Interview Questions | Edureka
PDF
Big Data on AWS Tutorial | Edureka
PDF
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
PDF
Kubernetes Installation on Ubuntu | Edureka
PDF
Introduction to DevOps | Edureka
What to learn during the 21 days Lockdown | Edureka
Top 10 Dying Programming Languages in 2020 | Edureka
Top 5 Trending Business Intelligence Tools | Edureka
Tableau Tutorial for Data Science | Edureka
Python Programming Tutorial | Edureka
Top 5 PMP Certifications | Edureka
Top Maven Interview Questions in 2020 | Edureka
Linux Mint Tutorial | Edureka
How to Deploy Java Web App in AWS| Edureka
Importance of Digital Marketing | Edureka
RPA in 2020 | Edureka
Email Notifications in Jenkins | Edureka
EA Algorithm in Machine Learning | Edureka
Cognitive AI Tutorial | Edureka
AWS Cloud Practitioner Tutorial | Edureka
Blue Prism Top Interview Questions | Edureka
Big Data on AWS Tutorial | Edureka
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
Kubernetes Installation on Ubuntu | Edureka
Introduction to DevOps | Edureka

Recently uploaded (20)

PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PPT
Teaching material agriculture food technology
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Empathic Computing: Creating Shared Understanding
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
cuic standard and advanced reporting.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Teaching material agriculture food technology
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Building Integrated photovoltaic BIPV_UPV.pdf
Advanced methodologies resolving dimensionality complications for autism neur...
The Rise and Fall of 3GPP – Time for a Sabbatical?
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
MYSQL Presentation for SQL database connectivity
Empathic Computing: Creating Shared Understanding
20250228 LYD VKU AI Blended-Learning.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
The AUB Centre for AI in Media Proposal.docx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Network Security Unit 5.pdf for BCA BBA.
Diabetes mellitus diagnosis method based random forest with bat algorithm
cuic standard and advanced reporting.pdf

Android Studio Tutorial For Beginners -2 | Android Development Tutorial | Android Training | Edureka

  • 1. Copyright © 2017, edureka and/or its affiliates. All rights reserved.
  • 2. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Agenda ✓ What is Android Studio? ✓ Android Stack ✓ Installation ✓ What is an Activity? ✓ Activity Life Cycle ✓ Event Listeners ✓ Intents
  • 3. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Event Listeners Let’s look at various event listeners in an activity
  • 4. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Event Listeners  An event listener is an interface in the View class that contains a single callback method.  These are the tickets to capture the user interaction with your UI. This is called when the user either touches the item when in touch mode.  onClick() This is called when the user navigates onto or away from the item, using the navigation-keys or trackball.  onFocusChange() 1 2
  • 5. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Event Listeners  onLongClick()  onKey()  onTouch() The user either touches and holds the item when in touch mode. Say it holds the suitable "enter" key and holds down on the trackball (for one second). This is called when the user is focused on the item and presses or releases a hardware key on the device. This is called when the user performs an action qualified as a touch event, including a press, a release, or any movement gesture on the screen (within the bounds of the item). 3 4 5
  • 6. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Intents
  • 7. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Intents An intent is a messaging object you can use to request an action from another app component. ➢ Methods are used to deliver intents to different components: • context.startActivity() • context.startService() • context.sendBroadcast()
  • 8. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Intents  An intent can carry data bundle to perform any activity  For example if an activity has to launch an email operation, we can use an intent with ACTION_SEND. Types of Intent: Implicit Intent Explicit Intent 1 2
  • 9. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Implicit Intent Implicit intent is when the target component is not defined in the intent and the android system has to evaluate the registered components based on the intent data. Intent i = new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.edureka.co")); startActivity(i); Action Specification
  • 10. Copyright © 2017, edureka and/or its affiliates. All rights reserved. Explicit Intent Explicit intent is when an application defines the target component directly in the intent. Intent i = new Intent(this, ActivityTwo.class); i.putExtra("Value1", "This is ActivityTwo "); i.putExtra("Value2", "This value two for ActivityTwo"); startActivity(i); Target component