Android Open Source - AndroidMooch Book List View






From Project

Back to project page AndroidMooch.

License

The source code is released under:

Copyright (c) 2010 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software witho...

If you think the Android project AndroidMooch listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.github.stchris.views;
//  ww w  .  j a va2s  .  com
import android.content.Context;
import android.widget.LinearLayout;
import android.widget.TextView;

public class BookListView extends LinearLayout {

  private TextView tvTitle;
  private TextView tvAuthor;
  
  public BookListView(Context context) {
    super(context);
  }

  public BookListView(Context context, String title, String author) {
    this(context);
    this.setOrientation(VERTICAL);
    tvTitle = new TextView(context);
    tvTitle.setText(title);
    tvAuthor = new TextView(context);
    tvAuthor.setText(author);
    
    addView(tvTitle, new LinearLayout.LayoutParams(
                LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
    addView(tvAuthor, new LinearLayout.LayoutParams(
                LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
  }
  
  public void setTitle(String title) {
    tvTitle.setText(title);
  }
  
  public void setAuthor(String author) {
    tvAuthor.setText(author);
  }
}




Java Source Code List

com.github.stchris.activities.BookInfoActivity.java
com.github.stchris.activities.BookSearchActivity.java
com.github.stchris.activities.BookSearchListActivity.java
com.github.stchris.activities.InventoryActivity.java
com.github.stchris.activities.MainActivity.java
com.github.stchris.activities.ShowImageActivity.java
com.github.stchris.activities.WishlistActivity.java
com.github.stchris.models.BookListAdapter.java
com.github.stchris.models.Book.java
com.github.stchris.queries.Constants.java
com.github.stchris.util.JSONUtil.java
com.github.stchris.util.Util.java
com.github.stchris.views.BookListView.java