├── app ├── .gitignore ├── release │ ├── preview.png │ └── output.json ├── src │ ├── main │ │ ├── ic_launcher-web.png │ │ ├── res │ │ │ ├── drawable-xhdpi │ │ │ │ ├── wifi_on.png │ │ │ │ ├── wifi_off.png │ │ │ │ ├── guide_last.png │ │ │ │ ├── brightness_off.png │ │ │ │ ├── brightness_on.png │ │ │ │ ├── close_unclick.png │ │ │ │ ├── ic_onekeylock.png │ │ │ │ ├── ic_visibility.png │ │ │ │ ├── setting_wifi1.png │ │ │ │ ├── setting_wifi2.png │ │ │ │ ├── setting_wifi3.png │ │ │ │ ├── setting_wifi4.png │ │ │ │ ├── ic_visibility_off.png │ │ │ │ ├── smartbar_delete.png │ │ │ │ ├── drop_down_brightness.png │ │ │ │ ├── system_setting_settings.png │ │ │ │ └── navibar_icon_settings_highlight.png │ │ │ ├── drawable-hdpi │ │ │ │ ├── ic_apk_box.png │ │ │ │ ├── ic_pdf_box.png │ │ │ │ ├── ic_zip_box.png │ │ │ │ ├── ic_excel_box.png │ │ │ │ ├── ic_image_box.png │ │ │ │ ├── ic_music_box.png │ │ │ │ ├── ic_video_box.png │ │ │ │ ├── ic_visibility.png │ │ │ │ ├── ic_word_box.png │ │ │ │ ├── ic_document_box.png │ │ │ │ ├── ic_drawing_box.png │ │ │ │ ├── ic_certificate_box.png │ │ │ │ ├── ic_file_gray_116dp.png │ │ │ │ ├── ic_powerpoint_box.png │ │ │ │ ├── ic_visibility_off.png │ │ │ │ └── ic_folder_gray_48dp.png │ │ │ ├── mipmap-hdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-mdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── file_manager.png │ │ │ ├── drawable-mdpi │ │ │ │ ├── ic_visibility.png │ │ │ │ └── ic_visibility_off.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-xxhdpi │ │ │ │ ├── ic_visibility.png │ │ │ │ └── ic_visibility_off.png │ │ │ ├── drawable-xxxhdpi │ │ │ │ ├── ic_visibility.png │ │ │ │ └── ic_visibility_off.png │ │ │ ├── values-xhdpi │ │ │ │ └── dimens.xml │ │ │ ├── xml │ │ │ │ ├── filepath.xml │ │ │ │ └── lock.xml │ │ │ ├── drawable │ │ │ │ ├── border.xml │ │ │ │ ├── app_visible_status.xml │ │ │ │ ├── progress_thumb_drawable.xml │ │ │ │ ├── border_half_white_1dp.xml │ │ │ │ ├── app_item_final.xml │ │ │ │ ├── ic_more_vert_black_24dp.xml │ │ │ │ ├── app_item_normal.xml │ │ │ │ ├── app_item_right.xml │ │ │ │ ├── app_item_bottom.xml │ │ │ │ └── progress_style.xml │ │ │ ├── values │ │ │ │ ├── colors.xml │ │ │ │ ├── attrs.xml │ │ │ │ ├── dimens.xml │ │ │ │ ├── arrays.xml │ │ │ │ ├── styles.xml │ │ │ │ └── strings.xml │ │ │ ├── values-w820dp │ │ │ │ └── dimens.xml │ │ │ ├── values-pl │ │ │ │ ├── arrays.xml │ │ │ │ └── strings.xml │ │ │ ├── values-zh │ │ │ │ ├── arrays.xml │ │ │ │ └── strings.xml │ │ │ ├── layout │ │ │ │ ├── item_file.xml │ │ │ │ ├── launcher_item.xml │ │ │ │ ├── activity_file_manager.xml │ │ │ │ ├── launcher_activity.xml │ │ │ │ └── activity_setting.xml │ │ │ └── values-ko │ │ │ │ └── strings.xml │ │ ├── java │ │ │ └── cn │ │ │ │ └── modificator │ │ │ │ └── launcher │ │ │ │ ├── App.java │ │ │ │ ├── model │ │ │ │ ├── AdminReceiver.java │ │ │ │ ├── ObservableFloat.java │ │ │ │ ├── HomeEntranceService.java │ │ │ │ ├── AppDataCenter.java │ │ │ │ └── WifiControl.java │ │ │ │ ├── AppManagerFragment.java │ │ │ │ ├── widgets │ │ │ │ ├── ObserverFontTextView.java │ │ │ │ ├── RatioImageView.java │ │ │ │ └── BatteryView.java │ │ │ │ ├── ftpservice │ │ │ │ ├── FTPReceiver.java │ │ │ │ └── FTPService.java │ │ │ │ ├── AboutDialog.java │ │ │ │ ├── Utils.java │ │ │ │ ├── CrashDetailPage.java │ │ │ │ ├── Config.java │ │ │ │ ├── CrashCapture.java │ │ │ │ ├── SettingFramgent.java │ │ │ │ └── Launcher.java │ │ └── AndroidManifest.xml │ ├── libs │ │ └── yotadevice_sdk-3.7.12.jar │ ├── epd │ │ └── AndroidManifest.xml │ └── home │ │ └── AndroidManifest.xml ├── proguard-rules.pro └── build.gradle ├── settings.gradle ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── README.md ├── .gitignore ├── CHANGELOG.md ├── gradle.properties ├── gradlew.bat ├── gradlew └── LICENSE /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /app/release/preview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/release/preview.png -------------------------------------------------------------------------------- /app/src/main/ic_launcher-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/ic_launcher-web.png -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /app/src/libs/yotadevice_sdk-3.7.12.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/libs/yotadevice_sdk-3.7.12.jar -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/wifi_on.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/wifi_on.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_apk_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_apk_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_pdf_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_pdf_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_zip_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_zip_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/wifi_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/wifi_off.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_excel_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_excel_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_image_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_image_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_music_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_music_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_video_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_video_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_visibility.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_visibility.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_word_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_word_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_visibility.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-mdpi/ic_visibility.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/guide_last.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/guide_last.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/file_manager.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-xhdpi/file_manager.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_document_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_document_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_drawing_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_drawing_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/brightness_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/brightness_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/brightness_on.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/brightness_on.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/close_unclick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/close_unclick.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_onekeylock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/ic_onekeylock.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_visibility.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/ic_visibility.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/setting_wifi1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/setting_wifi1.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/setting_wifi2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/setting_wifi2.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/setting_wifi3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/setting_wifi3.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/setting_wifi4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/setting_wifi4.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_visibility.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xxhdpi/ic_visibility.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_certificate_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_certificate_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_file_gray_116dp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_file_gray_116dp.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_powerpoint_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_powerpoint_box.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_visibility_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_visibility_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_visibility_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-mdpi/ic_visibility_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_visibility_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/ic_visibility_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/smartbar_delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/smartbar_delete.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_visibility.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xxxhdpi/ic_visibility.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_folder_gray_48dp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-hdpi/ic_folder_gray_48dp.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_visibility_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xxhdpi/ic_visibility_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxxhdpi/ic_visibility_off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xxxhdpi/ic_visibility_off.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/drop_down_brightness.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/drop_down_brightness.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/system_setting_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/system_setting_settings.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/navibar_icon_settings_highlight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Modificator/E-Ink-Launcher/HEAD/app/src/main/res/drawable-xhdpi/navibar_icon_settings_highlight.png -------------------------------------------------------------------------------- /app/src/main/res/values-xhdpi/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 14sp 4 | 45dp 5 | -------------------------------------------------------------------------------- /app/src/main/res/xml/filepath.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | -------------------------------------------------------------------------------- /app/release/output.json: -------------------------------------------------------------------------------- 1 | [{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":23,"versionName":"0.1.8.1","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Sat Dec 28 21:12:43 CST 2019 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-all.zip 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_visible_status.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/progress_thumb_drawable.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 7 | 8 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## E-Ink Launcher 2 | 3 | `E-Ink Launcher` is an Android launcher for Electronic paper book 4 | 5 | this verison is support end,new version in branch [master](https://github.com/Modificator/E-Ink-Launcher) 6 | 7 | join telegram group https://t.me/EInkLauncher 8 | 9 | ![E-Ink Launcher](app/release/preview.png) 10 | -------------------------------------------------------------------------------- /app/src/main/res/xml/lock.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/App.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher; 2 | 3 | import android.app.Application; 4 | 5 | public class App extends Application { 6 | @Override 7 | public void onCreate() { 8 | super.onCreate(); 9 | CrashCapture.getInstance().init(this, 1, Launcher.class); 10 | } 11 | 12 | 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | #ffffffff 7 | #000000 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/model/AdminReceiver.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.model; 2 | 3 | import android.app.admin.DeviceAdminReceiver; 4 | 5 | /** 6 | * Created by Modificator 7 | * time: 16/12/3.下午2:49 8 | * des:create file and achieve model 9 | */ 10 | 11 | public class AdminReceiver extends DeviceAdminReceiver { 12 | } 13 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | *.apk 10 | projectFilesBackup 11 | /.idea/sonarlint/issuestore 12 | .idea 13 | config.gradle 14 | KeyStore.key 15 | release/output.json 16 | *__gen.go 17 | *__ignore.go 18 | *.swp 19 | *.swo 20 | ~i_* 21 | ig_* 22 | zzzig_* 23 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## 0.1.8.6 2 | - fix custom wifi icon failed 3 | - one key lock crash 4 | --------- 5 | 6 | ## 0.1.8.5 7 | - fix no custom wifi icon crash 8 | --------- 9 | 10 | ## 0.1.8.4 11 | - fix some devices can not show full setting 12 | - lock screen icon name:`E-ink_Launcher.Lock.png` 13 | - wifi icon name:`E-ink_Launcher.WifiOn.png` `E-ink_Launcher.WifiOff.png` -------------------------------------------------------------------------------- /app/src/main/res/values-w820dp/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 64dp 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/border_half_white_1dp.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/values/attrs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16dp 4 | 16dp 5 | 6 | 7 | 18sp 8 | 55dp 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_item_final.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_more_vert_black_24dp.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_item_normal.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_item_right.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/values-pl/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 2 5 | 3 6 | 4 7 | 5 8 | 6 9 | 7 10 | 8 11 | 9 12 | 10 13 | 14 | 15 | 2 ikony 16 | 3 ikony 17 | 4 ikony 18 | 5 ikon 19 | 6 ikon 20 | 7 ikon 21 | 8 ikon 22 | 9 ikon 23 | 10 ikon 24 | 25 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_item_bottom.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/epd/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 9 | 10 | 11 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/AppManagerFragment.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher; 2 | 3 | import android.app.Fragment; 4 | import android.os.Bundle; 5 | 6 | import androidx.annotation.Nullable; 7 | 8 | import android.view.LayoutInflater; 9 | import android.view.View; 10 | import android.view.ViewGroup; 11 | 12 | /** 13 | * Created by Modificator 14 | * time: 16/12/28.下午11:24 15 | * des:create file and achieve model 16 | */ 17 | 18 | public class AppManagerFragment extends Fragment { 19 | @Nullable 20 | @Override 21 | public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, Bundle savedInstanceState) { 22 | return super.onCreateView(inflater, container, savedInstanceState); 23 | } 24 | 25 | @Override 26 | public void onActivityCreated(@Nullable Bundle savedInstanceState) { 27 | super.onActivityCreated(savedInstanceState); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /app/src/main/res/values-zh/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 2 5 | 3 6 | 4 7 | 5 8 | 6 9 | 7 10 | 8 11 | 9 12 | 10 13 | 14 | 15 | 2个 16 | 3个 17 | 4个 18 | 5个 19 | 6个 20 | 7个 21 | 8个 22 | 9个 23 | 10个 24 | 25 | 26 | 隐藏 27 | 一行 28 | 两行 29 | 不限制 30 | 31 | -------------------------------------------------------------------------------- /app/src/main/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 2 5 | 3 6 | 4 7 | 5 8 | 6 9 | 7 10 | 8 11 | 9 12 | 10 13 | 14 | 15 | 2 items 16 | 3 items 17 | 4 items 18 | 5 items 19 | 6 items 20 | 7 items 21 | 8 items 22 | 9 items 23 | 10 items 24 | 25 | 26 | hide 27 | 1 line 28 | 2 line 29 | no limit 30 | 31 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/progress_style.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/widgets/ObserverFontTextView.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.widgets; 2 | 3 | import android.content.Context; 4 | 5 | import androidx.annotation.Nullable; 6 | 7 | import android.util.AttributeSet; 8 | import android.util.TypedValue; 9 | import android.widget.TextView; 10 | 11 | import java.util.Observable; 12 | import java.util.Observer; 13 | 14 | /** 15 | * Created by Modificator 16 | * time: 16/12/3.上午2:03 17 | * des:create file and achieve model 18 | */ 19 | 20 | public class ObserverFontTextView extends TextView implements Observer { 21 | public ObserverFontTextView(Context context) { 22 | super(context); 23 | } 24 | 25 | public ObserverFontTextView(Context context, @Nullable AttributeSet attrs) { 26 | super(context, attrs); 27 | } 28 | 29 | public ObserverFontTextView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) { 30 | super(context, attrs, defStyleAttr); 31 | } 32 | 33 | @Override 34 | public void update(Observable o, Object arg) { 35 | setTextSize(TypedValue.COMPLEX_UNIT_SP, (Float) arg); 36 | // requestLayout(); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | ## Project-wide Gradle settings. 2 | # 3 | # For more details on how to configure your build environment visit 4 | # http://www.gradle.org/docs/current/userguide/build_environment.html 5 | # 6 | # Specifies the JVM arguments used for the daemon process. 7 | # The setting is particularly useful for tweaking memory settings. 8 | # Default value: -Xmx1024m -XX:MaxPermSize=256m 9 | android.defaults.buildfeatures.buildconfig=true 10 | android.enableJetifier=true 11 | android.nonFinalResIds=false 12 | android.nonTransitiveRClass=false 13 | android.useAndroidX=true 14 | org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 15 | # 16 | # When configured, Gradle will run in incubating parallel mode. 17 | # This option should only be used with decoupled projects. More details, visit 18 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 19 | # org.gradle.parallel=true 20 | #Fri Dec 16 23:55:35 CST 2016 21 | #systemProp.https.proxyPort=1080 22 | #systemProp.http.proxyHost=127.0.0.1 23 | #systemProp.https.proxyHost=127.0.0.1 24 | #systemProp.http.proxyPort=1080 25 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/ftpservice/FTPReceiver.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.ftpservice; 2 | 3 | /** 4 | * Created by yashwanthreddyg on 09-06-2016. 5 | */ 6 | 7 | import android.content.BroadcastReceiver; 8 | import android.content.Context; 9 | import android.content.Intent; 10 | import android.util.Log; 11 | 12 | public class FTPReceiver extends BroadcastReceiver { 13 | 14 | static final String TAG = FTPReceiver.class.getSimpleName(); 15 | 16 | @Override 17 | public void onReceive(Context context, Intent intent) { 18 | Log.v(TAG, "Received: " + intent.getAction()); 19 | 20 | try { 21 | if (intent.getAction().equals(FTPService.ACTION_START_FTPSERVER)) { 22 | Intent serverService = new Intent(context, FTPService.class); 23 | if (!FTPService.isRunning()) { 24 | context.startService(serverService); 25 | } 26 | } else if (intent.getAction().equals(FTPService.ACTION_STOP_FTPSERVER)) { 27 | Intent serverService = new Intent(context, FTPService.class); 28 | context.stopService(serverService); 29 | } 30 | } catch (Exception e) { 31 | Log.e(TAG, "Failed to start/stop on intent " + e.getMessage()); 32 | } 33 | } 34 | 35 | 36 | } 37 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /home/mod/Android/Sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | 19 | -keep public class cn.modificator.launcher.R$*{ 20 | public static final int *; 21 | } 22 | #-keep class org.apache.** {*;} 23 | #-keep interface org.apache.** {*;} 24 | #-dontwarn org.apache.** 25 | #-dontwarn org.slf4j.** 26 | 27 | -keeppackagenames doNotKeepAThing 28 | -renamesourcefileattribute SourceFile 29 | -keepattributes LineNumberTable,SourceFile 30 | 31 | -repackageclasses '' 32 | 33 | -optimizationpasses 10 34 | 35 | -dontwarn org.slf4j.impl.StaticLoggerBinder 36 | -dontwarn org.slf4j.impl.StaticMDCBinder -------------------------------------------------------------------------------- /app/src/main/res/layout/item_file.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 14 | 15 | 23 | 24 | 32 | 33 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /app/src/home/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 15 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/model/ObservableFloat.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.model; 2 | 3 | import android.os.Parcel; 4 | import android.os.Parcelable; 5 | 6 | import java.io.Serializable; 7 | import java.util.Observable; 8 | 9 | /** 10 | * Created by Modificator 11 | * time: 16/12/3.上午2:00 12 | * des:create file and achieve model 13 | */ 14 | 15 | public class ObservableFloat extends Observable implements Parcelable, Serializable { 16 | static final long serialVersionUID = 1L; 17 | private float mValue; 18 | 19 | public ObservableFloat(float mValue) { 20 | this.mValue = mValue; 21 | } 22 | 23 | public ObservableFloat() { 24 | } 25 | 26 | public float get() { 27 | return mValue; 28 | } 29 | 30 | public void set(float value) { 31 | if (mValue != value) 32 | this.mValue = value; 33 | notifyObservers(mValue); 34 | setChanged(); 35 | } 36 | 37 | @Override 38 | public int describeContents() { 39 | return 0; 40 | } 41 | 42 | @Override 43 | public void writeToParcel(Parcel dest, int flags) { 44 | dest.writeFloat(mValue); 45 | } 46 | 47 | public static final Parcelable.Creator CREATOR 48 | = new Parcelable.Creator() { 49 | 50 | @Override 51 | public ObservableFloat createFromParcel(Parcel source) { 52 | return new ObservableFloat(source.readFloat()); 53 | } 54 | 55 | @Override 56 | public ObservableFloat[] newArray(int size) { 57 | return new ObservableFloat[size]; 58 | } 59 | }; 60 | } 61 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 21 | 22 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/model/HomeEntranceService.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.model; 2 | 3 | import android.app.Notification; 4 | import android.app.NotificationChannel; 5 | import android.app.NotificationManager; 6 | import android.app.PendingIntent; 7 | import android.app.Service; 8 | import android.content.Context; 9 | import android.content.Intent; 10 | import android.os.Build; 11 | import android.os.IBinder; 12 | 13 | import cn.modificator.launcher.Launcher; 14 | import cn.modificator.launcher.R; 15 | 16 | public class HomeEntranceService extends Service { 17 | 18 | public static final String HomeEntranceChannelId = "Back to Launcher"; 19 | public static final String HomeEntranceChannelName = "Back to Launcher Notification"; 20 | 21 | @Override 22 | public void onCreate() { 23 | super.onCreate(); 24 | if (Build.VERSION.SDK_INT>=26){ 25 | NotificationManager nm = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE); 26 | if (nm != null) { 27 | nm.createNotificationChannel(new NotificationChannel(HomeEntranceChannelId,HomeEntranceChannelName,NotificationManager.IMPORTANCE_LOW)); 28 | } 29 | } 30 | 31 | Notification.Builder builder; 32 | if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) { 33 | builder = new Notification.Builder(this,HomeEntranceChannelId); 34 | }else{ 35 | builder = new Notification.Builder(this); 36 | } 37 | 38 | startForeground(1, builder 39 | .setWhen(System.currentTimeMillis()) 40 | .setContentTitle(getString(R.string.notification_click_back_launcher)) 41 | .setContentIntent(PendingIntent.getActivity(this,10,new Intent(this, Launcher.class),Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED)) 42 | .setSmallIcon(R.mipmap.ic_launcher) 43 | .getNotification() 44 | ); 45 | } 46 | 47 | @Override 48 | public int onStartCommand(Intent intent, int flags, int startId) { 49 | return START_STICKY; 50 | } 51 | 52 | @Override 53 | public IBinder onBind(Intent intent) { 54 | return null; 55 | } 56 | 57 | @Override 58 | public void onDestroy() { 59 | Intent thisService = new Intent(this,HomeEntranceService.class); 60 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { 61 | startForegroundService(thisService); 62 | }else{ 63 | startService(thisService); 64 | } 65 | super.onDestroy(); 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 12 | set DEFAULT_JVM_OPTS= 13 | 14 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | set CMD_LINE_ARGS=%* 63 | goto execute 64 | 65 | :4NT_args 66 | @rem Get arguments from the 4NT Shell from JP Software 67 | set CMD_LINE_ARGS=%$ 68 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | //noinspection GradleDynamicVersion 2 | apply plugin: 'com.android.application' 3 | //apply plugin: 'com.jakewharton.hugo' 4 | apply from: '../config.gradle' 5 | 6 | android { 7 | namespace 'cn.modificator.launcher' 8 | signingConfigs { 9 | config { 10 | keyAlias release.keyAlias 11 | keyPassword release.keyPassword 12 | storeFile release.storeFile 13 | storePassword release.storePassword 14 | } 15 | } 16 | compileSdkVersion 31 17 | defaultConfig { 18 | applicationId "cn.modificator.launcher" 19 | minSdkVersion 14 20 | targetSdkVersion 31 21 | versionCode 30 22 | versionName "0.1.8.6" 23 | signingConfig signingConfigs.config 24 | } 25 | buildTypes { 26 | release { 27 | debuggable false 28 | zipAlignEnabled true 29 | minifyEnabled true 30 | shrinkResources true 31 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 32 | signingConfig signingConfigs.config 33 | } 34 | debug { 35 | debuggable true 36 | zipAlignEnabled true 37 | minifyEnabled false 38 | shrinkResources false 39 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 40 | signingConfig signingConfigs.config 41 | } 42 | } 43 | 44 | flavorDimensions "screen" 45 | productFlavors { 46 | home{ 47 | dimension "screen" 48 | } 49 | epd{ 50 | dimension "screen" 51 | } 52 | } 53 | packagingOptions { 54 | jniLibs { 55 | excludes += ['META-INF/androidx*', 'META-INF/spring*', 'META-INF/proguard/*'] 56 | } 57 | resources { 58 | excludes += ['proguard-project.txt', 'project.properties', 'META-INF/LICENSE.txt', 'META-INF/LICENSE', 'META-INF/NOTICE.txt', 'META-INF/NOTICE', 'META-INF/DEPENDENCIES.txt', 'META-INF/DEPENDENCIES', 'META-INF/androidx*', 'META-INF/spring*', 'META-INF/proguard/*'] 59 | } 60 | } 61 | lint { 62 | abortOnError false 63 | checkReleaseBuilds false 64 | } 65 | } 66 | 67 | dependencies { 68 | // implementation fileTree(include: ['*.jar'], dir: 'libs') 69 | implementation 'androidx.core:core:1.7.0' 70 | implementation 'org.apache.ftpserver:ftplet-api:1.1.0' 71 | implementation 'org.apache.ftpserver:ftpserver-core:1.1.0' 72 | //can't connect http://fw.ydevices.com/maven 73 | // compileOnly files('src/libs/yotadevice_sdk-3.7.12.jar') 74 | } 75 | /* 76 | android.applicationVariants.all { variant -> 77 | variant.outputs.all { 78 | outputFileName = "E-Ink Launcher_${variant.versionName}.apk" 79 | } 80 | }*/ 81 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/widgets/RatioImageView.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.widgets; 2 | 3 | import android.content.Context; 4 | import android.content.res.TypedArray; 5 | import android.util.AttributeSet; 6 | import android.view.View; 7 | import android.widget.ImageView; 8 | 9 | import cn.modificator.launcher.R; 10 | 11 | /** 12 | * Created by mod on 15-10-30. 13 | */ 14 | public class RatioImageView extends ImageView { 15 | 16 | /** 17 | * 以哪边为参考,默认为宽 18 | */ 19 | ReferenceType reference = ReferenceType.WIDTH; 20 | /** 21 | * 宽的比例 22 | */ 23 | double ratioWidth = 1; 24 | /** 25 | * 高的比例 26 | */ 27 | double ratioHeight = 1; 28 | 29 | public enum ReferenceType { 30 | WIDTH, 31 | ReferenceType, HEIGHT 32 | } 33 | 34 | public RatioImageView(Context context) { 35 | super(context); 36 | } 37 | 38 | public RatioImageView(Context context, AttributeSet attrs) { 39 | super(context, attrs); 40 | TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.RatioLayout, 0, 0); 41 | //获取参考边 42 | reference = typedArray.getInt(R.styleable.RatioLayout_reference, 0) == 0 ? ReferenceType.WIDTH : ReferenceType.HEIGHT; 43 | //获取高比例 44 | ratioHeight = typedArray.getFloat(R.styleable.RatioLayout_ratioHeight, 1); 45 | //获取宽比例 46 | ratioWidth = typedArray.getFloat(R.styleable.RatioLayout_ratioWidth, 1); 47 | typedArray.recycle(); 48 | } 49 | 50 | public RatioImageView(Context context, AttributeSet attrs, int defStyleAttr) { 51 | super(context, attrs, defStyleAttr); 52 | TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.RatioLayout, defStyleAttr, 0); 53 | //获取参考边 54 | reference = typedArray.getInt(R.styleable.RatioLayout_reference, 0) == 0 ? ReferenceType.WIDTH : ReferenceType.HEIGHT; 55 | //获取高比例 56 | ratioHeight = typedArray.getFloat(R.styleable.RatioLayout_ratioHeight, 1); 57 | //获取宽比例 58 | ratioWidth = typedArray.getFloat(R.styleable.RatioLayout_ratioWidth, 1); 59 | typedArray.recycle(); 60 | } 61 | 62 | @Override 63 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { 64 | /** 65 | * 如果以宽慰基准边则宽不变,高按比例得出具体数值,反之亦然 66 | */ 67 | setMeasuredDimension(View.getDefaultSize(0, reference == ReferenceType.WIDTH ? widthMeasureSpec : 68 | (int) (heightMeasureSpec / ratioHeight * ratioWidth)), 69 | View.getDefaultSize(0, reference == ReferenceType.HEIGHT ? heightMeasureSpec : 70 | (int) (widthMeasureSpec / ratioWidth * ratioHeight))); 71 | 72 | int childSpec = reference == ReferenceType.WIDTH ? getMeasuredWidth() : getMeasuredHeight(); 73 | /** 74 | * 获取非基准边的尺寸 75 | */ 76 | int measureSpec = reference == ReferenceType.HEIGHT ? View.MeasureSpec.makeMeasureSpec( 77 | (int) (childSpec / ratioHeight * ratioWidth), View.MeasureSpec.EXACTLY) : 78 | View.MeasureSpec.makeMeasureSpec( 79 | (int) (childSpec / ratioWidth * ratioHeight), View.MeasureSpec.EXACTLY); 80 | 81 | super.onMeasure(reference == ReferenceType.WIDTH ? widthMeasureSpec : measureSpec, reference == ReferenceType.HEIGHT ? heightMeasureSpec : measureSpec); 82 | } 83 | } 84 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 29 | 30 | 34 | 35 | 38 | 41 | 42 | 43 | 44 | 45 | 48 | 49 | 50 | 54 | 55 | 56 | 57 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | -------------------------------------------------------------------------------- /app/src/main/res/values-ko/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 완료 4 | E-Ink Launcher 5 | 충전 중 6 | 충전 완료 7 | 과열 8 | 배터리 부족 9 | 전원 부족 10 | 모름 11 | 읭? 12 | 기본 경로 13 | 삭제 14 | 취소 15 | 닫기 16 | 확인 17 | 숨기기 18 | 패키지 이름: %s 19 | 제거 20 | 빈 디렉토리 21 | 종료 22 | 파일 탐색기 23 | 화면 잠금 24 | 상위 폴더 25 | 경로 26 | 기기 종료 27 | 앱 관리자 28 | 클라우드 관리자 - 꺼짐 29 | 클라우드 관리자 - 켜짐 30 | "클라우드 관리자 31 | — WiFi 연결 없음" 32 | 33 | 도움말 & 정보 34 | 구분선 숨김 35 | " 행 " 36 | 폰트 크기 설정 37 | 구분선 표시 38 | 기기 39 | WiFi 연결이 필요합니다! 40 | APK 41 | 압축 파일 42 | 인증서 43 | 디렉토리 44 | 파일 45 | 그림 46 | 스프레드시트 47 | 이미지 48 | 음악 49 | PDF 문서 50 | 프리젠테이션 51 | 비디오 52 | 문서 53 | WiFi 닫는 중 54 | WiFi 연결: %s 55 | WiFi 연결 중 56 | WiFi 연결 해제 57 | WiFi 연결 해제 중 58 | WiFi 꺼짐 59 | WiFi 켜짐 60 | WiFi 여는 중 61 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/AboutDialog.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher; 2 | 3 | import android.app.AlertDialog; 4 | import android.content.Context; 5 | import android.os.Build; 6 | import android.view.View; 7 | import android.view.ViewGroup; 8 | import android.widget.LinearLayout; 9 | import android.widget.TextView; 10 | 11 | /** 12 | * Created by Modificator 13 | * time: 17/1/7.下午2:40 14 | * des:create file and achieve model 15 | */ 16 | 17 | public class AboutDialog { 18 | 19 | Context context; 20 | 21 | private AboutDialog(Context context) { 22 | this.context = context; 23 | } 24 | 25 | public static AboutDialog getInstance(Context context) { 26 | return new AboutDialog(context); 27 | } 28 | 29 | private View initLayout() { 30 | LinearLayout root = new LinearLayout(context); 31 | int padding = Utils.dp2Px(context, 15); 32 | root.setPadding(padding, padding, padding, padding); 33 | root.setOrientation(LinearLayout.VERTICAL); 34 | root.setBackgroundColor(0xffffffff); 35 | TextView appName = new TextView(context); 36 | appName.setText("E-Ink Launcher"); 37 | appName.setTextSize(30); 38 | root.addView(appName); 39 | View line = new View(context); 40 | line.setBackgroundColor(0xff000000); 41 | root.addView(line, new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, Utils.dp2Px(context, 1))); 42 | 43 | TextView authorInfo = new TextView(context); 44 | 45 | authorInfo.setText(" Author:Modificator\n Email:yunshangcn@gmail.com\n Weibo: weibo.com/yunshangcn"); 46 | authorInfo.setTextSize(18); 47 | authorInfo.setTextColor(0xff000000); 48 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN) { 49 | authorInfo.setLineSpacing(authorInfo.getLineSpacingExtra(), 1.2f); 50 | } 51 | LinearLayout.LayoutParams authorInfoLP = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT); 52 | authorInfoLP.topMargin = Utils.dp2Px(context, 10); 53 | authorInfoLP.bottomMargin = Utils.dp2Px(context, 10); 54 | root.addView(authorInfo, authorInfoLP); 55 | 56 | line = new View(context); 57 | line.setBackgroundColor(0xff000000); 58 | root.addView(line, new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, Utils.dp2Px(context, 1))); 59 | 60 | TextView thanksView = new TextView(context); 61 | thanksView.setText("Thanks:\nMaciej Haudek "); 62 | thanksView.setTextSize(15); 63 | thanksView.setPadding(0, Utils.dp2Px(context, 10), 0, Utils.dp2Px(context, 10)); 64 | root.addView(thanksView); 65 | 66 | line = new View(context); 67 | line.setBackgroundColor(0xff000000); 68 | root.addView(line, new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, Utils.dp2Px(context, 1))); 69 | 70 | TextView launcherInfo = new TextView(context); 71 | launcherInfo.setText("E-Ink Launcher 是作者君闲暇之作,JDR没桌面,又找不到\n自己满意的,果断自己动手写了一个。\n主要功能:\n1.当然是显示App了\n2.App展示密度调整\n3.App名称字体大小调整\n4.卸载/隐藏App\n5.一键锁屏\n6.一键开关WIFI\n7.可以换图标了,长按图标会出现包名,把图标重命名成包名+文件后缀,然后连接电脑放到 Documents/E-Ink Launcher/icon 下就可以了\nPS:图标长按有惊喜"); 72 | launcherInfo.setTextColor(0xff000000); 73 | launcherInfo.setTextSize(14); 74 | root.addView(launcherInfo); 75 | 76 | return root; 77 | } 78 | 79 | public void show() { 80 | new AlertDialog.Builder(context) 81 | .setView(initLayout()) 82 | .setPositiveButton(R.string.dialog_close, null) 83 | .show(); 84 | } 85 | } 86 | -------------------------------------------------------------------------------- /app/src/main/res/layout/launcher_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 16 | 17 | 21 | 22 | 26 | 27 | 36 | 37 | 41 | 42 | 43 | 51 | 52 | 53 | 54 | 55 | 63 | 64 | 65 | 74 | 75 | 80 | 81 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /app/src/main/res/values-pl/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | E-Ink Launcher 4 | Menedżer plików 5 | 6 | Pusty folder 7 | Urządzenie 8 | Archiwum 9 | Certyfikat 10 | Folder 11 | Plik 12 | Rysunek 13 | Arkusz 14 | Obraz 15 | Muzyka 16 | Wideo 17 | PDF 18 | Prezentacja 19 | Dokument 20 | APK 21 | 22 | Menedżer chmury - wł. 23 | Menedżer chmury - wył. 24 | Menedżer chmury\n -- Brak WIFI 25 | Słaba bateria 26 | Pokaż siatkę 27 | Ukryj siatkę 28 | Ustaw rozmiar czcionki 29 | Zarządzanie aplikacjami 30 | Kolumny 31 | " Wiersze " 32 | Proszę włączyć Wlan! 33 | Gotowe 34 | Przegrzanie baterii 35 | Nieznany 36 | Ładowanie 37 | Niski poziom 38 | Pełna 39 | WTF? 40 | 41 | Anuluj 42 | Ukryj 43 | Odinstaluj 44 | Nazwa pakietu: %s 45 | Zamknij 46 | 47 | WiFi wył. 48 | Wyłączanie WiFi 49 | Włączanie WiFi 50 | WiFi wł. 51 | WiFi połączone:%s 52 | Łączenie WiFi 53 | WiFi wyłączone 54 | Rozłączanie WiFi 55 | 56 | Zablokuj ekran 57 | 58 | 59 | Wyłącz 60 | Uruchom ponownie 61 | 62 | 现在可以操作电源了哦~ 63 | Pomoc i informacje 64 | Ścieżka 65 | Domyślna ścieżka 66 | Potwierdź 67 | Wyżej 68 | Zakończ 69 | Usuń 70 | 71 | -------------------------------------------------------------------------------- /app/src/main/res/values-zh/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | E-Ink Launcher 4 | 文件浏览 5 | 6 | 空文件夹 7 | App安装包 8 | 压缩包 9 | 证书 10 | 文件夹 11 | 文件 12 | 照片 13 | 电子表格 14 | 图片 15 | 音乐 16 | PDF文档 17 | PPT 演示文档 18 | 视频 19 | Word文档 20 | 21 | 22 | 显示分隔线 23 | 隐藏分隔线 24 | 设置字体大小 25 | 管理应用 26 | 打开设备管理器 27 | 每列图标 28 | 大哥诶,麻烦先把WIFI连上吧 29 | 每行图标 30 | 电池过热 31 | 电池呢? 32 | 充电中 33 | 电量低 34 | 充满了 35 | WTF? 36 | 37 | 取消 38 | 隐藏 39 | 卸载 40 | 包名: %s 41 | 关闭 42 | 43 | WiFi 已关闭 44 | WiFi 正在关闭 45 | WiFi 正在开启 46 | WiFi 已开启 47 | WiFi 已连接:%s 48 | WiFi 连接中 49 | WiFi 已断开 50 | WiFi 断开中 51 | 52 | 一键锁屏 53 | 54 | 55 | 关机 56 | 重启 57 | 58 | 网络传书 (开) 59 | 网络传书 (关) 60 | 网络传书 (请连接WIFI) 61 | 帮助 & 关于 62 | 路径 63 | 设置默认路径 64 | 确认 65 | 上级目录 66 | 退出 67 | 删除 68 | 完成 69 | 现在可以操作电源了哦~ 70 | 电量低 71 | 显示自定义图标 72 | 显示状态栏 73 | 显示WiFi名字 74 | 点击这里回到桌面 75 | App 名字 76 | 启动失败 77 | 打开设备管理器 78 | 请打开设备管理器并启用 E-Ink Launcher 79 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/Utils.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher; 2 | 3 | import android.Manifest; 4 | import android.app.Activity; 5 | import android.content.Context; 6 | import android.content.pm.PackageManager; 7 | import android.content.res.ColorStateList; 8 | import android.graphics.drawable.Drawable; 9 | import android.os.Build; 10 | 11 | import androidx.core.graphics.drawable.DrawableCompat; 12 | 13 | import java.io.File; 14 | import java.text.DecimalFormat; 15 | import java.util.ArrayList; 16 | import java.util.Arrays; 17 | import java.util.Calendar; 18 | import java.util.Collections; 19 | import java.util.List; 20 | 21 | 22 | /** 23 | * Created by mod on 16-5-6. 24 | */ 25 | public class Utils { 26 | 27 | public static Drawable tintDrawable(Drawable drawable, ColorStateList colors) { 28 | final Drawable wrappedDrawable = DrawableCompat.wrap(drawable); 29 | DrawableCompat.setTintList(wrappedDrawable, colors); 30 | return wrappedDrawable; 31 | } 32 | 33 | public static String getReadableFileSize(long size) { 34 | // if (size <= 0) return "0"; 35 | // final String[] units = new String[]{"B", "KB", "MB", "GB", "TB"}; 36 | // int digitGroups = (int) (Math.log10(size) / Math.log10(1024)); 37 | // return new DecimalFormat("#").format(size / Math.pow(1024, digitGroups)) + " " + units[digitGroups]; 38 | DecimalFormat formater = new DecimalFormat("####.00"); 39 | if (size < 1024 * 0.8) { 40 | return size + "bytes"; 41 | } else if (size < 1024 * 1024 * 0.8) { 42 | float kbsize = size / 1024f; 43 | return formater.format(kbsize) + "KB"; 44 | } else if (size < 1024 * 1024 * 1024 * 0.8) { 45 | float mbsize = size / 1024f / 1024f; 46 | return formater.format(mbsize) + "MB"; 47 | } else if (size < 1024 * 1024 * 1024 * 1024 * 0.8) { 48 | float gbsize = size / 1024f / 1024f / 1024f; 49 | return formater.format(gbsize) + "GB"; 50 | } else { 51 | float tbsize = size / 1024f / 1024f / 1024f / 1024f; 52 | return formater.format(tbsize) + "TB"; 53 | } 54 | } 55 | 56 | public static int dp2Px(Context context, float dp) { 57 | final float scale = context.getResources().getDisplayMetrics().density; 58 | return (int) (dp * scale + 0.5f); 59 | } 60 | 61 | public static String getAMPMCNString(int hours, int ampm) { 62 | if (ampm == Calendar.AM) { 63 | if (hours < 5) { 64 | return sAmPmCN[0]; 65 | } else if (hours >= 5 && hours < 7) { 66 | return sAmPmCN[1]; 67 | } else if (hours >= 7 && hours < 9) { 68 | return sAmPmCN[2]; 69 | } else if (hours >= 9 && hours < 12) { 70 | return sAmPmCN[3]; 71 | } else { 72 | return sAmPmCN[0]; 73 | } 74 | } else { 75 | if (hours == 0) { 76 | return sAmPmCN[4]; 77 | } else if (hours < 6) { 78 | return sAmPmCN[5]; 79 | } else if (hours >= 6 && hours <= 9) { 80 | return sAmPmCN[6]; 81 | } else if (hours > 9 && hours < 12) { 82 | return sAmPmCN[7]; 83 | } else if (hours == 12) { 84 | return sAmPmCN[4]; 85 | } else { 86 | return sAmPmCN[4]; 87 | } 88 | } 89 | } 90 | 91 | private static final String[] sAmPmCN = new String[]{ 92 | "凌晨", "黎明", "早晨", "上午", "中午", "下午", "晚上", "深夜" 93 | }; 94 | 95 | public static void checkStroagePermission(Activity activity,Runnable next){ 96 | String[] permissions = new String[]{Manifest.permission.READ_EXTERNAL_STORAGE,Manifest.permission.WRITE_EXTERNAL_STORAGE}; 97 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M && activity.checkSelfPermission(Manifest.permission.READ_EXTERNAL_STORAGE)== PackageManager.PERMISSION_DENIED) { 98 | activity.requestPermissions(permissions,10003); 99 | }else if(next!=null){ 100 | next.run(); 101 | } 102 | } 103 | 104 | } 105 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_file_manager.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 14 | 15 | 22 | 23 | 41 | 42 | 43 | 47 | 48 | 53 | 54 | 58 | 59 | 62 | 63 | 74 | 75 | 79 | 80 | 81 | 89 | 90 | 94 | 95 | 105 | 106 | 107 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/CrashDetailPage.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher; 2 | 3 | import android.app.Activity; 4 | import android.content.Context; 5 | import android.content.Intent; 6 | import android.graphics.Color; 7 | import android.graphics.Typeface; 8 | import android.os.Bundle; 9 | import android.text.SpannableString; 10 | import android.text.Spanned; 11 | import android.text.SpannedString; 12 | import android.text.style.AbsoluteSizeSpan; 13 | import android.text.style.StyleSpan; 14 | import android.view.Gravity; 15 | import android.view.View; 16 | import android.view.ViewGroup; 17 | import android.widget.LinearLayout; 18 | import android.widget.ScrollView; 19 | import android.widget.TextView; 20 | 21 | import java.io.File; 22 | import java.io.FileInputStream; 23 | import java.io.FileNotFoundException; 24 | import java.io.FileReader; 25 | import java.io.IOException; 26 | import java.io.InputStreamReader; 27 | 28 | import androidx.annotation.Nullable; 29 | 30 | public class CrashDetailPage extends Activity { 31 | 32 | private TextView btnReLaunch, tvContent; 33 | private Context mContext; 34 | 35 | @Override 36 | protected void onCreate(@Nullable Bundle savedInstanceState) { 37 | super.onCreate(savedInstanceState); 38 | mContext = this; 39 | initViews(); 40 | } 41 | 42 | private void initViews() { 43 | LinearLayout root = new LinearLayout(this); 44 | root.setOrientation(LinearLayout.VERTICAL); 45 | root.setBackgroundColor(Color.WHITE); 46 | 47 | ScrollView scrollView = new ScrollView(this); 48 | tvContent = new TextView(this); 49 | tvContent.setTextColor(Color.BLACK); 50 | tvContent.setTextSize(12); 51 | 52 | scrollView.addView(tvContent); 53 | 54 | 55 | root.addView(scrollView, new LinearLayout.LayoutParams(-1, -1, 1)); 56 | 57 | btnReLaunch = new TextView(this); 58 | btnReLaunch.setText("Restart Launcher"); 59 | btnReLaunch.setTextColor(Color.BLACK); 60 | btnReLaunch.setGravity(Gravity.CENTER); 61 | 62 | View divider = new View(this); 63 | divider.setBackgroundColor(Color.BLACK); 64 | root.addView(divider, new ViewGroup.LayoutParams(-1, 1)); 65 | root.addView(btnReLaunch, new LinearLayout.LayoutParams(-1, Utils.dp2Px(this, 40))); 66 | 67 | setContentView(root); 68 | } 69 | 70 | private void fillErrorContent() { 71 | btnReLaunch.setOnClickListener(new View.OnClickListener() { 72 | @Override 73 | public void onClick(View v) { 74 | Intent intent = new Intent(mContext, Launcher.class); 75 | intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK); 76 | startActivity(intent); 77 | finish(); 78 | } 79 | }); 80 | 81 | tvContent.setText(""); 82 | String title = "Oh! It's Crashed."; 83 | SpannableString titleSpan = new SpannableString(title); 84 | titleSpan.setSpan(new AbsoluteSizeSpan(25, true), 0, title.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); 85 | tvContent.append(titleSpan); 86 | tvContent.append("\nーーーーーーーーーーーーーーーーーーーー\n"); 87 | tvContent.append("Please screenshot and give me feedback.\n"); 88 | tvContent.append("email : yunshangcn@gmail.com\n"); 89 | tvContent.append("telegram : https://t.me/EInkLauncher\n"); 90 | tvContent.append("github issues : https://github.com/Modificator/E-Ink-Launcher\n"); 91 | tvContent.append("well it's already open source\n"); 92 | tvContent.append("当然也可以在酷安应用页反馈\n"); 93 | tvContent.append("Thanks."); 94 | tvContent.append("\nーーーーーーーーーーーーーーーーーーーー\n"); 95 | 96 | if (getIntent().hasExtra("crashFile")) { 97 | String fileName = getIntent().getStringExtra("crashFile"); 98 | File crashFile = new File(getExternalFilesDir("crash"), fileName); 99 | try { 100 | char[] readData = new char[(int) crashFile.length()]; 101 | FileReader reader = new FileReader(crashFile); 102 | reader.read(readData); 103 | tvContent.append(new String(readData)); 104 | reader.close(); 105 | } catch (Throwable e) { 106 | e.printStackTrace(); 107 | } 108 | } 109 | } 110 | 111 | @Override 112 | protected void onStart() { 113 | super.onStart(); 114 | fillErrorContent(); 115 | 116 | } 117 | } 118 | -------------------------------------------------------------------------------- /app/src/main/java/cn/modificator/launcher/widgets/BatteryView.java: -------------------------------------------------------------------------------- 1 | package cn.modificator.launcher.widgets; 2 | 3 | import android.content.Context; 4 | import android.graphics.Canvas; 5 | import android.graphics.Paint; 6 | import android.graphics.Path; 7 | import android.graphics.Rect; 8 | import android.graphics.RectF; 9 | import android.text.TextPaint; 10 | import android.util.AttributeSet; 11 | import android.util.Log; 12 | import android.view.View; 13 | 14 | /** 15 | * Created by mod on 16-4-25. 16 | */ 17 | 18 | public class BatteryView extends View { 19 | Paint circlePaint; 20 | TextPaint textPaint; 21 | int maxProgress = 100; 22 | int progress = 0; 23 | 24 | public BatteryView(Context context) { 25 | super(context); 26 | init(); 27 | } 28 | 29 | public BatteryView(Context context, AttributeSet attrs) { 30 | super(context, attrs); 31 | init(); 32 | } 33 | 34 | public BatteryView(Context context, AttributeSet attrs, int defStyleAttr) { 35 | super(context, attrs, defStyleAttr); 36 | init(); 37 | } 38 | 39 | private void init() { 40 | circlePaint = new Paint(); 41 | circlePaint.setStyle(Paint.Style.STROKE); 42 | circlePaint.setAntiAlias(true); 43 | textPaint = new TextPaint(); 44 | textPaint.setColor(0xff000000); 45 | textPaint.setAntiAlias(true); 46 | } 47 | 48 | @Override 49 | protected void onDraw(Canvas canvas) { 50 | super.onDraw(canvas); 51 | int size = getWidth() > getHeight() ? getHeight() : getWidth(); 52 | circlePaint.setStrokeWidth(size / 10); 53 | circlePaint.setColor(0xffcccccc); 54 | canvas.drawCircle(getWidth() / 2, getHeight() / 2, (size - circlePaint.getStrokeWidth()) / 2, circlePaint); 55 | RectF rectF = new RectF( 56 | (getWidth() - size + circlePaint.getStrokeWidth()) / 2, 57 | (getHeight() - size + circlePaint.getStrokeWidth()) / 2, 58 | (getWidth() - size - circlePaint.getStrokeWidth()) / 2 + size, 59 | (getHeight() - size - circlePaint.getStrokeWidth()) / 2 + size 60 | ); 61 | circlePaint.setColor(0xff000000); 62 | canvas.drawArc(rectF, -90, progress * 1f / maxProgress * 360, false, circlePaint); 63 | textPaint.setTextSize(size / 2.8f); 64 | drawText(canvas); 65 | } 66 | 67 | private void drawText(Canvas canvas) { 68 | String showText = String.format("%02d", (int) Math.round(progress * 1f / maxProgress * 100)); 69 | Rect rect = new Rect(); 70 | textPaint.getTextBounds(showText, 0, showText.length(), rect); 71 | textPaint.setFakeBoldText(true); 72 | canvas.translate(getWidth() / 2f, getHeight() / 2f); 73 | canvas.drawText(showText, 74 | -(rect.right - rect.left) / 1.9f, 75 | (rect.bottom - rect.top) / 2f, textPaint); 76 | } 77 | 78 | public void setMaxProgress(int maxProgress) { 79 | this.maxProgress = maxProgress; 80 | invalidate(); 81 | } 82 | 83 | public void setProgress(int progress) { 84 | this.progress = progress; 85 | invalidate(); 86 | } 87 | /*private void drawChargeIcon(Canvas canvas) { 88 | Paint paint = new Paint(); 89 | paint.setStyle(Paint.Style.FILL); 90 | paint.setColor(0xff000000); 91 | int size = getHeight(); 92 | float margin = size * 0.2f; 93 | Path path = new Path(); 94 | path.moveTo(size / 3f+margin, 0+margin); 95 | path.lineTo(size / 3f * 2-margin, 0+margin); 96 | path.lineTo(size * 0.45f, size * 0.45f); 97 | path.lineTo(size * 0.8f, size * 0.45f); 98 | path.lineTo(size * 0.25f, size); 99 | path.lineTo(size * 0.45f, size * 0.55f); 100 | path.lineTo(size * 0.25f, size * 0.55f);*//* 101 | path.moveTo(size / 3f, 0); 102 | path.lineTo(size / 3f * 2, 0); 103 | path.lineTo(size * 0.45f, size * 0.45f); 104 | path.lineTo(size * 0.8f, size * 0.45f); 105 | path.lineTo(size * 0.25f, size); 106 | path.lineTo(size * 0.45f, size * 0.55f); 107 | path.lineTo(size * 0.25f, size * 0.55f);*//* 108 | path.close(); 109 | canvas.drawPath(path, paint); 110 | 111 | }*/ 112 | 113 | @Override 114 | protected void onWindowVisibilityChanged(int visibility) { 115 | super.onWindowVisibilityChanged(visibility); 116 | if (visibility == VISIBLE) { 117 | 118 | } else { 119 | 120 | } 121 | } 122 | 123 | } 124 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | E-Ink Launcher 3 | File Manager 4 | 5 | Empty directory 6 | Device 7 | Archive 8 | Certificate 9 | Directory 10 | File 11 | Picture 12 | Spreadsheet 13 | Image 14 | Music 15 | Video 16 | PDF document 17 | Presentation 18 | Document 19 | APK 20 | 21 | Cloud Manager - ON 22 | Cloud Manager - OFF 23 | Cloud Manager\n -- No WIFI connect 24 | Low power 25 | Show Divider 26 | Hide Divider 27 | Change Font Size 28 | Apps Manager 29 | Open Device Manager 30 | Column 31 | " Row " 32 | Please connect Wlan! 33 | Done 34 | Battery Overheat 35 | Unknown 36 | Charging 37 | Low Battery 38 | Full 39 | WTF? 40 | 41 | Cancel 42 | Hide 43 | Uninstall 44 | Package Name: %s 45 | Close 46 | 47 | WiFi OFF 48 | WiFi closing 49 | WiFi opening 50 | WiFi ON 51 | WiFi connected:%s 52 | WiFi connecting 53 | WiFi disconnected 54 | WiFi disconnecting 55 | 56 | Lock Screen 57 | Launch failed 58 | Please open Device Policy Manager and enable E-Ink Launcher 59 | Open Device Policy Manager 60 | 61 | 62 | Power off 63 | Reboot 64 | 65 | 现在可以操作电源了哦~ 66 | 混淆有毛用啊,文件这么少,代码渣貌似也能增加难度,不想加固,加固有问题,大哥我这就署名有价值,反编译别把我名字去了- - 67 | 给点赏钱吧,支付鸨就行,账号是邮箱 68 | Help & About 69 | Path 70 | Default Path 71 | Confim 72 | Parent folder 73 | Exit 74 | Delete 75 | Show StatusBar 76 | Show Wifi Name 77 | Show custom icon 78 | Click here, back to Launcher 79 | App name 80 | 81 | -------------------------------------------------------------------------------- /app/src/main/res/layout/launcher_activity.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 16 | 17 | 21 | 22 | 25 | 26 | 30 | 31 | 39 | 40 | 46 | 47 | 51 | 52 | 58 | 59 | 63 | 64 | 71 | 72 | 73 | 74 | 82 | 83 |