[Android] Add 'final' to all of the class declarations.
This prevents inheritance of the classes (will throw a compiler error if you try and extend any of the classes). This is mainly syntactical sugar and form. Nothing major.
This commit is contained in:
parent
a791733c27
commit
0142efbb2a
|
@ -16,7 +16,7 @@ import java.util.List;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class AboutFragment extends Fragment {
|
||||
public final class AboutFragment extends Fragment {
|
||||
private static Activity m_activity;
|
||||
|
||||
private ListView mMainList;
|
||||
|
|
|
@ -17,7 +17,7 @@ import android.view.WindowManager;
|
|||
import java.io.*;
|
||||
import java.util.List;
|
||||
|
||||
public class DolphinEmulator<MainActivity> extends Activity
|
||||
public final class DolphinEmulator<MainActivity> extends Activity
|
||||
{
|
||||
static private NativeGLSurfaceView GLview = null;
|
||||
static private boolean Running = false;
|
||||
|
|
|
@ -14,7 +14,7 @@ import android.widget.Toast;
|
|||
import java.io.File;
|
||||
import java.util.*;
|
||||
|
||||
public class FolderBrowser extends Fragment {
|
||||
public final class FolderBrowser extends Fragment {
|
||||
private Activity m_activity;
|
||||
private FolderBrowserAdapter adapter;
|
||||
private ListView mDrawerList;
|
||||
|
|
|
@ -11,7 +11,7 @@ import android.widget.TextView;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public class FolderBrowserAdapter extends ArrayAdapter<FolderBrowserItem>{
|
||||
public final class FolderBrowserAdapter extends ArrayAdapter<FolderBrowserItem>{
|
||||
|
||||
private Context c;
|
||||
private int id;
|
||||
|
|
|
@ -22,7 +22,7 @@ import java.util.List;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class GameListActivity extends Activity
|
||||
public final class GameListActivity extends Activity
|
||||
implements GameListFragment.OnGameListZeroListener{
|
||||
|
||||
private int mCurFragmentNum = 0;
|
||||
|
|
|
@ -10,7 +10,7 @@ import android.widget.TextView;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public class GameListAdapter extends ArrayAdapter<GameListItem>{
|
||||
public final class GameListAdapter extends ArrayAdapter<GameListItem>{
|
||||
|
||||
private Context c;
|
||||
private int id;
|
||||
|
|
|
@ -24,7 +24,7 @@ import java.util.Set;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class GameListFragment extends Fragment
|
||||
public final class GameListFragment extends Fragment
|
||||
{
|
||||
private ListView mMainList;
|
||||
private GameListAdapter mGameAdapter;
|
||||
|
|
|
@ -8,7 +8,7 @@ import java.io.File;
|
|||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
public class GameListItem implements Comparable<GameListItem>{
|
||||
public final class GameListItem implements Comparable<GameListItem>{
|
||||
private String name;
|
||||
private String data;
|
||||
private String path;
|
||||
|
|
|
@ -14,7 +14,7 @@ import java.util.List;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class InputConfigAdapter extends ArrayAdapter<InputConfigItem> {
|
||||
public final class InputConfigAdapter extends ArrayAdapter<InputConfigItem> {
|
||||
private Context c;
|
||||
private int id;
|
||||
private List<InputConfigItem> items;
|
||||
|
|
|
@ -18,7 +18,7 @@ import java.util.List;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class InputConfigFragment extends Fragment
|
||||
public final class InputConfigFragment extends Fragment
|
||||
implements GameListActivity.OnGameConfigListener{
|
||||
private Activity m_activity;
|
||||
private ListView mDrawerList;
|
||||
|
|
|
@ -9,7 +9,7 @@ package org.dolphinemu.dolphinemu;
|
|||
/**
|
||||
* Represents a controller input item (button, stick, etc).
|
||||
*/
|
||||
public class InputConfigItem implements Comparable<InputConfigItem>{
|
||||
public final class InputConfigItem implements Comparable<InputConfigItem>{
|
||||
private String m_name;
|
||||
private String m_Config;
|
||||
private String m_bind;
|
||||
|
|
|
@ -4,7 +4,7 @@ import android.content.Context;
|
|||
import android.view.SurfaceHolder;
|
||||
import android.view.SurfaceView;
|
||||
|
||||
public class NativeGLSurfaceView extends SurfaceView {
|
||||
public final class NativeGLSurfaceView extends SurfaceView {
|
||||
static private Thread myRun;
|
||||
static private boolean Running = false;
|
||||
static private boolean Created = false;
|
||||
|
|
|
@ -13,7 +13,7 @@ import android.view.Surface;
|
|||
* Class which contains methods that interact
|
||||
* with the native side of the Dolphin code.
|
||||
*/
|
||||
public class NativeLibrary {
|
||||
public final class NativeLibrary {
|
||||
public static native void onTouchEvent(int Action, float X, float Y);
|
||||
public static native void onGamePadEvent(String Device, int Button, int Action);
|
||||
public static native void onGamePadMoveEvent(String Device, int Axis, float Value);
|
||||
|
|
|
@ -17,7 +17,7 @@ import javax.microedition.khronos.opengles.GL10;
|
|||
* Licensed under GPLv2
|
||||
* Refer to the license.txt file included.
|
||||
*/
|
||||
public class PrefsFragment extends PreferenceFragment {
|
||||
public final class PrefsFragment extends PreferenceFragment {
|
||||
private Activity m_activity;
|
||||
|
||||
static public class VersionCheck {
|
||||
|
|
|
@ -9,7 +9,7 @@ import android.widget.TextView;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public class SideMenuAdapter extends ArrayAdapter<SideMenuItem>{
|
||||
public final class SideMenuAdapter extends ArrayAdapter<SideMenuItem>{
|
||||
|
||||
private Context c;
|
||||
private int id;
|
||||
|
|
|
@ -10,7 +10,7 @@ package org.dolphinemu.dolphinemu;
|
|||
/**
|
||||
* Represents an item that goes in the sidemenu of the app.
|
||||
*/
|
||||
public class SideMenuItem implements Comparable<SideMenuItem>
|
||||
public final class SideMenuItem implements Comparable<SideMenuItem>
|
||||
{
|
||||
private String m_name;
|
||||
private int m_id;
|
||||
|
|
Loading…
Reference in New Issue