Merge branch 'remove-sdl' of https://github.com/SDLash3D/xash3d-android-project into remove-sdl

This commit is contained in:
a1batross 2016-07-26 16:56:57 +06:00
commit e48b54d461
9 changed files with 23 additions and 5 deletions

@ -1 +1 @@
Subproject commit a581d08683dd5c6b5695cc334acd9d5d56b23f31 Subproject commit 1c21fb1dace7b943853c3332cf1a924723b51b44

@ -1 +1 @@
Subproject commit 1706490b2078cb45c35d25ebc46b1e96c6abcc38 Subproject commit 2c0f598c6d7990b2e1ae1af6178aa4b9e6d82cf6

View file

@ -270,6 +270,19 @@
android:layout_marginRight="10dp" android:layout_marginRight="10dp"
android:layout_marginTop="10dp"/> android:layout_marginTop="10dp"/>
<ToggleButton
android:id="@+id/enableResizeWorkaround"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="10dp"
android:text="enableResizeWorkaround"
android:textOff="Keyboard does not resize screen"
android:textOn="Keyboard resizes screen" />
<TextView <TextView
android:id="@+id/textView7" android:id="@+id/textView7"
android:layout_marginBottom="10dp" android:layout_marginBottom="10dp"

View file

@ -39,6 +39,7 @@ public class LauncherActivity extends Activity {
public final static int sdk = Integer.valueOf(Build.VERSION.SDK); public final static int sdk = Integer.valueOf(Build.VERSION.SDK);
static EditText cmdArgs; static EditText cmdArgs;
static ToggleButton useVolume; static ToggleButton useVolume;
static ToggleButton resizeWorkaround;
static EditText resPath; static EditText resPath;
static SharedPreferences mPref; static SharedPreferences mPref;
static Spinner pixelSpinner; static Spinner pixelSpinner;
@ -78,8 +79,8 @@ public class LauncherActivity extends Activity {
"32 bit (RGBA8888)", "32 bit (RGBA8888)",
"24 bit (RGB888)", "24 bit (RGB888)",
"16 bit (RGB565)", "16 bit (RGB565)",
"15 bit (RGBA5551)", "16 bit (RGBA5551)",
"12 bit (RGBA4444)", "16 bit (RGBA4444)",
"8 bit (RGB332)" "8 bit (RGB332)"
}; };
pixelSpinner = (Spinner) findViewById(R.id.pixelSpinner); pixelSpinner = (Spinner) findViewById(R.id.pixelSpinner);
@ -119,6 +120,8 @@ public class LauncherActivity extends Activity {
cmdArgs.setText(mPref.getString("argv","-dev 3 -log")); cmdArgs.setText(mPref.getString("argv","-dev 3 -log"));
useVolume = ( ToggleButton ) findViewById( R.id.useVolume ); useVolume = ( ToggleButton ) findViewById( R.id.useVolume );
useVolume.setChecked(mPref.getBoolean("usevolume",true)); useVolume.setChecked(mPref.getBoolean("usevolume",true));
resizeWorkaround = ( ToggleButton ) findViewById( R.id.enableResizeWorkaround );
resizeWorkaround.setChecked(mPref.getBoolean("enableResizeWorkaround",true));
resPath = ( EditText ) findViewById( R.id.cmdPath ); resPath = ( EditText ) findViewById( R.id.cmdPath );
tvResPath = ( TextView ) findViewById( R.id.textView_path ); tvResPath = ( TextView ) findViewById( R.id.textView_path );
updatePath(mPref.getString("basedir", getDefaultPath())); updatePath(mPref.getString("basedir", getDefaultPath()));
@ -150,6 +153,7 @@ public class LauncherActivity extends Activity {
editor.putBoolean("usevolume",useVolume.isChecked()); editor.putBoolean("usevolume",useVolume.isChecked());
editor.putString("basedir", resPath.getText().toString()); editor.putString("basedir", resPath.getText().toString());
editor.putInt("pixelformat", pixelSpinner.getSelectedItemPosition()); editor.putInt("pixelformat", pixelSpinner.getSelectedItemPosition());
editor.putBoolean("enableResizeWorkaround",resizeWorkaround.isChecked());
editor.commit(); editor.commit();
startActivity(intent); startActivity(intent);
} }

View file

@ -127,7 +127,8 @@ public class XashActivity extends Activity {
mPixelFormat = mPref.getInt("pixelformat", 0); mPixelFormat = mPref.getInt("pixelformat", 0);
mUseVolume = mPref.getBoolean("usevolume", false); mUseVolume = mPref.getBoolean("usevolume", false);
AndroidBug5497Workaround.assistActivity(this); if( mPref.getBoolean("enableResizeWorkaround", true) )
AndroidBug5497Workaround.assistActivity(this);
} }
// Events // Events

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.9 KiB

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.1 KiB

After

Width:  |  Height:  |  Size: 7.2 KiB