package io.github.emanual.app.fragment;

import io.github.emanual.app.R;
import io.github.emanual.app.ui.TopicList;
import android.content.Intent;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;

public class LearnClub extends BaseFragment implements OnClickListener {
	@Override
	public View onCreateView(LayoutInflater inflater, ViewGroup container,
			Bundle savedInstanceState) {
		View v = inflater
				.inflate(R.layout.fragment_learnclub, container, false);
		v.findViewById(R.id.btn_basic).setOnClickListener(this);
		return v;
	}

	@Override
	public void onClick(View v) {
		Intent intent = new Intent(getActivity(), TopicList.class);
		switch (v.getId()) {
		case R.id.btn_basic:
			intent.putExtra("kind", "basic");
			intent.putExtra("title", "基础");
			break;
		default:
			toast("It's comming soon.");
			break;
		}
		startActivity(intent);
	}
}

@@ -654,249 +654,1345 @@
 %0D%0A%09%09
-return v;%0D%0A%09%7D%0D%0A%0D%0A%09@Override%0D%0A%09public void onClick(View v) %7B%0D%0A%09%09Intent intent = new Intent(getActivity(), TopicList.class);%0D%0A%09%09switch (v.getId()) %7B%0D%0A%09%09case R.id.btn_basic:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22basic%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22%E5%9F%BA%E7%A1%80
+v.findViewById(R.id.btn_advance).setOnClickListener(this);%0D%0A%09%09v.findViewById(R.id.btn_pattern).setOnClickListener(this);%0D%0A%09%09v.findViewById(R.id.btn_database).setOnClickListener(this);%0D%0A%09%09v.findViewById(R.id.btn_web).setOnClickListener(this);%0D%0A%09%09v.findViewById(R.id.btn_webframework).setOnClickListener(this);%0D%0A%09%09v.findViewById(R.id.btn_arithmetic).setOnClickListener(this);%0D%0A%09%09return v;%0D%0A%09%7D%0D%0A%0D%0A%09@Override%0D%0A%09public void onClick(View v) %7B%0D%0A%09%09Intent intent = new Intent(getActivity(), TopicList.class);%0D%0A%09%09switch (v.getId()) %7B%0D%0A%09%09case R.id.btn_basic:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22basic%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22Java%E5%9F%BA%E7%A1%80%22);%0D%0A%09%09%09break;%0D%0A%09%09case R.id.btn_advance:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22advance%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22Java%E8%BF%9B%E9%98%B6%22);%0D%0A%09%09%09break;%0D%0A%09%09case R.id.btn_pattern:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22pattern%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F%22);%0D%0A%09%09%09break;%0D%0A%0D%0A%09%09case R.id.btn_database:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22database%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22%E6%95%B0%E6%8D%AE%E5%BA%93%22);%0D%0A%09%09%09break;%0D%0A%09%09%09%0D%0A%09%09case R.id.btn_web:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22java_web%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22Java Web%22);%0D%0A%09%09%09break;%0D%0A%09%09case R.id.btn_webframework:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22framework%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22Web%E6%A1%86%E6%9E%B6%22);%0D%0A%09%09%09break;%0D%0A%09%09case R.id.btn_arithmetic:%0D%0A%09%09%09intent.putExtra(%22kind%22, %22arithmetic%22);%0D%0A%09%09%09intent.putExtra(%22title%22, %22%E7%AE%97%E6%B3%95%E5%AE%9E%E8%B7%B5
 %22);%0D

add activity link