Changing the height and the minimum height of the toolbar in order to have a smooth design

This commit is contained in:
BGbaderguet 2020-11-08 18:15:23 +01:00
parent 2f85e69b3a
commit 115fe155b6

View File

@ -1,6 +1,7 @@
package fr.romanet.vj.apps.myweather; package fr.romanet.vj.apps.myweather;
import androidx.appcompat.app.AppCompatActivity; import androidx.appcompat.app.AppCompatActivity;
import androidx.appcompat.widget.Toolbar;
import android.os.Bundle; import android.os.Bundle;
@ -10,5 +11,9 @@ public class AddCity extends AppCompatActivity {
protected void onCreate(Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
setContentView(R.layout.add_city_page); setContentView(R.layout.add_city_page);
Toolbar toolbarAddCity = (Toolbar) findViewById(R.id.toolbarAddCity);
setSupportActionBar(toolbarAddCity);
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
getSupportActionBar().setDisplayShowHomeEnabled(true);
} }
} }