launcher修改--修改launcher的屏幕数
首先,在Launcher.java代码中
修改这两段
static final int SCREEN_COUNT = 5; static final int DEFAULT_SCREEN = 2;//第一页是从0开始计数,这里是把第三个页面作为默认首页
然后选中项目,选择Search>File,输入defaultscreen勾选Selected Resources点击搜索,,会找到好几个结果,作相应的更改即可
<com.android.launcher2.DragLayer xmlns:android="http://schemas.android.com/apk/res/android" xmlns:launcher="http://schemas.android.com/apk/res/com.android.launcher" android:id="@+id/drag_layer" android:layout_width="match_parent" android:layout_height="match_parent"> <include layout="@layout/all_apps" /> <!-- The workspace contains 3 screens of cells --> <com.android.launcher2.Workspace android:id="@+id/workspace" android:layout_width="match_parent" android:layout_height="match_parent" android:scrollbars="horizontal" android:fadeScrollbars="true" launcher:defaultScreen="2"> <include android:id="@+id/cell1" layout="@layout/workspace_screen" /> <include android:id="@+id/cell2" layout="@layout/workspace_screen" /> <include android:id="@+id/cell3" layout="@layout/workspace_screen" /> <include android:id="@+id/cell4" layout="@layout/workspace_screen" /> <include android:id="@+id/cell5" layout="@layout/workspace_screen" /> </com.android.launcher2.Workspace>
相关推荐
liufangbaishi0 2020-09-23
xjp 2020-05-28
fengyeezju 2020-04-26
androidstudyroom 2011-02-16
yinbaoshiguang 2011-08-29
ThedakeLaugh 2011-08-15
ntfsformac 2011-09-30
longjing 2011-09-30
lookingFor 2015-03-25
yffhhffv 2015-03-24
小召的阳光地带 2015-03-23
jxnk 2015-03-23
ChainDestiny 2015-04-14
xz0mzq 2012-01-08
xiaozaq 2019-09-08
Swen 2012-04-18
Swen 2011-03-22
heshizui 2013-11-03
pengzhanxuan 2012-04-10