Create an add projects button below the last active project in the projects page.

This commit is contained in:
Keith Uplinger 2013-05-03 15:09:32 +00:00 committed by Joachim Fritzsch
parent 6b22ba2902
commit 20dc090739
2 changed files with 17 additions and 1 deletions

View File

@ -27,6 +27,16 @@
android:layout_width="match_parent"
android:layout_height="wrap_content" >
</ListView>
</ListView>
<TextView
android:id="@+id/addProjectButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:clickable="true"
android:drawableTop="@android:drawable/ic_input_add"
android:onClick="addProjectClicked"
android:text="@string/projects_add" />
</LinearLayout>

View File

@ -37,6 +37,8 @@ import android.util.Log;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.ListView;
import android.widget.TextView;
import android.widget.Toast;
@ -196,6 +198,10 @@ public class ProjectsActivity extends FragmentActivity {
public void onProjectClicked(String url, String name) {
Log.d(TAG, "onProjectClicked()");
}
public void addProjectClicked(View view) {
onProjectAdd();
}
public void onProjectAdd() {
Log.d(TAG, "onProjectAdd()");