├── .idea ├── .name ├── .gitignore ├── compiler.xml ├── runConfigurations.xml ├── misc.xml └── jarRepositories.xml ├── app ├── .gitignore ├── .DS_Store ├── src │ ├── .DS_Store │ ├── main │ │ ├── .DS_Store │ │ ├── java │ │ │ ├── .DS_Store │ │ │ └── com │ │ │ │ ├── .DS_Store │ │ │ │ └── example │ │ │ │ ├── .DS_Store │ │ │ │ └── fruit │ │ │ │ ├── .DS_Store │ │ │ │ ├── MainView.java │ │ │ │ ├── register │ │ │ │ ├── RegisterView.java │ │ │ │ ├── RegisterModel.java │ │ │ │ └── RegisterPresenter.java │ │ │ │ ├── login │ │ │ │ ├── LoginView.java │ │ │ │ ├── LoginModel.java │ │ │ │ └── LoginPresenter.java │ │ │ │ ├── history │ │ │ │ ├── HistoryView.java │ │ │ │ ├── OnItemClickListener.java │ │ │ │ ├── HistoryModel.java │ │ │ │ ├── HistoryPresenter.java │ │ │ │ └── HistoryAdapter.java │ │ │ │ ├── collection │ │ │ │ ├── OnItemClickListener.java │ │ │ │ ├── CollectionView.java │ │ │ │ ├── CollectionModel.java │ │ │ │ ├── CollectionItem.java │ │ │ │ ├── CollectionPresenter.java │ │ │ │ └── CollectionAdapter.java │ │ │ │ ├── home │ │ │ │ ├── QuickView.java │ │ │ │ ├── QuickModel.java │ │ │ │ ├── QuickPage.java │ │ │ │ ├── QuickPresenter.java │ │ │ │ └── QuickPageAdapter.java │ │ │ │ ├── setting │ │ │ │ ├── SettingsView.java │ │ │ │ ├── SettingsModel.java │ │ │ │ └── SettingsPresenter.java │ │ │ │ ├── MainModel.java │ │ │ │ ├── search │ │ │ │ ├── MJavascriptInterface.java │ │ │ │ ├── SearchPresenter.java │ │ │ │ ├── SearchModel.java │ │ │ │ └── BlockerTool.java │ │ │ │ ├── MyAppliaction.java │ │ │ │ ├── bean │ │ │ │ ├── Collection.java │ │ │ │ ├── History.java │ │ │ │ ├── Quick.java │ │ │ │ └── User.java │ │ │ │ ├── MainPresenter.java │ │ │ │ ├── splash │ │ │ │ └── SplashActivity.java │ │ │ │ ├── discover │ │ │ │ └── DiscoverFragment.java │ │ │ │ └── utils │ │ │ │ └── Util.java │ │ ├── res │ │ │ ├── .DS_Store │ │ │ ├── drawable │ │ │ │ ├── .DS_Store │ │ │ │ ├── logo.png │ │ │ │ ├── discover1.png │ │ │ │ ├── discover2.png │ │ │ │ ├── discover3.png │ │ │ │ ├── discover4.png │ │ │ │ ├── discover5.png │ │ │ │ ├── discover6.png │ │ │ │ ├── discover7.jpeg │ │ │ │ ├── icon_logo.png │ │ │ │ ├── bytedance_logo.png │ │ │ │ ├── edit_text_focus.xml │ │ │ │ ├── menu_icon_bg_border_my_exit.xml │ │ │ │ ├── menu_icon_bg_border_add_collection.xml │ │ │ │ ├── menu_icon_bg_border_my_collection.xml │ │ │ │ ├── menu_icon_bg_border_my_history.xml │ │ │ │ ├── menu_icon_bg_border_my_setting.xml │ │ │ │ ├── lnk_icon_bg_border.xml │ │ │ │ ├── menu_icon_bg_border.xml │ │ │ │ ├── pop_window_border.xml │ │ │ │ ├── search_button_border.xml │ │ │ │ ├── home_search_bar_border.xml │ │ │ │ ├── home_discover_bar_border.xml │ │ │ │ ├── cursor_style.xml │ │ │ │ ├── save_photo_border.xml │ │ │ │ ├── user_image.xml │ │ │ │ ├── player_gesture_shape.xml │ │ │ │ ├── login_register_edittext_border.xml │ │ │ │ ├── search_bar_border.xml │ │ │ │ ├── setting_image_window_shape.xml │ │ │ │ ├── setting_name_window_shape.xml │ │ │ │ ├── switch_style.xml │ │ │ │ ├── logout_window_shape.xml │ │ │ │ ├── switch_off.xml │ │ │ │ ├── search_btn_shape.xml │ │ │ │ ├── switch_on.xml │ │ │ │ ├── reload_shape.xml │ │ │ │ ├── logout_btn_shape.xml │ │ │ │ ├── switch_thume.xml │ │ │ │ ├── navigation_bar.xml │ │ │ │ ├── button_circle_shape.xml │ │ │ │ ├── login_btn_shape.xml │ │ │ │ ├── discover_image.xml │ │ │ │ └── ic_launcher_background.xml │ │ │ ├── drawable-v24 │ │ │ │ ├── qq.png │ │ │ │ ├── .DS_Store │ │ │ │ ├── home.png │ │ │ │ ├── menu.png │ │ │ │ ├── paging.png │ │ │ │ ├── quit.png │ │ │ │ ├── reload.png │ │ │ │ ├── search.png │ │ │ │ ├── trash.png │ │ │ │ ├── user.png │ │ │ │ ├── wechat.png │ │ │ │ ├── add_lnk.png │ │ │ │ ├── add_page.png │ │ │ │ ├── app_logo.png │ │ │ │ ├── go_page.png │ │ │ │ ├── history.png │ │ │ │ ├── setting.png │ │ │ │ ├── back_page.png │ │ │ │ ├── collection.png │ │ │ │ ├── home_logo.png │ │ │ │ ├── rotate_left.png │ │ │ │ ├── search_home.png │ │ │ │ ├── home_enabled.png │ │ │ │ ├── page_history.png │ │ │ │ ├── player_bright.png │ │ │ │ ├── player_volume.png │ │ │ │ ├── rotate_right.png │ │ │ │ ├── setting_user.png │ │ │ │ ├── add_collection.png │ │ │ │ ├── add_quick_page.png │ │ │ │ ├── confirm_password.png │ │ │ │ ├── go_page_enabled.png │ │ │ │ ├── home_logo_text.png │ │ │ │ ├── lnk_default_item.png │ │ │ │ ├── page_collection.png │ │ │ │ ├── back_page_enabled.png │ │ │ │ ├── search_delete_edittext.png │ │ │ │ ├── login_register_edit_user.png │ │ │ │ ├── login_register_edit_password.png │ │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── mipmap-hdpi │ │ │ │ ├── logo.png │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ │ ├── logo.png │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── logo.png │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── logo.png │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── logo.png │ │ │ │ ├── .DS_Store │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-anydpi-v26 │ │ │ │ ├── quick_page.png │ │ │ │ ├── logo.xml │ │ │ │ ├── ic_launcher.xml │ │ │ │ └── ic_launcher_round.xml │ │ │ ├── values │ │ │ │ ├── arrays.xml │ │ │ │ ├── attrs.xml │ │ │ │ ├── styles.xml │ │ │ │ ├── colors.xml │ │ │ │ └── strings.xml │ │ │ ├── xml │ │ │ │ └── provider_paths.xml │ │ │ ├── anim │ │ │ │ ├── night_fade_out.xml │ │ │ │ ├── nigth_fade_in.xml │ │ │ │ ├── rotate_left.xml │ │ │ │ ├── rotate_right.xml │ │ │ │ ├── pop_hidden.xml │ │ │ │ ├── pop_show.xml │ │ │ │ ├── photo_browser_in.xml │ │ │ │ └── photo_browser_out.xml │ │ │ ├── layout │ │ │ │ ├── splash_activity.xml │ │ │ │ ├── search_fragment.xml │ │ │ │ ├── confirm_window.xml │ │ │ │ ├── collection_item.xml │ │ │ │ ├── quick_page_item.xml │ │ │ │ ├── activity_photo_browser.xml │ │ │ │ ├── confirm_password_window.xml │ │ │ │ ├── setting_name_window.xml │ │ │ │ ├── history_item.xml │ │ │ │ ├── setting_image_window.xml │ │ │ │ ├── history_fragment.xml │ │ │ │ ├── setting_password_window.xml │ │ │ │ ├── collection_fragment.xml │ │ │ │ ├── quick_page_dialog.xml │ │ │ │ ├── home_fragment.xml │ │ │ │ ├── activity_main.xml │ │ │ │ ├── login_fragment.xml │ │ │ │ └── discover_fragment.xml │ │ │ ├── raw │ │ │ │ └── night.css │ │ │ └── values-night │ │ │ │ └── colors.xml │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── example │ │ │ └── fruit │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── example │ │ └── fruit │ │ └── ExampleInstrumentedTest.java ├── .settings │ └── org.eclipse.buildship.core.prefs ├── .classpath ├── proguard-rules.pro ├── .project └── build.gradle ├── settings.gradle ├── .DS_Store ├── images ├── and.png ├── logo.png ├── .DS_Store ├── search.gif ├── splash.gif ├── title.png ├── unity.png ├── dark_mode.gif ├── home_dark.png ├── logo_text.png ├── scut_logo.png ├── home_light.png ├── quick_page.gif ├── bytedance_logo.png └── history_bookmark.gif ├── gradle ├── .DS_Store └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .settings └── org.eclipse.buildship.core.prefs ├── .project ├── gradle.properties ├── .gitignore ├── gradlew.bat ├── Chinese_Introduction └── README.md ├── README.md └── gradlew /.idea/.name: -------------------------------------------------------------------------------- 1 | Fruit -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | #忽略根目录下的 2 | /build 3 | 4 | # -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | rootProject.name = "Fruit" -------------------------------------------------------------------------------- /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/.DS_Store -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | -------------------------------------------------------------------------------- /app/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/.DS_Store -------------------------------------------------------------------------------- /images/and.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/and.png -------------------------------------------------------------------------------- /images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/logo.png -------------------------------------------------------------------------------- /app/src/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/.DS_Store -------------------------------------------------------------------------------- /gradle/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/gradle/.DS_Store -------------------------------------------------------------------------------- /images/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/.DS_Store -------------------------------------------------------------------------------- /images/search.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/search.gif -------------------------------------------------------------------------------- /images/splash.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/splash.gif -------------------------------------------------------------------------------- /images/title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/title.png -------------------------------------------------------------------------------- /images/unity.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/unity.png -------------------------------------------------------------------------------- /images/dark_mode.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/dark_mode.gif -------------------------------------------------------------------------------- /images/home_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/home_dark.png -------------------------------------------------------------------------------- /images/logo_text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/logo_text.png -------------------------------------------------------------------------------- /images/scut_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/scut_logo.png -------------------------------------------------------------------------------- /app/src/main/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/.DS_Store -------------------------------------------------------------------------------- /images/home_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/home_light.png -------------------------------------------------------------------------------- /images/quick_page.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/quick_page.gif -------------------------------------------------------------------------------- /images/bytedance_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/bytedance_logo.png -------------------------------------------------------------------------------- /app/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- 1 | connection.project.dir=.. 2 | eclipse.preferences.version=1 3 | -------------------------------------------------------------------------------- /app/src/main/java/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/java/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/.DS_Store -------------------------------------------------------------------------------- /images/history_bookmark.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/images/history_bookmark.gif -------------------------------------------------------------------------------- /app/src/main/java/com/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/java/com/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/drawable/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/drawable/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/logo.png -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/qq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/qq.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-hdpi/logo.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-mdpi/logo.png -------------------------------------------------------------------------------- /app/src/main/java/com/example/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/java/com/example/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/home.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/menu.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/paging.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/paging.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/quit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/quit.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/reload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/reload.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/search.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/trash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/trash.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/user.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/wechat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/wechat.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover1.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover2.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover3.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover4.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover5.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover6.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover7.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/discover7.jpeg -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/icon_logo.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xhdpi/logo.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxhdpi/logo.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxxhdpi/logo.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/add_lnk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/add_lnk.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/add_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/add_page.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/app_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/app_logo.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/go_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/go_page.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/history.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/history.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/setting.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxxhdpi/.DS_Store -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/java/com/example/fruit/.DS_Store -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/back_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/back_page.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/collection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/collection.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/home_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/home_logo.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/rotate_left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/rotate_left.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/search_home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/search_home.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/bytedance_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable/bytedance_logo.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/home_enabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/home_enabled.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/page_history.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/page_history.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/player_bright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/player_bright.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/player_volume.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/player_volume.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/rotate_right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/rotate_right.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/setting_user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/setting_user.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/MainView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | public interface MainView { 4 | void showAddCollection(); 5 | } 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/add_collection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/add_collection.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/add_quick_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/add_quick_page.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/confirm_password.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/confirm_password.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/go_page_enabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/go_page_enabled.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/home_logo_text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/home_logo_text.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/lnk_default_item.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/lnk_default_item.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/page_collection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/page_collection.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/quick_page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-anydpi-v26/quick_page.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/back_page_enabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/back_page_enabled.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/search_delete_edittext.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/search_delete_edittext.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/login_register_edit_user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/login_register_edit_user.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/edit_text_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/login_register_edit_password.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/HeXavi8/Orange-Browser/HEAD/app/src/main/res/drawable-v24/login_register_edit_password.png -------------------------------------------------------------------------------- /app/src/main/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | baidu.com 5 | 6 | -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/register/RegisterView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.register; 2 | 3 | public interface RegisterView { 4 | void showRegisterSuccessfully(); 5 | void showUsernameExist(); 6 | } 7 | -------------------------------------------------------------------------------- /app/src/main/res/xml/provider_paths.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border_my_exit.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border_add_collection.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border_my_collection.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border_my_history.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border_my_setting.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/lnk_icon_bg_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/login/LoginView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.login; 2 | 3 | import com.example.fruit.bean.User; 4 | 5 | public interface LoginView { 6 | void showLoginSuccessfully(User user); 7 | 8 | void showLoginFailed(); 9 | } 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/menu_icon_bg_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/pop_window_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/history/HistoryView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.history; 2 | 3 | import com.example.fruit.bean.History; 4 | 5 | import java.util.List; 6 | 7 | public interface HistoryView { 8 | void showAll(List histories); 9 | } 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/search_button_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/anim/night_fade_out.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/home_search_bar_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/logo.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Tue Jun 15 16:58:12 CST 2021 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-6.7.1-all.zip 7 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/history/OnItemClickListener.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.history; 2 | 3 | import android.view.View; 4 | 5 | public interface OnItemClickListener { 6 | void onClick(View view, int pos); 7 | 8 | boolean onLongClick(View view, int pos); 9 | } 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/home_discover_bar_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/collection/OnItemClickListener.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.collection; 2 | 3 | import android.view.View; 4 | 5 | public interface OnItemClickListener { 6 | void onClick(View view, int pos); 7 | 8 | boolean onLongClick(View view, int pos); 9 | } 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/cursor_style.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/values/attrs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/collection/CollectionView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.collection; 2 | 3 | import com.example.fruit.bean.Collection; 4 | 5 | import java.util.List; 6 | 7 | public interface CollectionView { 8 | void showAllCollection(List collections); 9 | } 10 | -------------------------------------------------------------------------------- /app/src/main/res/anim/nigth_fade_in.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/save_photo_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/user_image.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/home/QuickView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.home; 2 | 3 | import com.example.fruit.bean.Quick; 4 | 5 | import java.util.List; 6 | 7 | public interface QuickView { 8 | void insertSuccess(); 9 | 10 | void insertFail(); 11 | 12 | void showAll(List quicks); 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/player_gesture_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/login_register_edittext_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/setting/SettingsView.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.setting; 2 | 3 | public interface SettingsView { 4 | void showChangeName(); 5 | 6 | void showProfileAfterChange(); 7 | 8 | void showCheckPasswordFalse(); 9 | 10 | void showCheckPasswordSuccess(); 11 | 12 | void showDeleteUser(); 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/search_bar_border.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/anim/rotate_left.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/anim/rotate_right.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | 10 | -------------------------------------------------------------------------------- /app/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/setting_image_window_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | android:shape="rectangle"> 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/setting_name_window_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/anim/pop_hidden.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/switch_style.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/anim/pop_show.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 12 | -------------------------------------------------------------------------------- /.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- 1 | arguments= 2 | auto.sync=false 3 | build.scans.enabled=false 4 | connection.gradle.distribution=GRADLE_DISTRIBUTION(WRAPPER) 5 | connection.project.dir= 6 | eclipse.preferences.version=1 7 | gradle.user.home= 8 | java.home=/Library/Java/JavaVirtualMachines/jdk-15.jdk/Contents/Home 9 | jvm.arguments= 10 | offline.mode=false 11 | override.workspace.settings=true 12 | show.console.view=true 13 | show.executions.view=true 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/logout_window_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/switch_off.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 7 | 8 | 10 | 11 | 12 | 13 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/search_btn_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/switch_on.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 7 | 8 | 9 | 11 | 12 | 13 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/test/java/com/example/fruit/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /app/src/main/res/drawable/reload_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/anim/photo_browser_in.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/anim/photo_browser_out.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/logout_btn_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/switch_thume.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/MainModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | import com.example.fruit.dao.DBController; 4 | import com.example.fruit.utils.Util; 5 | 6 | public class MainModel { 7 | private DBController mDBController; 8 | private String username; 9 | 10 | public MainModel() { 11 | mDBController = DBController.getInstance(MyAppliaction.getContext()); 12 | username = Util.getInstance().getUserName(); 13 | } 14 | 15 | public void addCollection(String url, String title) { 16 | mDBController.addCollection(username, url, title); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/navigation_bar.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | //边框的颜色 5 | 6 | 7 | 8 | 9 | 10 | //这里有四个方向可以选择,这里因为只要显示底部边框,所以就设置bottom 12 | 13 | 14 | //整个空间的背景颜色 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_circle_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 11 | 12 | **设置文字padding** 13 | 14 | 20 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/search/MJavascriptInterface.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.search; 2 | 3 | import android.content.Context; 4 | import android.content.Intent; 5 | 6 | public class MJavascriptInterface { 7 | private Context context; 8 | 9 | public MJavascriptInterface(Context context) { 10 | this.context = context; 11 | } 12 | 13 | @android.webkit.JavascriptInterface 14 | public void openImage(String img) { 15 | Intent intent = new Intent(); 16 | intent.putExtra("image", img); 17 | intent.setClass(context, PhotoBrowserActivity.class); 18 | context.startActivity(intent); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/login_btn_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/discover_image.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 11 | 12 | **设置文字padding** 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/search/SearchPresenter.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.search; 2 | 3 | import android.os.Handler; 4 | import android.os.Message; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | import com.example.fruit.bean.History; 9 | 10 | import java.util.List; 11 | 12 | public class SearchPresenter { 13 | private SearchModel mSearchModel; 14 | 15 | public SearchPresenter() { 16 | mSearchModel = new SearchModel(); 17 | } 18 | 19 | public void insertHistories(List histories) { 20 | new Thread(new Runnable() { 21 | @Override 22 | public void run() { 23 | mSearchModel.insertHistory(histories); 24 | } 25 | }).start(); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/search/SearchModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.search; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.Collection; 5 | import com.example.fruit.bean.History; 6 | import com.example.fruit.dao.DBController; 7 | import com.example.fruit.utils.Util; 8 | 9 | import java.util.List; 10 | 11 | public class SearchModel { 12 | private DBController mDBController; 13 | private String mUsername; 14 | 15 | public SearchModel() { 16 | mDBController = DBController.getInstance(MyAppliaction.getContext()); 17 | mUsername = Util.getInstance().getUserName(); 18 | } 19 | 20 | public void insertHistory(List histories) { 21 | mDBController.insertHistory(histories); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/search/BlockerTool.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.search; 2 | 3 | import android.content.Context; 4 | import android.content.res.Resources; 5 | 6 | import com.example.fruit.R; 7 | 8 | public class BlockerTool { 9 | public static boolean isBlock(Context context, String url) { 10 | Resources resources = context.getResources(); 11 | String [] urlsToBeBlocked = resources.getStringArray(R.array.BlockUrl); 12 | for (String adURL : urlsToBeBlocked) { 13 | if (matchURL(url, adURL)) { 14 | return true; 15 | } 16 | } 17 | return false; 18 | } 19 | 20 | private static boolean matchURL(String sourceURL, String targetURL) { 21 | return sourceURL.contains(targetURL); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/history/HistoryModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.history; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.History; 5 | import com.example.fruit.dao.DBController; 6 | 7 | import java.util.List; 8 | 9 | public class HistoryModel { 10 | private DBController mDBController; 11 | 12 | public HistoryModel() { 13 | mDBController = DBController.getInstance(MyAppliaction.getContext()); 14 | } 15 | 16 | public List getAllHistory() { 17 | return mDBController.getAll(); 18 | } 19 | 20 | public void deleteAll() { 21 | mDBController.deleteAllHistory(); 22 | } 23 | 24 | public void deleteSelected(List toBeDeleted) { 25 | mDBController.deleteSelectedHistory(toBeDeleted); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | Fruit 4 | Project Fruit-Browser created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.buildship.core.gradleprojectbuilder 10 | 11 | 12 | 13 | 14 | 15 | org.eclipse.buildship.core.gradleprojectnature 16 | 17 | 18 | 19 | 0 20 | 21 | 30 22 | 23 | org.eclipse.core.resources.regexFilterMatcher 24 | node_modules|.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__ 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/login/LoginModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.login; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.User; 5 | import com.example.fruit.dao.DBController; 6 | 7 | public class LoginModel { 8 | private DBController mDbController; 9 | private User mUser; 10 | 11 | public LoginModel() { 12 | mUser = new User(null, "", "", "",null); 13 | mDbController = DBController.getInstance(MyAppliaction.getContext()); 14 | } 15 | 16 | public User checkUserAndPassword () { 17 | return mDbController.checkUserAndPassword(mUser.getName(), mUser.getPassword()); 18 | } 19 | 20 | public void setUser(String username, String password) { 21 | mUser.setName(username); 22 | mUser.setPassword(password); 23 | mUser.setCustomizeName(username); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/src/androidTest/java/com/example/fruit/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | import android.content.Context; 4 | 5 | import androidx.test.platform.app.InstrumentationRegistry; 6 | import androidx.test.ext.junit.runners.AndroidJUnit4; 7 | 8 | import org.junit.Test; 9 | import org.junit.runner.RunWith; 10 | 11 | import static org.junit.Assert.*; 12 | 13 | /** 14 | * Instrumented test, which will execute on an Android device. 15 | * 16 | * @see Testing documentation 17 | */ 18 | @RunWith(AndroidJUnit4.class) 19 | public class ExampleInstrumentedTest { 20 | @Test 21 | public void useAppContext() { 22 | // Context of the app under test. 23 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 24 | assertEquals("com.example.fruit", appContext.getPackageName()); 25 | } 26 | } -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/register/RegisterModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.register; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.User; 5 | import com.example.fruit.dao.DBController; 6 | 7 | public class RegisterModel { 8 | private DBController mDBController; 9 | private User mUser; 10 | 11 | public RegisterModel() { 12 | mUser = new User(null, "", "", "",null); 13 | mDBController = DBController.getInstance(MyAppliaction.getContext()); 14 | } 15 | 16 | public boolean checkUserExist(String username) { 17 | return mDBController.checkUserExist(username); 18 | } 19 | 20 | public void insertUser(String username, String password) { 21 | mUser.setName(username); 22 | mUser.setPassword(password); 23 | mUser.setCustomizeName(username); 24 | mDBController.insertUser(mUser); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/MyAppliaction.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | import android.app.Application; 4 | import android.content.Context; 5 | import android.content.res.Configuration; 6 | import android.content.res.Resources; 7 | import android.util.DisplayMetrics; 8 | 9 | import androidx.appcompat.app.AppCompatDelegate; 10 | 11 | import com.example.fruit.utils.Util; 12 | 13 | public class MyAppliaction extends Application { 14 | private static Context sContext; 15 | 16 | @Override 17 | public void onCreate() { 18 | super.onCreate(); 19 | sContext = getApplicationContext(); 20 | //初始化我们的主题模式 21 | // if(Util.getNight()) { 22 | // AppCompatDelegate.setDefaultNightMode(AppCompatDelegate.MODE_NIGHT_YES); 23 | // }; 24 | 25 | } 26 | 27 | public static Context getContext() { 28 | return sContext; 29 | } 30 | 31 | 32 | } 33 | -------------------------------------------------------------------------------- /app/src/main/res/layout/splash_activity.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 13 | 14 | 23 | 24 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/home/QuickModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.home; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.Quick; 5 | import com.example.fruit.dao.DBController; 6 | 7 | import java.util.List; 8 | 9 | public class QuickModel { 10 | private DBController mDbController; 11 | 12 | public QuickModel() { 13 | mDbController = DBController.getInstance(MyAppliaction.getContext()); 14 | } 15 | 16 | public boolean insertQuick(String title, String url) { 17 | return mDbController.insertQuick(title, url); 18 | } 19 | 20 | public List getAllQuick() { 21 | return mDbController.getQuick(); 22 | } 23 | 24 | public void deleteQuick(String title, String url) { 25 | mDbController.deleteQuick(title, url); 26 | } 27 | 28 | public void changeQuick(String title, String url, String newTitle, String newUrl) { 29 | mDbController.changeQuick(title, url, newTitle, newUrl); 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /app/src/main/res/raw/night.css: -------------------------------------------------------------------------------- 1 | 2 | /*所有元素的背景色都设置为黑夜模式,原来使用#201f26(rgb)会影响celltick资讯详情页里列表项的图片显示,这里改用rgba,有0.8的透明度*/ 3 | *, *:before, *:after { 4 | box-sizing: inherit; 5 | background-color: rgba(32, 31, 38, 0.8) !important; 6 | } 7 | 8 | /*背景颜色和一般字体颜色*/ 9 | div,h1,h2,h3,h4,h5,h6,p,body,em,html,link,textarea,form,select,input,span,button,em,menu,aside,table,tr,td,nav,dl,dt,dd,amp-iframe,main{ 10 | /*background-color: rgba(32, 31, 38, 0.8) !important;*/ 11 | color: #888888!important; 12 | border-color: #555555 !important; 13 | text-shadow : 0 0 0 #000; /*去掉文本的阴影效果*/ 14 | } 15 | 16 | /*超链接*/ 17 | a{ 18 | color:#3c5180 !important; 19 | } 20 | 21 | strong { 22 | display: block; 23 | } 24 | 25 | img, iframe, canvas, svg,amp-social-share, 26 | embed[type='application/x-shockwave-flash'], 27 | object[type='application/x-shockwave-flash'], 28 | *[style*='url('] { 29 | -webkit-filter : opacity(50%); 30 | -ms-filter : opacity(50%); 31 | filter : opacity(50%); 32 | } 33 | -------------------------------------------------------------------------------- /app/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | app 4 | Project app created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.buildship.core.gradleprojectbuilder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.buildship.core.gradleprojectnature 22 | 23 | 24 | 25 | 1633539444081 26 | 27 | 30 28 | 29 | org.eclipse.core.resources.regexFilterMatcher 30 | node_modules|.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__ 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/bean/Collection.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.bean; 2 | 3 | import org.greenrobot.greendao.annotation.Entity; 4 | import org.greenrobot.greendao.annotation.Generated; 5 | 6 | @Entity 7 | public class Collection { 8 | String name; 9 | String url; 10 | String title; 11 | @Generated(hash = 512964657) 12 | public Collection(String name, String url, String title) { 13 | this.name = name; 14 | this.url = url; 15 | this.title = title; 16 | } 17 | @Generated(hash = 1149123052) 18 | public Collection() { 19 | } 20 | 21 | public String getUrl() { 22 | return this.url; 23 | } 24 | public void setUrl(String url) { 25 | this.url = url; 26 | } 27 | public String getTitle() { 28 | return this.title; 29 | } 30 | public void setTitle(String title) { 31 | this.title = title; 32 | } 33 | public String getName() { 34 | return this.name; 35 | } 36 | public void setName(String name) { 37 | this.name = name; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/bean/History.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.bean; 2 | 3 | import org.greenrobot.greendao.annotation.Entity; 4 | import org.greenrobot.greendao.annotation.Generated; 5 | 6 | @Entity 7 | public class History { 8 | private String title; 9 | private String url; 10 | private String time; 11 | @Generated(hash = 1019327556) 12 | public History(String title, String url, String time) { 13 | this.title = title; 14 | this.url = url; 15 | this.time = time; 16 | } 17 | @Generated(hash = 869423138) 18 | public History() { 19 | } 20 | public String getTitle() { 21 | return this.title; 22 | } 23 | public void setTitle(String title) { 24 | this.title = title; 25 | } 26 | public String getUrl() { 27 | return this.url; 28 | } 29 | public void setUrl(String url) { 30 | this.url = url; 31 | } 32 | public String getTime() { 33 | return this.time; 34 | } 35 | public void setTime(String time) { 36 | this.time = time; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/collection/CollectionModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.collection; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.bean.Collection; 5 | import com.example.fruit.dao.DBController; 6 | import com.example.fruit.utils.Util; 7 | 8 | import java.util.List; 9 | 10 | public class CollectionModel { 11 | private DBController mDBController; 12 | private String mUsername; 13 | 14 | public CollectionModel() { 15 | mDBController = DBController.getInstance(MyAppliaction.getContext()); 16 | mUsername = Util.getInstance().getUserName(); 17 | } 18 | 19 | public List getCollection() { 20 | if (mUsername != null) { 21 | return mDBController.getUserCollection(mUsername); 22 | } 23 | return null; 24 | } 25 | 26 | public void deleteAllUserCollection() { 27 | mDBController.deleteAllCollection(mUsername); 28 | } 29 | 30 | public void deleteSelectedUserCollection(List toBeDeleted) { 31 | mDBController.deleteSelectedCollection(toBeDeleted); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/bean/Quick.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.bean; 2 | 3 | import org.greenrobot.greendao.annotation.Entity; 4 | import org.greenrobot.greendao.annotation.Generated; 5 | import org.greenrobot.greendao.annotation.Id; 6 | 7 | @Entity 8 | public class Quick { 9 | @Id(autoincrement = true) 10 | private Long id; 11 | private String title; 12 | private String url; 13 | @Generated(hash = 501286242) 14 | public Quick(Long id, String title, String url) { 15 | this.id = id; 16 | this.title = title; 17 | this.url = url; 18 | } 19 | @Generated(hash = 258038605) 20 | public Quick() { 21 | } 22 | public String getTitle() { 23 | return this.title; 24 | } 25 | public void setTitle(String title) { 26 | this.title = title; 27 | } 28 | public String getUrl() { 29 | return this.url; 30 | } 31 | public void setUrl(String url) { 32 | this.url = url; 33 | } 34 | public Long getId() { 35 | return this.id; 36 | } 37 | public void setId(Long id) { 38 | this.id = id; 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx2048m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app"s APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/setting/SettingsModel.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.setting; 2 | 3 | import com.example.fruit.MyAppliaction; 4 | import com.example.fruit.dao.DBController; 5 | import com.example.fruit.utils.Util; 6 | 7 | public class SettingsModel { 8 | private DBController mDBController; 9 | private String mUsername; 10 | 11 | public SettingsModel() { 12 | mDBController = new DBController(MyAppliaction.getContext()); 13 | mUsername = Util.getInstance().getUserName(); 14 | } 15 | 16 | public void changeName(String newName) { 17 | mDBController.changeUsername(mUsername, newName); 18 | } 19 | 20 | public void setProfile(String profile) { 21 | mDBController.setProfile(mUsername, profile); 22 | } 23 | public String getProfile(){ 24 | return mDBController.getProfile(mUsername); 25 | } 26 | 27 | public boolean checkPassword(String password) { 28 | return mDBController.checkUserAndPassword(mUsername, password) != null; 29 | } 30 | 31 | public void changePassword(String newPassword) { 32 | mDBController.changeUsername(mUsername, newPassword); 33 | } 34 | 35 | public void deleteUser() { 36 | mDBController.deleteUser(mUsername); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/MainPresenter.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit; 2 | 3 | import android.os.Handler; 4 | import android.os.Message; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | import com.example.fruit.utils.Util; 9 | 10 | public class MainPresenter { 11 | private static final int ADD_COLLECTION = 0; 12 | 13 | private MainModel mMainModel; 14 | private MainView mMainView; 15 | 16 | private Handler mHandler = new Handler() { 17 | @Override 18 | public void handleMessage(@NonNull Message msg) { 19 | switch (msg.what) { 20 | case ADD_COLLECTION: 21 | mMainView.showAddCollection(); 22 | break; 23 | } 24 | } 25 | }; 26 | 27 | public MainPresenter(MainView mainView) { 28 | mMainModel = new MainModel(); 29 | mMainView = mainView; 30 | } 31 | 32 | 33 | public void addCollection(String url, String title) { 34 | new Thread(new Runnable() { 35 | @Override 36 | public void run() { 37 | mMainModel.addCollection(url, title); 38 | Message message = new Message(); 39 | message.what = ADD_COLLECTION; 40 | mHandler.sendMessage(message); 41 | } 42 | }).start(); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /.idea/jarRepositories.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 9 | 10 | 14 | 15 | 19 | 20 | 24 | 25 | 29 | 30 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/collection/CollectionItem.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.collection; 2 | 3 | public class CollectionItem { 4 | 5 | public String imgPath;//图片地址 6 | private String title;//收藏名字 7 | private String url;//收藏URL 8 | private boolean isSelected;//是否选中 9 | 10 | 11 | public String getImgPath() { 12 | return imgPath; 13 | } 14 | 15 | public void setImgPath(String imgPath) { 16 | this.imgPath = imgPath; 17 | } 18 | 19 | 20 | public String getTitle() { 21 | return title; 22 | } 23 | 24 | public void setTitle(String title) { 25 | this.title = title; 26 | } 27 | 28 | public String getUrl() { 29 | return url; 30 | } 31 | 32 | public void setUrl(String url) { 33 | this.url = url; 34 | } 35 | 36 | public boolean isSelected() { 37 | return isSelected; 38 | } 39 | 40 | public void setSelected(boolean selected) { 41 | isSelected = selected; 42 | } 43 | 44 | 45 | 46 | public CollectionItem() { 47 | 48 | } 49 | 50 | public CollectionItem(String title, String url,String imgPath) { 51 | this.title = title; 52 | this.url = url; 53 | this.imgPath = imgPath; 54 | } 55 | 56 | @Override 57 | public String toString() { 58 | return "HistoryItem{" + 59 | "title='" + title + '\'' + 60 | ", url=" + url + 61 | '}'; 62 | } 63 | 64 | 65 | } 66 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/home/QuickPage.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.home; 2 | 3 | import org.greenrobot.greendao.annotation.Entity; 4 | import org.greenrobot.greendao.annotation.Generated; 5 | 6 | public class QuickPage { 7 | private String url; 8 | private String title; 9 | private int imgPathId;//本地图片就是ID 10 | private String imgPathUrl;//网页图片就是string 11 | private boolean isAddIcon;//判断是添加的图标还是编辑图标 12 | 13 | public QuickPage(String title, String url, int imgPathId, String imgPathUrl, boolean isAddIcon) { 14 | this.url = url; 15 | this.title = title; 16 | this.imgPathId = imgPathId; 17 | this.imgPathUrl = imgPathUrl; 18 | this.isAddIcon = isAddIcon; 19 | } 20 | 21 | public QuickPage() { 22 | } 23 | 24 | public String getUrl() { 25 | return this.url; 26 | } 27 | public void setUrl(String url) { 28 | this.url = url; 29 | } 30 | public String getTitle() { 31 | return this.title; 32 | } 33 | public void setTitle(String title) { 34 | this.title = title; 35 | } 36 | public int getImgPathId() { 37 | return this.imgPathId; 38 | } 39 | public void setImgPathId(int imgPathId) { 40 | this.imgPathId = imgPathId; 41 | } 42 | public String getImgPathUrl() { 43 | return this.imgPathUrl; 44 | } 45 | public void setImgPathUrl(String imgPathUrl) { 46 | this.imgPathUrl = imgPathUrl; 47 | } 48 | 49 | public boolean getIsAddIcon() { 50 | return this.isAddIcon; 51 | } 52 | public void setIsAddIcon(boolean isAddIcon) { 53 | this.isAddIcon = isAddIcon; 54 | } 55 | 56 | } 57 | -------------------------------------------------------------------------------- /app/src/main/res/layout/search_fragment.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 12 | 13 | 20 | 26 | 34 | 35 | 36 | 40 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/register/RegisterPresenter.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.register; 2 | 3 | import android.os.Handler; 4 | import android.os.Message; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | public class RegisterPresenter { 9 | private static final int REGISTER_SUCCESSFULLY = 1; 10 | private static final int USERNAME_EXIST = 2; 11 | private RegisterModel mRegisterModel; 12 | private RegisterView mRegisterView; 13 | private Handler mHandler = new Handler() { 14 | @Override 15 | public void handleMessage(@NonNull Message msg) { 16 | switch (msg.what) { 17 | case REGISTER_SUCCESSFULLY: 18 | mRegisterView.showRegisterSuccessfully(); 19 | break; 20 | case USERNAME_EXIST: 21 | mRegisterView.showUsernameExist(); 22 | break; 23 | } 24 | } 25 | }; 26 | 27 | public RegisterPresenter(RegisterView registerView) { 28 | mRegisterModel = new RegisterModel(); 29 | mRegisterView = registerView; 30 | } 31 | 32 | public void register(String username, String password) { 33 | new Thread(new Runnable() { 34 | @Override 35 | public void run() { 36 | boolean res = mRegisterModel.checkUserExist(username); 37 | Message message = new Message(); 38 | if (res) { 39 | message.what = USERNAME_EXIST; 40 | } else { 41 | mRegisterModel.insertUser(username, password); 42 | message.what = REGISTER_SUCCESSFULLY; 43 | } 44 | mHandler.sendMessage(message); 45 | } 46 | }).start(); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.aar 4 | *.ap_ 5 | *.aab 6 | 7 | # Files for the ART/Dalvik VM 8 | *.dex 9 | 10 | # Java class files 11 | *.class 12 | 13 | # Generated files 14 | bin/ 15 | gen/ 16 | out/ 17 | # Uncomment the following line in case you need and you don't have the release build type files in your app 18 | # release/ 19 | 20 | # Gradle files 21 | .gradle/ 22 | build/ 23 | 24 | # Local configuration file (sdk path, etc) 25 | local.properties 26 | 27 | # Proguard folder generated by Eclipse 28 | proguard/ 29 | 30 | # Log Files 31 | *.log 32 | 33 | # Android Studio Navigation editor temp files 34 | .navigation/ 35 | 36 | # Android Studio captures folder 37 | captures/ 38 | 39 | # IntelliJ 40 | *.iml 41 | .idea/workspace.xml 42 | .idea/tasks.xml 43 | .idea/gradle.xml 44 | .idea/assetWizardSettings.xml 45 | .idea/dictionaries 46 | .idea/libraries 47 | # Android Studio 3 in .gitignore file. 48 | .idea/caches 49 | .idea/modules.xml 50 | # Comment next line if keeping position of elements in Navigation Editor is relevant for you 51 | .idea/navEditor.xml 52 | 53 | # Keystore files 54 | # Uncomment the following lines if you do not want to check your keystore files in. 55 | #*.jks 56 | #*.keystore 57 | 58 | # External native build folder generated in Android Studio 2.2 and later 59 | .externalNativeBuild 60 | .cxx/ 61 | 62 | # Google Services (e.g. APIs or Firebase) 63 | # google-services.json 64 | 65 | # Freeline 66 | freeline.py 67 | freeline/ 68 | freeline_project_description.json 69 | 70 | # fastlane 71 | fastlane/report.xml 72 | fastlane/Preview.html 73 | fastlane/screenshots 74 | fastlane/test_output 75 | fastlane/readme.md 76 | 77 | # Version control 78 | vcs.xml 79 | 80 | # lint 81 | lint/intermediates/ 82 | lint/generated/ 83 | lint/outputs/ 84 | lint/tmp/ 85 | # lint/reports/ 86 | -------------------------------------------------------------------------------- /app/src/main/java/com/example/fruit/login/LoginPresenter.java: -------------------------------------------------------------------------------- 1 | package com.example.fruit.login; 2 | 3 | import android.os.Handler; 4 | import android.os.Message; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | import com.example.fruit.bean.User; 9 | 10 | public class LoginPresenter { 11 | private static final int LOGIN_SUCCESSFULLY = 1; 12 | private static final int LOGIN_FAILED = 2; 13 | private LoginModel mLoginModel; 14 | private LoginView mLoginView; 15 | private User mUser; 16 | 17 | private Handler mHandler = new Handler() { 18 | @Override 19 | public void handleMessage(@NonNull Message msg) { 20 | switch (msg.what) { 21 | case LOGIN_SUCCESSFULLY: 22 | mLoginView.showLoginSuccessfully(mUser); 23 | break; 24 | case LOGIN_FAILED: 25 | mLoginView.showLoginFailed(); 26 | break; 27 | } 28 | } 29 | }; 30 | 31 | public LoginPresenter(LoginView loginView) { 32 | mLoginModel = new LoginModel(); 33 | mLoginView = loginView; 34 | } 35 | 36 | public void login(String username, String password) { 37 | mLoginModel.setUser(username, password); 38 | new Thread(new Runnable() { 39 | @Override 40 | public void run() { 41 | User res = mLoginModel.checkUserAndPassword(); 42 | Message message = new Message(); 43 | if (res != null) { 44 | mUser = res; 45 | message.what = LOGIN_SUCCESSFULLY; 46 | } else { 47 | message.what = LOGIN_FAILED; 48 | } 49 | mHandler.sendMessage(message); 50 | } 51 | }).start(); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | 15 | 18 | 21 | 22 | 23 | 24 | 30 | -------------------------------------------------------------------------------- /app/src/main/res/layout/confirm_window.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | 21 | 25 | 26 | 27 |