O GoConqr está de visual novo! Conte para nós o que você achou.

Notas

Building your first app

PIKANSHU KUMAR Computer Studies GRE Inglês 1 página

Conteúdo das notas (1)

Página 1

View objects are usually UI widgets such as buttons or text fields.

ViewGroup objects are invisible view containers that define how the child views are laid out, such as in a grid or a vertical list.

Layouts are subclasses of the ViewGroup.

LinearLayout is a view group (a subclass of ViewGroup).

The default weight for all views is 0, so if you specify any weight value greater than 0 to only one view, then that view fills whatever space remains after all views are given the space they require.

The weight value is a number that specifies the amount of remaining space each view should consume, relative to the amount consumed by sibling views.

An Intent is an object that provides runtime binding between separate components (such as two activities). The Intent represents an app’s "intent to do something."

The Intent constructor takes two parameters:

A Context as its first parameter (this is used because the Activity class is a subclass of Context)

The Class of the app component to which the system should deliver the Intent (in this case, the activity that should be started).

An Intent can carry data types as key-value pairs called extras. Your key is a public constant EXTRA_MESSAGE because the next activity uses the key to retrieve the text value.

It's a good practice to define keys for intent extras using your app's package name as a prefix. This ensures the keys are unique, in case your app interacts with other apps.

The call getIntent() grabs the intent that started the activity. Every Activity is invoked by an Intent, regardless of how the user navigated there. The call getStringExtra() retrieves the data from the first activity.

Informações

Descrição
GRE Computer Studies Notas sobre Building your first app, criado por PIKANSHU KUMAR em 01-03-2017.
Criado por
PIKANSHU KUMAR
Visualizações
4
Avaliação

Fale Conosco

Sobre o que é sua mensagem?

O que você acha do novo visual?

Você gostou?