Skip to content

Instantly share code, notes, and snippets.

View guuilp's full-sized avatar
😃
Hi!

Guilherme guuilp

😃
Hi!
View GitHub Profile
public static final String QUERY_PARAMETER = "q";
public void onClickOpenAddressButton(View v) {
// COMPLETED (5) Store an address in a String
String addressString = "1600 Amphitheatre Parkway, CA";
// COMPLETED (6) Use Uri.Builder with the appropriate scheme and query to form the Uri for the address
Uri.Builder builder = new Uri.Builder();
builder.scheme("geo")
.path("0,0")
<android.support.design.widget.TextInputLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:layout_marginBottom="8dp">
<EditText android:id="@+id/input_email"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Número de Cliente" />
</android.support.design.widget.TextInputLayout>
private NoticiaAdapter.NoticiaOnClickListener onClickNoticia() {
return new NoticiaAdapter.NoticiaOnClickListener() {
@Override
public void onClickNoticia(View view, int idx) {
Noticia c = noticias.get(idx);
@Override
public void onBindViewHolder(final NoticiaViewHolder holder, final int position) {
//Click
if (noticiaOnClickListener != null){
holder.itemView.setOnClickListener(new View.OnClickListener() {
private NoticiaOnClickListener noticiaOnClickListener;
public interface NoticiaOnClickListener{
public void onClickNoticia(View view, int idx);
}
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
tools:openDrawer="start">