Some code cleanup
This commit is contained in:
parent
5ef0bad6c8
commit
d72242d081
|
@ -13,3 +13,4 @@ local.properties
|
|||
/captures
|
||||
.externalNativeBuild
|
||||
.cxx
|
||||
build
|
||||
|
|
|
@ -9,11 +9,11 @@ import emu.project64.jni.SettingsID;
|
|||
import emu.project64.util.Strings;
|
||||
import emu.project64.util.Utility;
|
||||
import android.os.Bundle;
|
||||
import android.support.design.widget.TabLayout;
|
||||
import android.support.v4.view.ViewPager;
|
||||
import android.support.v7.app.ActionBar;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
import com.google.android.material.tabs.TabLayout;
|
||||
import androidx.viewpager.widget.ViewPager;
|
||||
import androidx.appcompat.app.ActionBar;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.appcompat.widget.Toolbar;
|
||||
import android.text.Html;
|
||||
import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
|
@ -21,7 +21,7 @@ import android.webkit.WebView;
|
|||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
public class AboutActivity extends AppCompatActivity
|
||||
public class AboutActivity extends AppCompatActivity
|
||||
{
|
||||
public final static int MODE_ABOUT = 0;
|
||||
public final static int MODE_LICENCE = 1;
|
||||
|
@ -32,20 +32,21 @@ public class AboutActivity extends AppCompatActivity
|
|||
public void onCreate( Bundle savedInstanceState )
|
||||
{
|
||||
super.onCreate( savedInstanceState );
|
||||
setContentView( R.layout.about_activity );
|
||||
|
||||
// Add the tool bar to the activity (which supports the fancy menu/arrow animation)
|
||||
setContentView( R.layout.about_activity );
|
||||
|
||||
m_title_clicks = 0;
|
||||
|
||||
Toolbar toolbar = (Toolbar) findViewById( R.id.toolbar );
|
||||
toolbar.setTitle( getString(R.string.app_name) + " " + NativeExports.appVersion() );
|
||||
setSupportActionBar( toolbar );
|
||||
ActionBar actionbar = getSupportActionBar();
|
||||
|
||||
|
||||
if (AndroidDevice.IS_ICE_CREAM_SANDWICH)
|
||||
{
|
||||
actionbar.setHomeButtonEnabled(true);
|
||||
actionbar.setDisplayHomeAsUpEnabled(true);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
View aboutMain = findViewById(R.id.about_main);
|
||||
WebView webView = (WebView)findViewById(R.id.webview);
|
||||
|
||||
|
@ -54,13 +55,13 @@ public class AboutActivity extends AppCompatActivity
|
|||
ViewPager viewPager = (ViewPager) findViewById(R.id.pager);
|
||||
viewPager.setOffscreenPageLimit(MODE_TOTAL-1);
|
||||
viewPager.setAdapter(new AboutPagerAdapter(lists, titles));
|
||||
|
||||
|
||||
TabLayout tabLayout = (TabLayout) findViewById(R.id.sliding_tabs);
|
||||
tabLayout.setupWithViewPager(viewPager);
|
||||
|
||||
TextView link = (TextView)findViewById(R.id.main_link);
|
||||
link.setText(Html.fromHtml(getString(R.string.about_link)));
|
||||
|
||||
|
||||
TextView app_name_full = (TextView)findViewById(R.id.app_name_full);
|
||||
app_name_full.setText(Strings.GetString(LanguageStringID.ANDROID_ABOUT_APP_NAME));
|
||||
|
||||
|
@ -72,11 +73,11 @@ public class AboutActivity extends AppCompatActivity
|
|||
|
||||
webView.loadData(Utility.readAsset("licence.htm", ""), "text/html", "UTF8");
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean onOptionsItemSelected(MenuItem item)
|
||||
public boolean onOptionsItemSelected(MenuItem item)
|
||||
{
|
||||
switch (item.getItemId())
|
||||
switch (item.getItemId())
|
||||
{
|
||||
case android.R.id.home:
|
||||
finish();
|
||||
|
@ -84,14 +85,14 @@ public class AboutActivity extends AppCompatActivity
|
|||
}
|
||||
return super.onOptionsItemSelected(item);
|
||||
}
|
||||
|
||||
public void onAppNameClick(View v)
|
||||
|
||||
public void onAppNameClick(View v)
|
||||
{
|
||||
m_title_clicks += 1;
|
||||
if (m_title_clicks == 6)
|
||||
{
|
||||
NativeExports.SettingsSaveBool(SettingsID.UserInterface_BasicMode.getValue(), false);
|
||||
Toast.makeText(this, "Advanced Mode Enabled", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
m_title_clicks += 1;
|
||||
if (m_title_clicks == 6)
|
||||
{
|
||||
NativeExports.SettingsSaveBool(SettingsID.UserInterface_BasicMode.getValue(), false);
|
||||
Toast.makeText(this, "Advanced Mode Enabled", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package emu.project64;
|
||||
|
||||
import android.database.DataSetObserver;
|
||||
import android.support.v4.view.PagerAdapter;
|
||||
import androidx.viewpager.widget.PagerAdapter;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ import emu.project64.util.Strings;
|
|||
import emu.project64.util.Utility;
|
||||
import android.annotation.TargetApi;
|
||||
import android.app.Activity;
|
||||
import android.app.AlertDialog;
|
||||
import androidx.appcompat.app.AlertDialog;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.DialogInterface.OnCancelListener;
|
||||
|
@ -51,14 +51,6 @@ import android.net.Uri;
|
|||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
import android.support.v4.content.res.ResourcesCompat;
|
||||
import android.support.v4.view.GravityCompat;
|
||||
import android.support.v4.widget.DrawerLayout;
|
||||
import android.support.v7.app.ActionBarDrawerToggle;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.support.v7.widget.GridLayoutManager;
|
||||
import android.support.v7.widget.RecyclerView;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
import android.text.SpannableStringBuilder;
|
||||
import android.text.method.LinkMovementMethod;
|
||||
import android.text.style.ClickableSpan;
|
||||
|
@ -75,6 +67,16 @@ import android.widget.ListAdapter;
|
|||
import android.widget.TextView;
|
||||
import android.widget.TextView.BufferType;
|
||||
|
||||
import androidx.appcompat.app.ActionBar;
|
||||
import androidx.appcompat.app.ActionBarDrawerToggle;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.appcompat.widget.Toolbar;
|
||||
import androidx.core.content.res.ResourcesCompat;
|
||||
import androidx.core.view.GravityCompat;
|
||||
import androidx.drawerlayout.widget.DrawerLayout;
|
||||
import androidx.recyclerview.widget.GridLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
public class GalleryActivity extends AppCompatActivity implements IabBroadcastListener
|
||||
{
|
||||
//Progress dialog for ROM scan
|
||||
|
@ -231,14 +233,14 @@ public class GalleryActivity extends AppCompatActivity implements IabBroadcastLi
|
|||
}
|
||||
});
|
||||
UpdateLanguage();
|
||||
|
||||
|
||||
int RunCount = NativeExports.UISettingsLoadDword(UISettingID.AppInfo_RunCount.getValue()) + 1;
|
||||
if (RunCount < 1) { RunCount = 1; }
|
||||
if (RunCount < 1) { RunCount = 1; }
|
||||
NativeExports.UISettingsSaveDword(UISettingID.AppInfo_RunCount.getValue(), RunCount);
|
||||
Log.d("GalleryActivity", "ShowSupportWindow RunCount = " + RunCount);
|
||||
if (RunCount == 5 || RunCount == 10)
|
||||
{
|
||||
ShowReviewOptions();
|
||||
ShowReviewOptions();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -388,10 +390,10 @@ public class GalleryActivity extends AppCompatActivity implements IabBroadcastLi
|
|||
{
|
||||
switch( item.getItemId() )
|
||||
{
|
||||
case R.id.menuItem_gameDir:
|
||||
Intent intent = new Intent(this, ScanRomsActivity.class);
|
||||
startActivityForResult( intent, GAME_DIR_REQUEST_CODE );
|
||||
return true;
|
||||
case R.id.menuItem_GameDir:
|
||||
Intent ScanRomsIntent = new Intent(this, ScanRomsActivity.class);
|
||||
startActivityForResult( ScanRomsIntent, GAME_DIR_REQUEST_CODE );
|
||||
return true;
|
||||
case R.id.menuItem_settings:
|
||||
Intent SettingsIntent = new Intent(this, SettingsActivity.class);
|
||||
startActivity( SettingsIntent );
|
||||
|
@ -405,10 +407,10 @@ public class GalleryActivity extends AppCompatActivity implements IabBroadcastLi
|
|||
startActivity(IssueIntent);
|
||||
return true;
|
||||
case R.id.menuItem_review:
|
||||
ShowReviewOptions();
|
||||
ShowReviewOptions();
|
||||
return true;
|
||||
case R.id.menuItem_support:
|
||||
ShowPaymentOptions();
|
||||
ShowPaymentOptions();
|
||||
return true;
|
||||
case R.id.menuItem_about:
|
||||
Intent AboutIntent = new Intent(this, AboutActivity.class);
|
||||
|
@ -605,7 +607,6 @@ public class GalleryActivity extends AppCompatActivity implements IabBroadcastLi
|
|||
{
|
||||
NativeExports.LoadGame(item.romFile.getAbsolutePath());
|
||||
StartGameMenu(true);
|
||||
Log.d("GalleryActivity", "onGalleryItemLongClick 4");
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -817,7 +818,7 @@ public class GalleryActivity extends AppCompatActivity implements IabBroadcastLi
|
|||
})
|
||||
.setCancelable(false).show();
|
||||
}
|
||||
|
||||
|
||||
public void ShowPaymentOptions()
|
||||
{
|
||||
ArrayList<String> skuList = new ArrayList<String>();
|
||||
|
|
|
@ -7,7 +7,6 @@ import java.util.List;
|
|||
import emu.project64.R;
|
||||
import android.content.Context;
|
||||
import android.graphics.Color;
|
||||
import android.support.v7.widget.RecyclerView;
|
||||
import android.text.TextUtils;
|
||||
import android.util.TypedValue;
|
||||
import android.view.LayoutInflater;
|
||||
|
@ -18,6 +17,8 @@ import android.view.ViewGroup;
|
|||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
public class GalleryItem
|
||||
{
|
||||
public final String goodName;
|
||||
|
|
|
@ -118,7 +118,7 @@ public class SplashActivity extends AppCompatActivity implements ExtractAssetsLi
|
|||
}
|
||||
mInit = true;
|
||||
String ConfigFile = AndroidDevice.PACKAGE_DIRECTORY + "/Config/Project64.cfg";
|
||||
if(( new File( ConfigFile ) ).exists())
|
||||
if((new File(ConfigFile)).exists())
|
||||
{
|
||||
InitProject64();
|
||||
}
|
||||
|
@ -284,7 +284,7 @@ public class SplashActivity extends AppCompatActivity implements ExtractAssetsLi
|
|||
@Override
|
||||
public void run()
|
||||
{
|
||||
Log.e( "Splash", "extractAssetsTaskLauncher - start");
|
||||
Log.i( "Splash", "extractAssetsTaskLauncher - start");
|
||||
TOTAL_ASSETS = 0;
|
||||
CountTotalAssetFiles(SOURCE_DIR);
|
||||
mAssetsExtracted = 0;
|
||||
|
@ -312,12 +312,8 @@ public class SplashActivity extends AppCompatActivity implements ExtractAssetsLi
|
|||
}
|
||||
mTextView.setText( R.string.assetExtractor_finished );
|
||||
NativeExports.UISettingsSaveDword(UISettingID.Asserts_Version.getValue(), ASSET_VERSION);
|
||||
|
||||
// Launch gallery activity
|
||||
Intent intent = new Intent( this, GalleryActivity.class );
|
||||
this.startActivity( intent );
|
||||
|
||||
// We never want to come back to this activity, so finish it
|
||||
finish();
|
||||
}
|
||||
else
|
||||
|
|
|
@ -2,13 +2,14 @@ package emu.project64.game;
|
|||
|
||||
import emu.project64.jni.NativeExports;
|
||||
import emu.project64.jni.SystemEvent;
|
||||
import android.app.Activity;
|
||||
import android.app.AlertDialog;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
|
||||
public class GameActivity extends Activity
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
public class GameActivity extends AppCompatActivity
|
||||
{
|
||||
private GameLifecycleHandler mLifecycleHandler;
|
||||
@SuppressWarnings("unused")
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package emu.project64.jni;
|
||||
|
||||
public enum LanguageStringID
|
||||
{
|
||||
{
|
||||
EMPTY_STRING(0),
|
||||
|
||||
/*********************************************************************************
|
||||
|
@ -379,7 +379,7 @@ public enum LanguageStringID
|
|||
STR_FR_DLS(701),
|
||||
STR_FR_PERCENT(702),
|
||||
STR_FR_DLS_VIS(703),
|
||||
STR_FR_NONE(704),
|
||||
STR_FR_NONE(704),
|
||||
|
||||
// Increase speed
|
||||
STR_INSREASE_SPEED(710),
|
||||
|
@ -531,7 +531,7 @@ public enum LanguageStringID
|
|||
MSG_DEL_TITLE(2042),
|
||||
MSG_CHEAT_NAME_IN_USE(2043),
|
||||
MSG_MAX_CHEATS(2044),
|
||||
MSG_PLUGIN_INIT(2045),
|
||||
MSG_PLUGIN_INIT(2045),
|
||||
MSG_NO_SHORTCUT_SEL(2046),
|
||||
MSG_NO_MENUITEM_SEL(2047),
|
||||
MSG_MENUITEM_ASSIGNED(2048),
|
||||
|
@ -569,10 +569,10 @@ public enum LanguageStringID
|
|||
ANDROID_ABOUT_REVISION(3018),
|
||||
ANDROID_ABOUT_TEXT(3019),
|
||||
ANDROID_ABOUT_PJ64_AUTHORS(3020),
|
||||
ANDROID_DISCORD(3021),
|
||||
ANDROID_SUPPORT_PJ64(3022),
|
||||
ANDROID_REVIEW_PJ64(3023),
|
||||
|
||||
ANDROID_DISCORD(3021),
|
||||
ANDROID_SUPPORT_PJ64(3022),
|
||||
ANDROID_REVIEW_PJ64(3023),
|
||||
|
||||
//In game menu
|
||||
ANDROID_MENU_SETTINGS(3100),
|
||||
ANDROID_MENU_SAVESTATE(3101),
|
||||
|
@ -592,26 +592,26 @@ public enum LanguageStringID
|
|||
//Video plugin
|
||||
ANDROID_VIDEO_NATIVE_RES(3200),
|
||||
;
|
||||
|
||||
|
||||
private int value;
|
||||
|
||||
public int getValue()
|
||||
|
||||
public int getValue()
|
||||
{
|
||||
return this.value;
|
||||
}
|
||||
private static final class StaticFields
|
||||
private static final class StaticFields
|
||||
{
|
||||
public static int Counter = 0;
|
||||
}
|
||||
|
||||
|
||||
private LanguageStringID()
|
||||
{
|
||||
this.value = StaticFields.Counter;
|
||||
StaticFields.Counter += 1;
|
||||
this.value = StaticFields.Counter;
|
||||
StaticFields.Counter += 1;
|
||||
}
|
||||
private LanguageStringID(int value)
|
||||
{
|
||||
this.value = value;
|
||||
StaticFields.Counter = this.value + 1;
|
||||
}
|
||||
this.value = value;
|
||||
StaticFields.Counter = this.value + 1;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,17 +1,10 @@
|
|||
package emu.project64.jni;
|
||||
|
||||
/**
|
||||
* Calls made between the native input-android library and Java. Any function names changed here
|
||||
* should also be changed in the corresponding C code, and vice versa.
|
||||
*
|
||||
* @see /Source/Android/PluginInput/Main.cpp
|
||||
* @see CoreInterface
|
||||
*/
|
||||
public class NativeVideo
|
||||
{
|
||||
static
|
||||
{
|
||||
System.loadLibrary( "Project64-gfx" );
|
||||
System.loadLibrary( "Project64-video" );
|
||||
}
|
||||
|
||||
public static native void UpdateScreenRes(int ScreenWidth, int ScreenHeight);
|
||||
|
|
|
@ -20,11 +20,11 @@ public enum SettingsID
|
|||
SupportFile_VideoRDBDefault,
|
||||
SupportFile_AudioRDB,
|
||||
SupportFile_AudioRDBDefault,
|
||||
SupportFile_Cheats,
|
||||
SupportFile_CheatsDefault,
|
||||
SupportFile_Enhancements,
|
||||
SupportFile_EnhancementsDefault,
|
||||
SupportFile_Notes,
|
||||
SupportFile_Cheats,
|
||||
SupportFile_CheatsDefault,
|
||||
SupportFile_Enhancements,
|
||||
SupportFile_EnhancementsDefault,
|
||||
SupportFile_Notes,
|
||||
SupportFile_NotesDefault,
|
||||
SupportFile_ExtInfo,
|
||||
SupportFile_ExtInfoDefault,
|
||||
|
@ -47,19 +47,19 @@ public enum SettingsID
|
|||
Setting_LanguageDirDefault,
|
||||
Setting_CurrentLanguage,
|
||||
Setting_EnableDisk,
|
||||
Setting_SyncViaAudioEnabled,
|
||||
Setting_Enhancement,
|
||||
Setting_SyncViaAudioEnabled,
|
||||
Setting_Enhancement,
|
||||
|
||||
//Default Settings
|
||||
Default_RDRamSize,
|
||||
Default_UseHleGfx,
|
||||
Default_UseTlb,
|
||||
Default_ViRefreshRate,
|
||||
Default_AiCountPerBytes,
|
||||
Default_CounterFactor,
|
||||
Default_32Bit,
|
||||
Default_SyncViaAudio,
|
||||
Default_FixedAudio,
|
||||
Default_UseHleGfx,
|
||||
Default_UseTlb,
|
||||
Default_ViRefreshRate,
|
||||
Default_AiCountPerBytes,
|
||||
Default_CounterFactor,
|
||||
Default_32Bit,
|
||||
Default_SyncViaAudio,
|
||||
Default_FixedAudio,
|
||||
Default_UnalignedDMA,
|
||||
|
||||
//RDB Settings
|
||||
|
@ -321,15 +321,15 @@ public enum SettingsID
|
|||
Cheat_Active,
|
||||
Cheat_Extension,
|
||||
|
||||
//Enhancement
|
||||
Enhancement_Name,
|
||||
Enhancement_Active,
|
||||
Enhancement_OnByDefault,
|
||||
Enhancement_Overclock,
|
||||
Enhancement_OverclockValue,
|
||||
Enhancement_Gameshark,
|
||||
Enhancement_GamesharkCode,
|
||||
Enhancement_Notes,
|
||||
//Enhancement
|
||||
Enhancement_Name,
|
||||
Enhancement_Active,
|
||||
Enhancement_OnByDefault,
|
||||
Enhancement_Overclock,
|
||||
Enhancement_OverclockValue,
|
||||
Enhancement_Gameshark,
|
||||
Enhancement_GamesharkCode,
|
||||
Enhancement_Notes,
|
||||
|
||||
FirstUISettings, LastUISettings(FirstUISettings.getValue() + 65535),
|
||||
FirstRSPDefaultSet, LastRSPDefaultSet(FirstRSPDefaultSet.getValue() + 65535),
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package emu.project64.settings;
|
||||
|
||||
import emu.project64.R;
|
||||
import android.support.v7.preference.Preference;
|
||||
import androidx.preference.Preference;
|
||||
|
||||
public class AdvancedFragment extends BaseSettingsFragment
|
||||
{
|
||||
|
|
|
@ -7,16 +7,16 @@ import emu.project64.profile.ControllerProfileActivity;
|
|||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.DialogFragment;
|
||||
import android.support.v4.app.Fragment;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.support.v7.preference.Preference;
|
||||
import android.support.v7.preference.PreferenceFragmentCompat;
|
||||
import androidx.appcompat.app.AlertDialog;
|
||||
import androidx.fragment.app.DialogFragment;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.preference.Preference;
|
||||
import androidx.preference.PreferenceFragmentCompat;
|
||||
|
||||
public abstract class BaseSettingsFragment extends PreferenceFragmentCompat
|
||||
{
|
||||
private static final String DIALOG_FRAGMENT_TAG = "android.support.v7.preference.PreferenceFragment.DIALOG";
|
||||
private static final String DIALOG_FRAGMENT_TAG = "androidx.preference.PreferenceFragment.DIALOG";
|
||||
|
||||
protected abstract int getXml();
|
||||
protected abstract int getTitleId();
|
||||
|
|
|
@ -7,9 +7,9 @@ import emu.project64.jni.SettingsID;
|
|||
import android.content.SharedPreferences;
|
||||
import android.os.Bundle;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.support.v7.app.ActionBar;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
import androidx.appcompat.app.ActionBar;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.appcompat.widget.Toolbar;
|
||||
import android.view.MenuItem;
|
||||
|
||||
public class GameSettingsActivity extends AppCompatActivity implements SharedPreferences.OnSharedPreferenceChangeListener
|
||||
|
|
|
@ -3,7 +3,7 @@ package emu.project64.settings;
|
|||
import emu.project64.R;
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
import android.support.v7.preference.DialogPreference;
|
||||
import androidx.preference.DialogPreference;
|
||||
import android.util.AttributeSet;
|
||||
import android.widget.SeekBar;
|
||||
|
||||
|
|
|
@ -2,10 +2,10 @@ package emu.project64.settings;
|
|||
|
||||
import emu.project64.R;
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
import android.support.v7.preference.DialogPreference;
|
||||
import android.support.v7.preference.Preference;
|
||||
import android.support.v7.preference.PreferenceDialogFragmentCompat;
|
||||
import androidx.appcompat.app.AlertDialog;
|
||||
import androidx.preference.DialogPreference;
|
||||
import androidx.preference.Preference;
|
||||
import androidx.preference.PreferenceDialogFragmentCompat;
|
||||
import android.view.View;
|
||||
import android.widget.SeekBar;
|
||||
import android.widget.TextView;
|
||||
|
|
|
@ -3,7 +3,7 @@ package emu.project64.settings;
|
|||
import emu.project64.R;
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
import android.support.v7.preference.ListPreference;
|
||||
import androidx.preference.ListPreference;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
public class TwoLinesListPreference extends ListPreference
|
||||
|
|
|
@ -7,9 +7,6 @@ import java.io.InputStream;
|
|||
import java.io.InputStreamReader;
|
||||
import emu.project64.Project64Application;
|
||||
|
||||
/**
|
||||
* Utility class which collects a bunch of commonly used methods into one class.
|
||||
*/
|
||||
public final class Utility
|
||||
{
|
||||
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
*.c
|
||||
*.cpp
|
||||
*.h
|
||||
*.vcproj
|
||||
*.vcxproj
|
||||
*.vcxproj.filters
|
||||
*.dsp
|
||||
*.plg
|
|
@ -0,0 +1,27 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("png")
|
||||
|
||||
add_library(png STATIC
|
||||
png.c
|
||||
pngerror.c
|
||||
pngget.c
|
||||
pngmem.c
|
||||
pngpread.c
|
||||
pngread.c
|
||||
pngrio.c
|
||||
pngrtran.c
|
||||
pngrutil.c
|
||||
pngset.c
|
||||
pngtest.c
|
||||
pngtrans.c
|
||||
pngwio.c
|
||||
pngwrite.c
|
||||
pngwtran.c
|
||||
pngwutil.c)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
|
||||
target_link_libraries(png)
|
|
@ -0,0 +1,12 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("Project64-input-android")
|
||||
|
||||
add_library(Project64-input-android SHARED
|
||||
Main.cpp)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
|
||||
target_link_libraries(Project64-input-android)
|
|
@ -0,0 +1,23 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("Project64-rsp-hle")
|
||||
|
||||
add_library(Project64-rsp-hle SHARED
|
||||
alist.cpp
|
||||
alist_audio.cpp
|
||||
alist_naudio.cpp
|
||||
alist_nead.cpp
|
||||
audio.cpp
|
||||
cicx105.cpp
|
||||
hle.cpp
|
||||
jpeg.cpp
|
||||
main.cpp
|
||||
mem.cpp
|
||||
mp3.cpp
|
||||
musyx.cpp)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
|
||||
target_link_libraries(Project64-rsp-hle)
|
|
@ -0,0 +1,19 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("Project64-audio-android")
|
||||
include_directories(..)
|
||||
|
||||
add_library(Project64-audio-android SHARED
|
||||
Driver/OpenSLES.cpp
|
||||
Driver/SoundBase.cpp
|
||||
AudioMain.cpp
|
||||
AudioSettings.cpp
|
||||
trace.cpp)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common)
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../Settings ${CMAKE_CURRENT_BINARY_DIR}/Settings)
|
||||
target_link_libraries(Project64-audio-android Common settings log OpenSLES)
|
|
@ -0,0 +1,76 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("Project64-video")
|
||||
include_directories(..)
|
||||
include_directories(../3rdParty)
|
||||
include_directories(./Renderer/inc)
|
||||
|
||||
add_library(Project64-video SHARED
|
||||
3dmath.cpp
|
||||
Android.cpp
|
||||
Combine.cpp
|
||||
Config.cpp
|
||||
CRC.cpp
|
||||
Debugger.cpp
|
||||
DepthBufferRender.cpp
|
||||
F3DTEXA.cpp
|
||||
FBtoScreen.cpp
|
||||
Main.cpp
|
||||
rdp.cpp
|
||||
ScreenResolution.cpp
|
||||
Settings.cpp
|
||||
TexBuffer.cpp
|
||||
TexCache.cpp
|
||||
trace.cpp
|
||||
turbo3D.cpp
|
||||
ucode.cpp
|
||||
ucode00.cpp
|
||||
ucode01.cpp
|
||||
ucode02.cpp
|
||||
ucode03.cpp
|
||||
ucode04.cpp
|
||||
ucode05.cpp
|
||||
ucode06.cpp
|
||||
ucode07.cpp
|
||||
ucode08.cpp
|
||||
ucode09.cpp
|
||||
ucode09rdp.cpp
|
||||
ucodeFB.cpp
|
||||
Util.cpp
|
||||
Ext_TxFilter.cpp
|
||||
Renderer/OGLEScombiner.cpp
|
||||
Renderer/OGLESgeometry.cpp
|
||||
Renderer/OGLESglitchmain.cpp
|
||||
Renderer/OGLEStextures.cpp
|
||||
Renderer/OGLESwrappers.cpp
|
||||
Renderer/Renderer.cpp
|
||||
TextureEnhancer/TxFilterExport.cpp
|
||||
TextureEnhancer/TxFilter.cpp
|
||||
TextureEnhancer/TxCache.cpp
|
||||
TextureEnhancer/TxTexCache.cpp
|
||||
TextureEnhancer/TxHiResCache.cpp
|
||||
TextureEnhancer/TxQuantize.cpp
|
||||
TextureEnhancer/TxUtil.cpp
|
||||
TextureEnhancer/TextureFilters.cpp
|
||||
TextureEnhancer/TextureFilters_2xsai.cpp
|
||||
TextureEnhancer/TextureFilters_hq2x.cpp
|
||||
TextureEnhancer/TextureFilters_hq4x.cpp
|
||||
TextureEnhancer/TxImage.cpp
|
||||
TextureEnhancer/TxReSample.cpp
|
||||
TextureEnhancer/TxDbg.cpp
|
||||
TextureEnhancer/tc-1.1+/fxt1.c
|
||||
TextureEnhancer/tc-1.1+/dxtn.c
|
||||
TextureEnhancer/tc-1.1+/wrapper.c
|
||||
TextureEnhancer/tc-1.1+/texstore.c)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
add_definitions(-DNOSSE)
|
||||
add_definitions(-DUSE_GLES)
|
||||
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../3rdParty/png ${CMAKE_CURRENT_BINARY_DIR}/3rdParty/png)
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../3rdParty/zlib ${CMAKE_CURRENT_BINARY_DIR}/3rdParty/zlib)
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../Common ${CMAKE_CURRENT_BINARY_DIR}/Common)
|
||||
ADD_SUBDIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/../Settings ${CMAKE_CURRENT_BINARY_DIR}/Settings)
|
||||
target_link_libraries(Project64-video png zlib Common settings GLESv2 log)
|
|
@ -0,0 +1,12 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
project("settings")
|
||||
|
||||
add_library(settings STATIC
|
||||
Settings.cpp)
|
||||
|
||||
add_definitions(-DANDROID)
|
||||
|
||||
target_link_libraries(settings)
|
Loading…
Reference in New Issue