不知不觉毕业2个半月了,在学校也学过java se,android,没做过啥项目,只是做过一些简单的demo,然而很明显企业需要的是项目经验,面试了几次虽然不多,处处碰壁,只想静下心来好好写写代码,想想基础来了工作自然就来了,男人嘛,就得不抛弃,从哪儿跌倒了从哪里爬起来,过去的时间已经过去了,尽力步入IT行业既然付出了为啥面试了几次失败了就放弃呢!这里用的开发工具是AndroidStudio前面对Eclipse算比较熟悉吧,开发工具度差不多,androidStudio是未来的开发工具,越来越流行了,
我个人的渣渣思想做的渣渣app,从界面出发
首先是布局界面也就是Activity_main.xml它的代码如下:
<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:background="@mipmap/skin_bg" android:orientation="vertical" tools:context=".MainActivity"> <!--第一行标题栏--> <TextView android:id="@+id/tv_title" android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" android:text="本地音乐库" android:textSize="25dp" android:textColor="#ffffff"/> <!--线性布局一个--> <LinearLayout android:id="@+id/control_layout" android:layout_width="match_parent" android:layout_height="65dp" android:layout_below="@id/tv_title" android:orientation="horizontal"> <Button android:id="@+id/btn_previous" android:layout_width="0dp" android:layout_height="match_parent" android:gravity="center" android:layout_weight="1" android:background="@mipmap/main_btn_previous" /> <Button android:id="@+id/btn_play_pause" android:layout_width="0dp" android:layout_height="match_parent" android:gravity="center" android:background="@mipmap/main_btn_pause" android:layout_weight="1" /> <!-- android:background="@mipmap/btn_shuffle--> <Button android:id="@+id/btn_next" android:layout_width="0dp" android:layout_height="match_parent" android:gravity="center" android:layout_weight="1" android:background="@mipmap/main_btn_next" /> </LinearLayout> <!--底部控制栏--> <RelativeLayout android:id="@+id/main_bottom_layout" android:layout_width="match_parent" android:layout_height="70dp" android:layout_alignParentBottom="true" android:layout_weight="1" > <LinearLayout android:id="@+id/main_bottom_click" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_toLeftOf="@+id/btn_main_bottom_detail" android:orientation="horizontal"> <ImageView android:id="@+id/main_bottom_image" android:layout_width="wrap_content" android:layout_height="match_parent" android:src="@mipmap/music_bottom" /> <LinearLayout android:id="@+id/main_bottom_v" android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_toRightOf="@+id/main_bottom_image" android:layout_toLeftOf="@+id/btn_main_bottom_detail" android:orientation="vertical" > <TextView android:id="@+id/tv_bottom_title" android:layout_width="wrap_content" android:layout_height="0dp" android:text="音乐的标题" android:textColor="#ffffff" android:layout_weight="1"/> <TextView android:id="@+id/tv_bottom_artist" android:layout_width="wrap_content" android:layout_height="0dp" android:textColor="#ffffff" android:text="音乐的歌手" android:layout_weight="1"/> <LinearLayout android:layout_width="wrap_content" android:layout_height="0dp" android:layout_weight="1" android:orientation="horizontal"> <TextView android:id="@+id/tv_bottom_currentTime" android:layout_width="wrap_content" android:layout_height="match_parent" android:text="当前时间" android:textColor="#ffffff" android:layout_weight="1"/> <TextView android:id="@+id/tv_botton_durationTime" android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_marginLeft="10dp" android:textColor="#ffffff" android:text="总时间" /> </LinearLayout> </LinearLayout> </LinearLayout> <Button android:id="@+id/btn_main_bottom_detail" android:layout_width="wrap_content" android:layout_height="match_parent" android:text="详细信息" android:textColor="#ffffff" android:layout_alignParentRight="true" /> </RelativeLayout> <ListView android:id="@+id/lv_musicList" android:layout_width="match_parent" android:layout_height="match_parent" android:focusable="true" android:layout_below="@+id/control_layout" android:layout_above="@+id/main_bottom_layout" > </ListView> </RelativeLayout>//andriodStudio图片显示如下