// Path: src/fr/xtof54/jsgo/GoJsActivity.java
// enum guistate {nogame, play, markDeadStones, checkScore, message, review, forums};


import java.io.BufferedReader;
import java.io.FileReader;
import java.io.FileWriter;
import java.io.PrintWriter;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import org.apache.http.client.methods.HttpGet;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ArrayAdapter;
import android.widget.EditText;
import android.widget.ListView;
import android.widget.AdapterView.OnItemClickListener;
import fr.xtof54.jsgo.R;
import fr.xtof54.jsgo.GoJsActivity.guistate;
import java.net.URLEncoder;

	static void showForums(final List<String> cats) {
		GoJsActivity.main.runOnUiThread(new Runnable() {
			@Override
			public void run() {
				if (cats.size()==0) {
					GoJsActivity.main.showMessage("No new forums; repress to see all forums");
					if (!showAll) switchShowNew();
					return;
				}
				System.out.println("set Forum view");
				GoJsActivity.main.setContentView(R.layout.forumcats);
				String[] c = new String[cats.size()];
				for (int i=0;i<c.length;i++) c[i]=cats.get(i);
				ArrayAdapter<String> adapter = new ArrayAdapter<String>(GoJsActivity.main, R.layout.detlistitem, c);
				final ListView listFrameview = (ListView)GoJsActivity.main.findViewById(R.id.forumCatsList);
				listFrameview.setAdapter(adapter);
				listFrameview.setOnItemClickListener(new OnItemClickListener() {
					@Override
					public void onItemClick(AdapterView<?> arg0, View arg1, int position, long id) {
						final int n=position;
						Thread forumcatthread = new Thread(new Runnable() {
							@Override
							public void run() {
								Forums.catChosen(n);
							}
						});
						forumcatthread.start();
					}
				});
// Path: src/fr/xtof54/jsgo/GoJsActivity.java
// enum guistate {nogame, play, markDeadStones, checkScore, message, review, forums};


// Path: src/fr/xtof54/jsgo/Forums.java
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.FileWriter;
import java.io.PrintWriter;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import org.apache.http.client.methods.HttpGet;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ArrayAdapter;
import android.widget.EditText;
import android.widget.ListView;
import android.widget.AdapterView.OnItemClickListener;
import fr.xtof54.jsgo.R;
import fr.xtof54.jsgo.GoJsActivity.guistate;
import java.net.URLEncoder;


	static void showForums(final List<String> cats) {
		GoJsActivity.main.runOnUiThread(new Runnable() {
			@Override
			public void run() {
				if (cats.size()==0) {
					GoJsActivity.main.showMessage("No new forums; repress to see all forums");
					if (!showAll) switchShowNew();
					return;
				}
				System.out.println("set Forum view");
				GoJsActivity.main.setContentView(R.layout.forumcats);
				String[] c = new String[cats.size()];
				for (int i=0;i<c.length;i++) c[i]=cats.get(i);
				ArrayAdapter<String> adapter = new ArrayAdapter<String>(GoJsActivity.main, R.layout.detlistitem, c);
				final ListView listFrameview = (ListView)GoJsActivity.main.findViewById(R.id.forumCatsList);
				listFrameview.setAdapter(adapter);
				listFrameview.setOnItemClickListener(new OnItemClickListener() {
					@Override
					public void onItemClick(AdapterView<?> arg0, View arg1, int position, long id) {
						final int n=position;
						Thread forumcatthread = new Thread(new Runnable() {
							@Override
							public void run() {
								Forums.catChosen(n);
							}
						});
						forumcatthread.start();
					}
				});
				GoJsActivity.main.curstate=guistate.forums;