Skip to content

Commit

Permalink
Add About layout and rearrange the settings
Browse files Browse the repository at this point in the history
  • Loading branch information
abdelkader.sellami committed Aug 29, 2019
1 parent 16ad2a7 commit 27a57af
Show file tree
Hide file tree
Showing 13 changed files with 148 additions and 41 deletions.
2 changes: 1 addition & 1 deletion AndroidManifest-common.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
android:fullBackupContent="@xml/backupscheme"
android:hardwareAccelerated="true"
android:icon="@drawable/ic_launcher_home"
android:label="@string/derived_app_name"
android:label="@string/custom_app_name"
android:largeHeap="@bool/config_largeHeap"
android:restoreAnyVersion="true"
android:supportsRtl="true" >
Expand Down
2 changes: 1 addition & 1 deletion AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
android:fullBackupContent="@xml/backupscheme"
android:hardwareAccelerated="true"
android:icon="@drawable/ic_launcher_home"
android:label="@string/derived_app_name"
android:label="@string/custom_app_name"
android:theme="@style/AppTheme"
android:largeHeap="@bool/config_largeHeap"
android:restoreAnyVersion="true"
Expand Down
2 changes: 1 addition & 1 deletion go/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
android:fullBackupContent="@xml/backupscheme"
android:hardwareAccelerated="true"
android:icon="@drawable/ic_launcher_home"
android:label="@string/derived_app_name"
android:label="@string/custom_app_name"
android:theme="@style/AppTheme"
android:largeHeap="@bool/config_largeHeap"
android:restoreAnyVersion="true"
Expand Down
2 changes: 1 addition & 1 deletion quickstep/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
android:fullBackupContent="@xml/backupscheme"
android:hardwareAccelerated="true"
android:icon="@drawable/ic_launcher_home"
android:label="@string/derived_app_name"
android:label="@string/custom_app_name"
android:theme="@style/AppTheme"
android:largeHeap="@bool/config_largeHeap"
android:restoreAnyVersion="true"
Expand Down
29 changes: 9 additions & 20 deletions res/drawable-v26/ic_launcher_home.xml
Original file line number Diff line number Diff line change
@@ -1,21 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2017 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/icon_background" />
<foreground>
<bitmap android:src="@mipmap/ic_launcher_home_foreground"/>
</foreground>
</adaptive-icon>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M20 2H4c-1.1 0 -2 0.9 -2 2v16c0 1.1 0.9 2 2 2h16c1.1 0 2 -0.9 2 -2V4c0 -1.1 -0.9 -2 -2 -2zM8 20H4v-4h4v4zm0 -6H4v-4h4v4zm0 -6H4V4h4v4zm6 12h-4v-4h4v4zm0 -6h-4v-4h4v4zm0 -6h-4V4h4v4zm6 12h-4v-4h4v4zm0 -6h-4v-4h4v4zm0 -6h-4V4h4v4z"
android:fillColor="#4285F4" />
</vector>
10 changes: 10 additions & 0 deletions res/drawable/add_icons.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M4 6H2v14c0 1.1 0.9 2 2 2h14v-2H4V6zm16 -4H8c-1.1 0 -2 0.9 -2 2v12c0 1.1 0.9 2 2 2h12c1.1 0 2 -0.9 2 -2V4c0 -1.1 -0.9 -2 -2 -2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"
android:fillColor="#4285F4" />
</vector>
10 changes: 10 additions & 0 deletions res/drawable/app_info.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M12 21.35l-1.45 -1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41 0.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78 -3.4 6.86 -8.55 11.54L12 21.35z"
android:fillColor="#4285F4" />
</vector>
10 changes: 10 additions & 0 deletions res/drawable/homescreen_rotation.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M15.55 5.55L11 1v3.07C7.06 4.56 4 7.92 4 12s3.05 7.44 7 7.93v-2.02c-2.84 -0.48 -5 -2.94 -5 -5.91s2.16 -5.43 5 -5.91V10l4.55 -4.45zM19.93 11c-0.17 -1.39 -0.72 -2.73 -1.62 -3.89l-1.42 1.42c0.54 0.75 0.88 1.6 1.02 2.47h2.02zM13 17.9v2.02c1.39 -0.17 2.74 -0.71 3.9 -1.61l-1.44 -1.44c-0.75 0.54 -1.59 0.89 -2.46 1.03zm3.89 -2.42l1.42 1.41c0.9 -1.16 1.45 -2.5 1.62 -3.89h-2.02c-0.14 0.87 -0.48 1.72 -1.02 2.48z"
android:fillColor="#4285F4" />
</vector>
26 changes: 9 additions & 17 deletions res/drawable/ic_launcher_home.xml
Original file line number Diff line number Diff line change
@@ -1,18 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2017 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<bitmap
xmlns:android="http://schemas.android.com/apk/res/android"
android:src="@mipmap/ic_launcher_home" />
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M20 2H4c-1.1 0 -2 0.9 -2 2v16c0 1.1 0.9 2 2 2h16c1.1 0 2 -0.9 2 -2V4c0 -1.1 -0.9 -2 -2 -2zM8 20H4v-4h4v4zm0 -6H4v-4h4v4zm0 -6H4V4h4v4zm6 12h-4v-4h4v4zm0 -6h-4v-4h4v4zm0 -6h-4V4h4v4zm6 12h-4v-4h4v4zm0 -6h-4v-4h4v4zm0 -6h-4V4h4v4z"
android:fillColor="#4285F4" />
</vector>
10 changes: 10 additions & 0 deletions res/drawable/icon_shape.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M7 14c-1.66 0 -3 1.34 -3 3 0 1.31 -1.16 2 -2 2 0.92 1.22 2.49 2 4 2 2.21 0 4 -1.79 4 -4 0 -1.66 -1.34 -3 -3 -3zm13.71 -9.37l-1.34 -1.34c-0.39 -0.39 -1.02 -0.39 -1.41 0L9 12.25 11.75 15l8.96 -8.96c0.39 -0.39 0.39 -1.02 0 -1.41z"
android:fillColor="#4285F4" />
</vector>
10 changes: 10 additions & 0 deletions res/drawable/notifications_dots.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android" xmlns:aapt="http://schemas.android.com/aapt"
android:height="38dp"
android:width="38dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10 -4.49 10 -10S17.51 2 12 2zm0 18c-4.41 0 -8 -3.59 -8 -8s3.59 -8 8 -8 8 3.59 8 8 -3.59 8 -8 8zm3 -8c0 1.66 -1.34 3 -3 3s-3 -1.34 -3 -3 1.34 -3 3 -3 3 1.34 3 3z"
android:fillColor="#4285F4" />
</vector>
20 changes: 20 additions & 0 deletions res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -361,4 +361,24 @@

<string name="state_loading">Loading</string>

<!-- About -->
<string name="about_aosp_launcher">About</string>
<string name="about_aosp_launcher_us">AOSP Pure Launcher</string>
<string name="about_aosp_launcher_version">Version</string>
<string name="about_aosp_launcher_version_sum">1.0</string>
<string name="thanks">Thanks for</string>
<string name="sum_thanks">- Amir Zaidi (Rootless Launcher)\n- Lawnchair Launcher\n </string>
<string name="date">Build date</string>
<string name="sum_date">27/08/19</string>
<string name="sum_about_app_aosp_launcher">About this app, version, information</string>
<string name="developer_info_sum">Abdelkader Sellami</string>
<string name="developer_info">Developer Info</string>
<string name="app_base_title">Based On</string>
<string name="app_base_title_sum">Based On Pure AOSP Launcher3</string>

<string name="custom_app_name">AOSP Pure Launcher</string>

<string name="github_title">Github</string>
<string name="github_sum">AOSP Pure Launcher Project Github</string>

</resources>
56 changes: 56 additions & 0 deletions res/xml/launcher_preferences.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
<com.android.launcher3.views.ButtonPreference
android:key="pref_icon_badging"
android:title="@string/icon_badging_title"
android:icon="@drawable/notifications_dots"
android:persistent="false"
android:widgetLayout="@layout/notification_pref_warning" >
<intent android:action="android.settings.NOTIFICATION_SETTINGS">
Expand All @@ -40,13 +41,15 @@
android:key="pref_add_icon_to_home"
android:title="@string/auto_add_shortcuts_label"
android:summary="@string/auto_add_shortcuts_description"
android:icon="@drawable/add_icons"
android:defaultValue="true"
android:persistent="true" />

<SwitchPreference
android:key="pref_allowRotation"
android:title="@string/allow_rotation_title"
android:summary="@string/allow_rotation_desc"
android:icon="@drawable/homescreen_rotation"
android:defaultValue="@bool/allow_rotation"
android:persistent="true" />

Expand All @@ -57,6 +60,7 @@
android:entries="@array/icon_shape_override_paths_names"
android:entryValues="@array/icon_shape_override_paths_values"
android:defaultValue=""
android:icon="@drawable/icon_shape"
android:persistent="false" />

<ListPreference
Expand All @@ -66,6 +70,58 @@
android:entries="@array/icon_size_names"
android:entryValues="@array/icon_size_values"
android:defaultValue="average"
android:icon="@drawable/icon_shape"
android:persistent="true" />


<PreferenceCategory android:title="@string/about_aosp_launcher">
<PreferenceScreen
android:key="about_screen"
android:icon="@drawable/app_info"
android:summary="@string/sum_about_app_aosp_launcher"
android:title="@string/about_aosp_launcher_us">
<Preference
android:key="@string/developer_info"
android:title="@string/developer_info"
android:summary="@string/developer_info_sum"
android:persistent="false">
</Preference>
<Preference
android:key="@string/app_base_title"
android:title="@string/app_base_title"
android:summary="@string/app_base_title_sum"
android:persistent="false">
</Preference>
<Preference
android:title="@string/thanks"
android:summary="@string/sum_thanks" >
</Preference>
<Preference
android:key="@string/about_aosp_launcher_version"
android:title="@string/about_aosp_launcher_version"
android:summary="@string/about_aosp_launcher_version_sum"
android:persistent="false">
</Preference>
<Preference
android:title="@string/date"
android:summary="@string/sum_date" >
</Preference>
<Preference
android:title="@string/github_title"
android:summary="@string/github_sum">
<intent android:action="android.intent.action.VIEW"
android:data="https://github.com/islem19/AOSP-Pure-Launcher" />
</Preference>

<Preference
android:key="app_info"
android:title="@string/app_info_drop_target_label"
android:persistent="false">
<intent
android:action="android.settings.APPLICATION_DETAILS_SETTINGS"
android:data="package:com.android.launcher3" />
</Preference>
</PreferenceScreen>
</PreferenceCategory>

</PreferenceScreen>

0 comments on commit 27a57af

Please sign in to comment.