From: Gustavo Martin Morcuende Date: Thu, 1 Sep 2016 22:15:57 +0000 (+0200) Subject: A few improvements X-Git-Tag: weatherinformation-2.0~14 X-Git-Url: https://git.gumartinm.name/?a=commitdiff_plain;h=f0edcda3d76ab2db3449e60df8e69684b358da7f;p=AndroidWeatherInformation A few improvements --- diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/AboutActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/AboutActivity.java index 80d3709..6ef65d0 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/AboutActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/AboutActivity.java @@ -29,14 +29,13 @@ public class AboutActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); + this.setContentView(R.layout.weather_about); final ActionBar actionBar = this.getSupportActionBar(); actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE); actionBar.setDisplayHomeAsUpEnabled(true); actionBar.setDisplayShowHomeEnabled(true); actionBar.setIcon(R.drawable.ic_launcher); - - setContentView(R.layout.weather_about); } @Override diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/LicensesActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/LicensesActivity.java index 324d495..411723c 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/LicensesActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/LicensesActivity.java @@ -39,6 +39,7 @@ public class LicensesActivity extends AppCompatActivity { @Override public void onCreate(final Bundle savedInstanceState) { super.onCreate(savedInstanceState); + this.setContentView(R.layout.weather_licenses); final ActionBar actionBar = this.getSupportActionBar(); actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE); @@ -46,8 +47,6 @@ public class LicensesActivity extends AppCompatActivity { actionBar.setDisplayShowHomeEnabled(true); actionBar.setIcon(R.drawable.ic_launcher); - setContentView(R.layout.weather_licenses); - mWebView = (WebView) this.findViewById(R.id.weather_licenses); } diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java index 4bacd09..85090a9 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java @@ -15,7 +15,6 @@ */ package name.gumartinm.weather.information.activity; -import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.os.Bundle; diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/MapActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/MapActivity.java index 77f4306..8550807 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/MapActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/MapActivity.java @@ -71,14 +71,13 @@ public class MapActivity extends AppCompatActivity implements @Override protected void onCreate(final Bundle savedInstanceState) { super.onCreate(savedInstanceState); + this.setContentView(R.layout.weather_map); final ActionBar actionBar = this.getSupportActionBar(); actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE); actionBar.setDisplayHomeAsUpEnabled(true); actionBar.setDisplayShowHomeEnabled(true); actionBar.setIcon(R.drawable.ic_launcher); - - this.setContentView(R.layout.weather_map); // Acquire a reference to the system Location Manager this.mLocationManager = (LocationManager) this.getSystemService(Context.LOCATION_SERVICE); diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/SpecificActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/SpecificActivity.java index 8189d06..be25b0e 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/SpecificActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/SpecificActivity.java @@ -38,7 +38,6 @@ public class SpecificActivity extends AppCompatActivity { actionBar.setDisplayHomeAsUpEnabled(true); actionBar.setDisplayShowHomeEnabled(true); actionBar.setIcon(R.drawable.ic_launcher); - } @Override diff --git a/app/src/main/res/values-v11/styles.xml b/app/src/main/res/values-v11/styles.xml index 5e8e931..175d9eb 100644 --- a/app/src/main/res/values-v11/styles.xml +++ b/app/src/main/res/values-v11/styles.xml @@ -27,6 +27,7 @@