mirror of
https://github.com/badaix/snapcast.git
synced 2025-04-30 02:37:15 +02:00
Added dummy About activity
This commit is contained in:
parent
1058bf35ad
commit
25c86be11d
6 changed files with 46 additions and 2 deletions
|
@ -36,7 +36,15 @@
|
||||||
<activity
|
<activity
|
||||||
android:name=".ClientSettingsActivity"
|
android:name=".ClientSettingsActivity"
|
||||||
android:label="@string/title_activity_client_settings"
|
android:label="@string/title_activity_client_settings"
|
||||||
android:parentActivityName=".MainActivity" >
|
android:parentActivityName=".MainActivity">
|
||||||
|
<meta-data
|
||||||
|
android:name="android.support.PARENT_ACTIVITY"
|
||||||
|
android:value=".MainActivity" />
|
||||||
|
</activity>
|
||||||
|
<activity
|
||||||
|
android:name=".AboutActivity"
|
||||||
|
android:label="@string/title_activity_about"
|
||||||
|
android:parentActivityName=".MainActivity">
|
||||||
<meta-data
|
<meta-data
|
||||||
android:name="android.support.PARENT_ACTIVITY"
|
android:name="android.support.PARENT_ACTIVITY"
|
||||||
android:value=".MainActivity" />
|
android:value=".MainActivity" />
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
package de.badaix.snapcast;
|
||||||
|
|
||||||
|
import android.support.v7.app.AppCompatActivity;
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
public class AboutActivity extends AppCompatActivity {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.activity_about);
|
||||||
|
}
|
||||||
|
}
|
|
@ -160,6 +160,9 @@ public class MainActivity extends AppCompatActivity implements ClientInfoItem.Cl
|
||||||
} else if (id == R.id.action_refresh) {
|
} else if (id == R.id.action_refresh) {
|
||||||
if ((remoteControl != null) && remoteControl.isConnected())
|
if ((remoteControl != null) && remoteControl.isConnected())
|
||||||
remoteControl.getServerStatus();
|
remoteControl.getServerStatus();
|
||||||
|
} else if (id == R.id.action_about) {
|
||||||
|
Intent intent = new Intent(this, AboutActivity.class);
|
||||||
|
startActivity(intent);
|
||||||
}
|
}
|
||||||
|
|
||||||
return super.onOptionsItemSelected(item);
|
return super.onOptionsItemSelected(item);
|
||||||
|
|
12
android/Snapcast/src/main/res/layout/activity_about.xml
Normal file
12
android/Snapcast/src/main/res/layout/activity_about.xml
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:paddingBottom="@dimen/activity_vertical_margin"
|
||||||
|
android:paddingLeft="@dimen/activity_horizontal_margin"
|
||||||
|
android:paddingRight="@dimen/activity_horizontal_margin"
|
||||||
|
android:paddingTop="@dimen/activity_vertical_margin"
|
||||||
|
tools:context="de.badaix.snapcast.AboutActivity">
|
||||||
|
|
||||||
|
</RelativeLayout>
|
|
@ -13,6 +13,12 @@
|
||||||
android:orderInCategory="100"
|
android:orderInCategory="100"
|
||||||
android:title="@string/action_settings"
|
android:title="@string/action_settings"
|
||||||
app:showAsAction="never" /> -->
|
app:showAsAction="never" /> -->
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_about"
|
||||||
|
android:orderInCategory="100"
|
||||||
|
android:title="@string/action_about"
|
||||||
|
app:showAsAction="never" />
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_scan"
|
android:id="@+id/action_scan"
|
||||||
android:orderInCategory="100"
|
android:orderInCategory="100"
|
||||||
|
|
|
@ -28,5 +28,7 @@
|
||||||
<string name="action_play_stop">Play/Stop</string>
|
<string name="action_play_stop">Play/Stop</string>
|
||||||
<string name="client_deleted">Client %1$s deleted</string>
|
<string name="client_deleted">Client %1$s deleted</string>
|
||||||
<string name="undo_string">undo</string>
|
<string name="undo_string">undo</string>
|
||||||
|
<string name="action_about">About...</string>
|
||||||
|
<string name="title_activity_about">About</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue