Back to project page OneSearch.
The source code is released under:
MIT License
If you think the Android project OneSearch listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package chrisjluc.funsearch.ui.gameplay; //from ww w . ja va 2 s . c o m import android.app.Fragment; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.TextView; import chrisjluc.funsearch.R; import chrisjluc.funsearch.WordSearchManager; import chrisjluc.funsearch.wordSearchGenerator.generators.WordSearchGenerator; public class WordSearchFragment extends Fragment { private static final String ARG_SECTION_NUMBER = "section_number"; public static WordSearchFragment newInstance(int sectionNumber) { WordSearchFragment fragment = new WordSearchFragment(); Bundle args = new Bundle(); args.putInt(ARG_SECTION_NUMBER, sectionNumber); fragment.setArguments(args); return fragment; } public WordSearchFragment() { } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View rootView = inflater.inflate(R.layout.wordsearch_fragment, container, false); TextView tv = (TextView) rootView.findViewById(R.id.section_label); WordSearchGridView grid = (WordSearchGridView) rootView.findViewById(R.id.gridView); grid.setWordFoundListener((WordSearchGridView.WordFoundListener)getActivity()); tv.setText(grid.getWord()); return rootView; } }