Skip to content

Commit ee20bc0

Browse files
committed
Changed style of the example app.
1 parent 70d728c commit ee20bc0

File tree

3 files changed

+7
-41
lines changed

3 files changed

+7
-41
lines changed

example/src/main/java/de/mrapp/android/dialog/example/MainActivity.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
import android.app.FragmentTransaction;
1919
import android.os.Bundle;
2020
import android.support.v7.app.AppCompatActivity;
21-
import android.support.v7.widget.Toolbar;
2221

2322
/**
2423
* The main activity of the example app.
@@ -27,14 +26,6 @@
2726
*/
2827
public class MainActivity extends AppCompatActivity {
2928

30-
/**
31-
* Initializes the activity's toolbar.
32-
*/
33-
private void initializeToolbar() {
34-
Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
35-
setSupportActionBar(toolbar);
36-
}
37-
3829
/**
3930
* Shows the preference fragment, which contains the activity's content.
4031
*/
@@ -49,7 +40,6 @@ private void showPreferenceFragment() {
4940
protected final void onCreate(final Bundle savedInstanceState) {
5041
super.onCreate(savedInstanceState);
5142
setContentView(R.layout.activity_main);
52-
initializeToolbar();
5343
showPreferenceFragment();
5444
}
5545

example/src/main/res/layout/activity_main.xml

Lines changed: 5 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,8 @@ General Public License for more details.
1414
You should have received a copy of the GNU Lesser General Public License along with this program. If
1515
not, see <http://www.gnu.org/licenses/>.
1616
-->
17-
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
18-
xmlns:app="http://schemas.android.com/apk/res-auto"
19-
android:layout_width="match_parent"
20-
android:layout_height="match_parent"
21-
android:orientation="vertical">
22-
23-
<android.support.v7.widget.Toolbar
24-
android:id="@+id/toolbar"
25-
android:layout_width="match_parent"
26-
android:layout_height="?android:attr/actionBarSize"
27-
android:background="?attr/colorPrimary"
28-
app:popupTheme="@style/ToolbarPopupTheme"
29-
app:theme="@style/ToolbarTheme"/>
30-
31-
<RelativeLayout
32-
android:id="@+id/fragment"
33-
android:layout_width="match_parent"
34-
android:layout_height="0dp"
35-
android:layout_weight="1"/>
36-
37-
</LinearLayout>
17+
<RelativeLayout
18+
android:id="@+id/fragment"
19+
xmlns:android="http://schemas.android.com/apk/res/android"
20+
android:layout_width="match_parent"
21+
android:layout_height="match_parent"/>

example/src/main/res/values/styles.xml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,10 @@ not, see <http://www.gnu.org/licenses/>.
1616
-->
1717
<resources>
1818

19-
<style name="AppTheme" parent="@style/Theme.AppCompat.Light.NoActionBar">
19+
<style name="AppTheme" parent="@style/Theme.AppCompat.Light.DarkActionBar">
2020
<item name="colorPrimary">#ffd64937</item>
21-
<item name="colorPrimaryDark">#ffd64937</item>
21+
<item name="colorPrimaryDark">#ffbb4030</item>
2222
<item name="colorAccent">#ffd64937</item>
2323
</style>
2424

25-
<style name="ToolbarTheme" parent="@style/Theme.AppCompat.Light.NoActionBar">
26-
<item name="colorPrimary">#ffd64937</item>
27-
<item name="android:textColorPrimary">@color/abc_primary_text_material_dark</item>
28-
<item name="android:textColorSecondary">@color/abc_secondary_text_material_dark</item>
29-
</style>
30-
31-
<style name="ToolbarPopupTheme" parent="@style/Theme.AppCompat.Light.NoActionBar"/>
32-
3325
</resources>

0 commit comments

Comments
 (0)