|
有没有同学跟我一样,感觉ct或者cb2的桌面太丑,还不如使用Launcher2呢,
怎么换成Launcher2,请参考修改默认Launcher,可是换成launcher2了,屏幕上下都有大块黑边,严重影响美观呀,看我给它动点小手术
cd packages/apps/Launcher2- diff --git a/packages/apps/Launcher2/res/layout-land/launcher.xml b/packages/apps/Launcher2/res/layout-land/launcher.xml
- index 051d8b2..5c81c21 100644
- --- a/packages/apps/Launcher2/res/layout-land/launcher.xml
- +++ b/packages/apps/Launcher2/res/layout-land/launcher.xml
- @@ -22,7 +22,7 @@
- android:id="@+id/launcher"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- - android:background="@drawable/workspace_bg">
- + >
- <com.android.launcher2.DragLayer
- android:id="@+id/drag_layer"
- @@ -118,4 +118,4 @@
- android:layout_height="match_parent"
- android:visibility="invisible" />
- </com.android.launcher2.DragLayer>
- -</FrameLayout>
- \ No newline at end of file
- +</FrameLayout>
- diff --git a/packages/apps/Launcher2/res/layout-port/launcher.xml b/packages/apps/Launcher2/res/layout-port/launcher.xml
- index 445c85e..4afc571 100644
- --- a/packages/apps/Launcher2/res/layout-port/launcher.xml
- +++ b/packages/apps/Launcher2/res/layout-port/launcher.xml
- @@ -22,14 +22,13 @@
- android:id="@+id/launcher"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- - android:background="@drawable/workspace_bg">
- + >
- <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:background="@drawable/workspace_bg"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:fitsSystemWindows="true">
- @@ -116,4 +115,4 @@
- android:layout_height="match_parent"
- android:visibility="invisible" />
- <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:background="@drawable/workspace_bg"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:fitsSystemWindows="true">
- @@ -116,4 +115,4 @@
- android:layout_height="match_parent"
- android:visibility="invisible" />
- </com.android.launcher2.DragLayer>
- -</FrameLayout>
- \ No newline at end of file
- +</FrameLayout>
- diff --git a/packages/apps/Launcher2/res/layout-sw720dp/launcher.xml b/packages/apps/Launcher2/res/layout-sw720dp/launcher.xml
- index 81a8f37..d0f8a6d 100644
- --- a/packages/apps/Launcher2/res/layout-sw720dp/launcher.xml
- +++ b/packages/apps/Launcher2/res/layout-sw720dp/launcher.xml
- @@ -22,14 +22,13 @@
- android:id="@+id/launcher"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- - android:background="@drawable/workspace_bg">
- + >
- <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:background="@drawable/workspace_bg"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:fitsSystemWindows="true">
- @@ -117,4 +116,4 @@
- android:layout_height="match_parent"
- android:visibility="invisible" />
- </com.android.launcher2.DragLayer>
- -</FrameLayout>
- \ No newline at end of file
- +</FrameLayout>
复制代码 总结下,就是把有渐变的背景去掉,还原成壁纸默认的着色。
修改完成后执行mm命令,在./out/target/product/sugar-cubietruck/system/app/目录下面就会生成Launcher2.apk,执行adb push ***/Launcher2.apk /system/app下面,就会发现黑边不见了。
|
|