Questions tagged [android-event]

On Android, there's more than one way to intercept the events from a user's interaction with your application. When considering events within your user interface, the approach is to capture the events from the specific View object that the user interacts with. The View class provides the means to do so. Questions that regard doubt about any type of events action (listeners and handlers), should use this tag to express themselves.

Within the various View classes that you'll use to compose your layout, you may notice several public callback methods that look useful for UI events. These methods are called by the Android framework when the respective action occurs on that object. For instance, when a View (such as a Button) is touched, the onTouchEvent() method is called on that object. However, in order to intercept this, you must extend the class and override the method. However, extending every View object in order to handle such an event would not be practical. This is why the View class also contains a collection of nested interfaces with callbacks that you can much more easily define. These interfaces, called event listeners, are your ticket to capturing the user interaction with your UI.

While you will more commonly use the event listeners to listen for user interaction, there may come a time when you do want to extend a View class, in order to build a custom component. Perhaps you want to extend the Button class to make something more fancy. In this case, you'll be able to define the default event behaviors for your class using the class event handlers.

For a more detailed information you can visit Google oficial webpage about Events at Google Developer - Events

318 questions
-3
votes
1 answer

Event error when clicked each delete button in Android ListView

I am making Android app but I am stuck on constructing list view. I want to remove each item by using delete button on each list item. What I mean that if I press a delete button in a specific row, a list item on the same row should be removed.…
Wongeun Cho
  • 101
  • 2
  • 10
-3
votes
1 answer

How to make all activities in android project move

I already created my activities but when I run the application it doesnt move when I touch d screen nothing happen meanwhile their are things below that I have to scroll down to see them any help.
olajide
  • 179
  • 1
  • 1
  • 7
-3
votes
2 answers

View.OnClickListener doen't get triggered in activity

I have an Activity which implements View.OnClickListener along with several other abstract methods form different classes. The problem is that the global onClick does not get triggered. I have to set a new OnClickListener for every individual view…
2hamed
  • 8,719
  • 13
  • 69
  • 112
1 2 3
21
22