====================================== Press the water ripple effect
<?xml version= "1.0" encoding= "Utf-8"?>
<!--ripple Effect background--
<!--android:color= "@color/dark_brown" when pressed--
<ripple xmlns:android= "Http://schemas.android.com/apk/res/android"
Android:color= "Attr/colorprimary" >
<!--normal display colors--
<item>
<shape>
<!--background Color--
<solid android:color= "@color/white"/>
</shape>
</item>
</ripple>
=========================toolbar and slide view combined with ======================
toolbar = Findview (r.id.toolbar_id);
Drawerlayout = (drawerlayout) Findviewbyid (r.id.drawer_id);
Actionbardrawertoggle Toggle = new Actionbardrawertoggle (This,drawerlayout,toolbar,r.string.kai,r.string.guan) {
Executes when the menu is closed
@Override
public void ondrawerclosed (View drawerview) {
if (Itemdianji) {
Sowhort ();
Itemdianji = false;
}
}
};
Drawerlayout.setdrawerlistener (toggle);
<activity
Android:name= ". Activity. Mainactivity "
android:screenorientation= "Portrait"/>
<!--
Android:screenorientation= ""
Landscape horizontal Screen
Portrait vertical Screen
Sensor direction according to sensors
User Settings method
Behind follows the previous one in the activity stack
It's an estimate.
Android Learning Notes---water ripple effect