├── .github └── workflows │ └── codeberg-mirror.yml ├── .gitignore ├── .idea ├── .gitignore ├── .name ├── compiler.xml ├── gradle.xml ├── inspectionProfiles │ └── Project_Default.xml ├── misc.xml ├── render.experimental.xml └── vcs.xml ├── COPYING ├── README.md ├── app ├── .gitignore ├── .signing │ ├── app-debug.prop │ ├── app-example.prop │ └── openvk-debug.jks ├── build.gradle ├── proguard-rules.pro └── src │ └── main │ ├── AndroidManifest.xml │ ├── java │ └── uk │ │ └── openvk │ │ └── android │ │ └── refresh │ │ ├── Global.java │ │ ├── OvkApplication.java │ │ ├── api │ │ ├── OpenVKAPI.java │ │ ├── TrackingRequestBody.java │ │ ├── attachments │ │ │ ├── Attachment.java │ │ │ ├── CommonAttachment.java │ │ │ ├── PhotoAttachment.java │ │ │ ├── PollAttachment.java │ │ │ └── VideoAttachment.java │ │ ├── counters │ │ │ ├── AccountCounters.java │ │ │ └── PostCounters.java │ │ ├── entities │ │ │ ├── Account.java │ │ │ ├── Authorization.java │ │ │ ├── Comment.java │ │ │ ├── Conversation.java │ │ │ ├── Error.java │ │ │ ├── Friend.java │ │ │ ├── Group.java │ │ │ ├── InstanceAdmin.java │ │ │ ├── InstanceLink.java │ │ │ ├── InstanceStatistics.java │ │ │ ├── LongPollServer.java │ │ │ ├── Message.java │ │ │ ├── Note.java │ │ │ ├── Ovk.java │ │ │ ├── OvkExpandableText.java │ │ │ ├── OvkLink.java │ │ │ ├── Photo.java │ │ │ ├── PhotoAlbum.java │ │ │ ├── PollAnswer.java │ │ │ ├── RepostInfo.java │ │ │ ├── User.java │ │ │ ├── UserPostInfo.java │ │ │ ├── VideoFiles.java │ │ │ ├── WallPost.java │ │ │ └── WallPostSource.java │ │ ├── enumerations │ │ │ └── HandlerMessages.java │ │ ├── interfaces │ │ │ └── OvkAPIListeners.java │ │ ├── models │ │ │ ├── Friends.java │ │ │ ├── Groups.java │ │ │ ├── Likes.java │ │ │ ├── Messages.java │ │ │ ├── Newsfeed.java │ │ │ ├── Notes.java │ │ │ ├── PhotoUploadParams.java │ │ │ ├── Photos.java │ │ │ ├── Users.java │ │ │ └── Wall.java │ │ └── wrappers │ │ │ ├── DownloadManager.java │ │ │ ├── JSONParser.java │ │ │ ├── NotificationManager.java │ │ │ ├── OvkAPIWrapper.java │ │ │ └── UploadManager.java │ │ ├── longpoll_api │ │ ├── MessageEvent.java │ │ └── wrappers │ │ │ └── LongPollWrapper.java │ │ ├── receivers │ │ ├── LongPollReceiver.java │ │ └── OvkAPIReceiver.java │ │ ├── services │ │ ├── AuthenticatorService.java │ │ └── LongPollService.java │ │ ├── ui │ │ ├── FragmentNavigator.java │ │ ├── core │ │ │ ├── activities │ │ │ │ ├── AppActivity.java │ │ │ │ ├── AuthActivity.java │ │ │ │ ├── ConversationActivity.java │ │ │ │ ├── FriendsIntentActivity.java │ │ │ │ ├── GroupIntentActivity.java │ │ │ │ ├── MainActivity.java │ │ │ │ ├── MainSettingsActivity.java │ │ │ │ ├── NewPostActivity.java │ │ │ │ ├── PhotoViewerActivity.java │ │ │ │ ├── ProfileIntentActivity.java │ │ │ │ ├── QuickSearchActivity.java │ │ │ │ ├── VideoPlayerActivity.java │ │ │ │ ├── WallPostActivity.java │ │ │ │ └── base │ │ │ │ │ └── NetworkActivity.java │ │ │ ├── enumerations │ │ │ │ ├── FontFamily.java │ │ │ │ ├── PublicPageCounters.java │ │ │ │ └── UiMessages.java │ │ │ ├── fragments │ │ │ │ ├── app │ │ │ │ │ ├── AboutApplicationFragment.java │ │ │ │ │ ├── BlankFragment.java │ │ │ │ │ ├── CommunityFragment.java │ │ │ │ │ ├── FriendsFragment.java │ │ │ │ │ ├── GroupsFragment.java │ │ │ │ │ ├── MessagesFragment.java │ │ │ │ │ ├── NewsfeedFragment.java │ │ │ │ │ ├── ProfileFragment.java │ │ │ │ │ ├── friends │ │ │ │ │ │ ├── FriendRequestsFragment.java │ │ │ │ │ │ └── FriendsListFragment.java │ │ │ │ │ ├── pub_pages │ │ │ │ │ │ ├── AboutFragment.java │ │ │ │ │ │ └── WallFragment.java │ │ │ │ │ └── settings │ │ │ │ │ │ ├── MainSettingsFragment.java │ │ │ │ │ │ ├── PersonalizationFragment.java │ │ │ │ │ │ └── VideoSettingsFragment.java │ │ │ │ └── auth │ │ │ │ │ ├── AuthFragment.java │ │ │ │ │ ├── AuthProgressFragment.java │ │ │ │ │ └── AuthTwoFactorFragment.java │ │ │ └── listeners │ │ │ │ ├── AppBarStateChangeListener.java │ │ │ │ ├── OnKeyboardStateListener.java │ │ │ │ ├── OnRecyclerScrollListener.java │ │ │ │ └── OnScrollListener.java │ │ ├── list │ │ │ ├── adapters │ │ │ │ ├── CommentsAdapter.java │ │ │ │ ├── ConversationsAdapter.java │ │ │ │ ├── DialogSingleChoiceAdapter.java │ │ │ │ ├── FriendRequestsAdapter.java │ │ │ │ ├── FriendsAdapter.java │ │ │ │ ├── GroupsAdapter.java │ │ │ │ ├── MessagesAdapter.java │ │ │ │ ├── NewsfeedAdapter.java │ │ │ │ ├── NewsfeedToolbarSpinnerAdapter.java │ │ │ │ └── PublicPageAboutAdapter.java │ │ │ ├── items │ │ │ │ ├── PublicPageAboutItem.java │ │ │ │ └── ToolbarSpinnerItem.java │ │ │ └── sections │ │ │ │ ├── CommunitiesSearchSection.java │ │ │ │ └── PeopleSearchSection.java │ │ ├── text │ │ │ └── CenteredImageSpan.java │ │ ├── util │ │ │ ├── OvkAlertDialogBuilder.java │ │ │ └── glide │ │ │ │ └── GlideShh.java │ │ ├── view │ │ │ ├── InfinityRecyclerView.java │ │ │ ├── InfinityScrollView.java │ │ │ ├── TightTextView.java │ │ │ ├── ZoomableImageView.java │ │ │ ├── layouts │ │ │ │ ├── ErrorLayout.java │ │ │ │ ├── PhotoAttachmentLayout.java │ │ │ │ ├── ProfileHeader.java │ │ │ │ ├── ProgressLayout.java │ │ │ │ ├── SendTextBottomPanel.java │ │ │ │ ├── VideoAttachmentLayout.java │ │ │ │ └── XConstraintLayout.java │ │ │ └── pager │ │ │ │ └── adapters │ │ │ │ ├── FriendsPagerAdapter.java │ │ │ │ └── PublicPagerAdapter.java │ │ └── wrappers │ │ │ ├── LocaleContextWrapper.java │ │ │ └── TypefaceUtil.java │ │ └── utils │ │ ├── AccountAuthentificator.java │ │ ├── LibraryLoader.java │ │ └── RealPathUtil.java │ └── res │ ├── color-night │ └── nv_items.xml │ ├── color │ ├── bnv_items.xml │ ├── counter_btn.xml │ └── nv_items.xml │ ├── drawable-anydpi-v24 │ └── ic_ovk_notif.xml │ ├── drawable-hdpi │ ├── ic_ovk_notif.png │ ├── photo_loading_error.png │ └── warning.png │ ├── drawable-mdpi │ └── ic_ovk_notif.png │ ├── drawable-night │ ├── ic_openvk_full_logo.xml │ ├── ic_openvk_splash_logo.xml │ └── item_background.xml │ ├── drawable-nodpi │ └── circular_avatar.png │ ├── drawable-xhdpi │ ├── ic_ovk_notif.png │ ├── photo_loading_error.png │ └── warning.png │ ├── drawable-xxhdpi │ └── ic_ovk_notif.png │ ├── drawable │ ├── bottom_shadow.xml │ ├── ic_account.xml │ ├── ic_add.xml │ ├── ic_api.xml │ ├── ic_api_android.xml │ ├── ic_api_default.xml │ ├── ic_api_iphone.xml │ ├── ic_arrow_back.xml │ ├── ic_arrow_drop_down_24.xml │ ├── ic_campaign.xml │ ├── ic_campaign_16.xml │ ├── ic_campaign_18.xml │ ├── ic_campaign_custom.xml │ ├── ic_campaign_custom_18.xml │ ├── ic_chat.xml │ ├── ic_comment.xml │ ├── ic_comment_16.xml │ ├── ic_comment_18.xml │ ├── ic_error.xml │ ├── ic_favorite.xml │ ├── ic_favorite_16.xml │ ├── ic_favorite_18.xml │ ├── ic_favorite_18_accent.xml │ ├── ic_feed.xml │ ├── ic_file_download.xml │ ├── ic_help_outline.xml │ ├── ic_home.xml │ ├── ic_info.xml │ ├── ic_instance.xml │ ├── ic_language.xml │ ├── ic_list_alt.xml │ ├── ic_logout.xml │ ├── ic_menu.xml │ ├── ic_more.xml │ ├── ic_openvk_compact_logo.xml │ ├── ic_openvk_compact_logo_color.xml │ ├── ic_openvk_full_logo.xml │ ├── ic_openvk_splash_logo.xml │ ├── ic_pause_large.xml │ ├── ic_people.xml │ ├── ic_person.xml │ ├── ic_person_add.xml │ ├── ic_person_remove.xml │ ├── ic_personalization.xml │ ├── ic_play.xml │ ├── ic_play_large.xml │ ├── ic_post_add.xml │ ├── ic_search.xml │ ├── ic_send.xml │ ├── ic_settings.xml │ ├── ic_verified.xml │ ├── ic_video_file_large.xml │ ├── ic_video_file_placeholder.xml │ ├── ic_video_library.xml │ ├── ic_warning_amber.xml │ ├── ic_zoom_in_large.xml │ ├── ic_zoom_out_large.xml │ ├── item_background.xml │ └── photo_placeholder.xml │ ├── font │ ├── inter.xml │ ├── inter_bold.ttf │ ├── inter_extrabold.ttf │ ├── inter_extralight.ttf │ ├── inter_light.ttf │ ├── inter_medium.ttf │ ├── inter_regular.ttf │ ├── open_sans.xml │ ├── open_sans_bold.ttf │ ├── open_sans_bold_italic.ttf │ ├── open_sans_italic.ttf │ ├── open_sans_light.ttf │ ├── open_sans_light_italic.ttf │ ├── open_sans_regular.ttf │ ├── raleway.xml │ ├── raleway_bold.ttf │ ├── raleway_bold_italic.ttf │ ├── raleway_italic.ttf │ ├── raleway_light.ttf │ ├── raleway_light_italic.ttf │ ├── raleway_medium.ttf │ ├── raleway_medium_italic.ttf │ ├── raleway_regular.ttf │ ├── roboto.xml │ ├── roboto_bold.ttf │ ├── roboto_bold_italic.ttf │ ├── roboto_italic.ttf │ ├── roboto_light.ttf │ ├── roboto_light_italic.ttf │ ├── roboto_medium.ttf │ ├── roboto_medium_italic.ttf │ ├── roboto_regular.ttf │ ├── rubik.xml │ ├── rubik_bold.ttf │ ├── rubik_bold_italic.ttf │ ├── rubik_italic.ttf │ ├── rubik_light.ttf │ ├── rubik_light_italic.ttf │ ├── rubik_medium.ttf │ ├── rubik_medium_italic.ttf │ └── rubik_regular.ttf │ ├── layout-night │ ├── activity_app.xml │ ├── activity_conversation.xml │ ├── activity_intent.xml │ ├── activity_new_post.xml │ ├── activity_photo_viewer.xml │ ├── activity_search.xml │ ├── activity_video_player.xml │ ├── activity_wall_post_watch.xml │ ├── attachment_video.xml │ ├── auth_screen.xml │ ├── msg_incoming.xml │ └── msg_outcoming.xml │ ├── layout-sw600dp-land-night │ └── activity_app.xml │ ├── layout-sw600dp-land │ └── activity_app.xml │ ├── layout-sw600dp-night │ └── activity_app.xml │ ├── layout-sw600dp │ ├── activity_app.xml │ ├── fragment_auth.xml │ ├── fragment_auth_2fa.xml │ ├── fragment_newsfeed.xml │ └── tab_wall.xml │ ├── layout │ ├── actionbar_spinner_dropdown_item.xml │ ├── actionbar_spinner_item.xml │ ├── activity_app.xml │ ├── activity_conversation.xml │ ├── activity_intent.xml │ ├── activity_main.xml │ ├── activity_new_post.xml │ ├── activity_photo_viewer.xml │ ├── activity_search.xml │ ├── activity_video_player.xml │ ├── activity_wall_post_watch.xml │ ├── app_host.xml │ ├── attachment_photo.xml │ ├── attachment_poll.xml │ ├── attachment_video.xml │ ├── auth_progress.xml │ ├── auth_screen.xml │ ├── blank_fragment.xml │ ├── blank_layout.xml │ ├── dialog_about_instance.xml │ ├── dialog_choose_list.xml │ ├── drawer_header.xml │ ├── fragment_about_app.xml │ ├── fragment_auth.xml │ ├── fragment_auth_2fa.xml │ ├── fragment_community.xml │ ├── fragment_conversations.xml │ ├── fragment_friends.xml │ ├── fragment_groups.xml │ ├── fragment_newsfeed.xml │ ├── fragment_profile.xml │ ├── layout_error.xml │ ├── layout_pref_notif.xml │ ├── layout_warn_message.xml │ ├── list_item_comments.xml │ ├── list_item_conversations.xml │ ├── list_item_friend_requests.xml │ ├── list_item_friends.xml │ ├── list_item_groups.xml │ ├── list_item_newsfeed.xml │ ├── list_item_pubpage_about.xml │ ├── list_item_search_result.xml │ ├── list_item_section.xml │ ├── list_item_single_choice.xml │ ├── messages_history_datestamp.xml │ ├── msg_incoming.xml │ ├── msg_outcoming.xml │ ├── panel_sendtext_bottom.xml │ ├── profile_header.xml │ ├── progress.xml │ ├── tab_about_page.xml │ ├── tab_friend_requests.xml │ ├── tab_friends.xml │ └── tab_wall.xml │ ├── menu │ ├── app_auth.xml │ ├── app_bottom_nav.xml │ ├── app_main.xml │ ├── app_nav_drawer.xml │ ├── app_newpost.xml │ ├── group.xml │ ├── photo_viewer.xml │ └── profile.xml │ ├── mipmap-anydpi-v26 │ ├── ic_launcher.xml │ └── ic_launcher_round.xml │ ├── mipmap-hdpi │ ├── ic_launcher.png │ ├── ic_launcher_foreground.png │ └── ic_launcher_round.png │ ├── mipmap-mdpi │ ├── ic_launcher.png │ ├── ic_launcher_foreground.png │ └── ic_launcher_round.png │ ├── mipmap-xhdpi │ ├── ic_launcher.png │ ├── ic_launcher_foreground.png │ └── ic_launcher_round.png │ ├── mipmap-xxhdpi │ ├── ic_launcher.png │ ├── ic_launcher_foreground.png │ └── ic_launcher_round.png │ ├── mipmap-xxxhdpi │ ├── ic_launcher.png │ ├── ic_launcher_foreground.png │ └── ic_launcher_round.png │ ├── navigation │ ├── bottom_nav.xml │ └── drawer.xml │ ├── values-land │ └── dimens.xml │ ├── values-night-v31 │ └── themes.xml │ ├── values-night │ ├── colors.xml │ └── themes.xml │ ├── values-ru-v31 │ └── arrays.xml │ ├── values-ru │ ├── arrays.xml │ ├── notifications.xml │ └── strings.xml │ ├── values-uk-v31 │ └── arrays.xml │ ├── values-uk │ ├── arrays.xml │ └── strings.xml │ ├── values-v31 │ ├── arrays.xml │ └── themes.xml │ ├── values-w1240dp │ └── dimens.xml │ ├── values-w600dp │ └── dimens.xml │ ├── values │ ├── arrays.xml │ ├── attrs.xml │ ├── colors.xml │ ├── dimens.xml │ ├── fonts.xml │ ├── ic_launcher_background.xml │ ├── instances.xml │ ├── notifications.xml │ ├── preloaded_fonts.xml │ ├── strings.xml │ └── themes.xml │ └── xml │ ├── app_more_pref.xml │ ├── app_video_pref.xml │ ├── locales.xml │ ├── main_pref.xml │ └── person_perf.xml ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle /.github/workflows/codeberg-mirror.yml: -------------------------------------------------------------------------------- 1 | name: Codeberg Mirroring 2 | 3 | on: push 4 | 5 | jobs: 6 | to_codeberg: 7 | runs-on: ubuntu-latest 8 | steps: 9 | - uses: actions/checkout@v2 10 | with: 11 | fetch-depth: 0 12 | - uses: pixta-dev/repository-mirroring-action@v1 13 | with: 14 | target_repo_url: "git@codeberg.org:openvk/mobile-android-refresh.git" 15 | ssh_private_key: ${{ secrets.CODEBERG_MIRRORSSH }} 16 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/caches 5 | /.idea/libraries 6 | /.idea/modules.xml 7 | /.idea/workspace.xml 8 | /.idea/navEditor.xml 9 | /.idea/assetWizardSettings.xml 10 | .DS_Store 11 | /build 12 | /captures 13 | .externalNativeBuild 14 | .cxx 15 | local.properties 16 | .idea/deploymentTargetDropDown.xml 17 | -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | -------------------------------------------------------------------------------- /.idea/.name: -------------------------------------------------------------------------------- 1 | OpenVK -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 19 | 20 | -------------------------------------------------------------------------------- /.idea/inspectionProfiles/Project_Default.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | -------------------------------------------------------------------------------- /.idea/render.experimental.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # OpenVK Refresh 2 | 3 | Author: [Dmitry Tretyakov](https://github.com/tretdm) 4 | 5 | Yet another mobile client in Material Design 2 with Monet theme support for Android 11-.\ 6 | _Powered by OpenVK API. Android 5.0+ supported._ 7 | 8 | We will be happy to accept your bugreports in [our bug-tracker](https://github.com/orgs/openvk/projects/1). 9 | 10 | ## Download APK 11 | * **via [Telegram channel](https://t.me/+nPLHBZqAsFlhYmIy)** 12 | 13 | ## Building 14 | You can build your app from source in Android Studio current version. [Download](https://developer.android.com/studio) 15 | 16 | ## Used Libraries 17 | _OpenVK API client and some UI layouts based on [OpenVK Legacy](https://github.com/openvk/mobile-android-legacy) (GNU Affero GPL 3.0+)_ 18 | 19 | 1. [AndroidX](https://developer.android.com/jetpack/androidx) (Apache License 2.0) 20 | 2. [Material Design 2 components](https://m2.material.io) (Apache License 2.0) 21 | 3. [Glide](https://bumptech.github.io/glide/) (BSD 2-Clause License) 22 | 4. [MonetCompat](https://github.com/KieronQuinn/MonetCompat) (X11 License) 23 | 5. [OkHttp](https://square.github.io/okhttp/) (Apache License 2.0) 24 | 6. [libVLC](https://www.videolan.org/vlc/libvlc.html) (LGPL 2.1) 25 | 7. [MaterialSearchBar](https://github.com/mancj/MaterialSearchBar) (X11 License) 26 | 8. [SectionedRecyclerViewAdapter](https://github.com/luizgrp/SectionedRecyclerViewAdapter) (X11 License) 27 | 28 | ## OpenVK Refresh License 29 | [GNU (Affero) GPL v3.0](https://github.com/openvk/mobile-android-refresh/blob/main/COPYING) or later version. 30 | 31 | ## Links 32 | [OpenVK API docs](https://docs.ovk.to/openvk_engine/en/api/description/)\ 33 | [OpenVK Mobile](https://ovk.to/app) 34 | 35 | 36 | Get it on Codeberg 37 | 38 | -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build -------------------------------------------------------------------------------- /app/.signing/app-debug.prop: -------------------------------------------------------------------------------- 1 | RELEASE_STORE_FILE=.signing/openvk-debug.jks 2 | RELEASE_STORE_PASSWORD=ovk_debug 3 | RELEASE_KEY_ALIAS=ovk_refresh 4 | RELEASE_KEY_PASSWORD=ovk_debug 5 | -------------------------------------------------------------------------------- /app/.signing/app-example.prop: -------------------------------------------------------------------------------- 1 | // APK signing config file example 2 | 3 | RELEASE_STORE_FILE=openvk.jks 4 | RELEASE_STORE_PASSWORD=[YOUR_STORE_PASSWORD_HERE] 5 | RELEASE_KEY_ALIAS=[YOUR_ALIAS_HERE] 6 | RELEASE_KEY_PASSWORD=[YOUR_KEY_PASSWORD_HERE] 7 | -------------------------------------------------------------------------------- /app/.signing/openvk-debug.jks: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/.signing/openvk-debug.jks -------------------------------------------------------------------------------- /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/uk/openvk/android/refresh/api/attachments/Attachment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.attachments; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class Attachment { 20 | public String type; 21 | public String status; 22 | private Object content; 23 | public Attachment(String type) { 24 | this.type = type; 25 | switch (type) { 26 | case "photo": 27 | content = new PhotoAttachment(); 28 | break; 29 | case "video": 30 | content = new VideoAttachment(); 31 | break; 32 | case "poll": 33 | content = new PollAttachment(); 34 | break; 35 | case "note": 36 | content = new CommonAttachment(); 37 | default: 38 | break; 39 | } 40 | } 41 | 42 | public Object getContent() { 43 | return content; 44 | } 45 | 46 | public void setContent(Object content) { 47 | this.content = content; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/attachments/CommonAttachment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.attachments; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class CommonAttachment { 20 | public String title; 21 | public String text; 22 | public CommonAttachment(String title, String text) { 23 | this.title = title; 24 | this.text = text; 25 | } 26 | 27 | public CommonAttachment() { 28 | 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/Authorization.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import org.json.JSONException; 4 | import org.json.JSONObject; 5 | 6 | import uk.openvk.android.refresh.api.wrappers.JSONParser; 7 | 8 | /** Copyleft © 2022, 2023 OpenVK Team 9 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 10 | * 11 | * This program is free software: you can redistribute it and/or modify it under the terms of 12 | * the GNU Affero General Public License as published by the Free Software Foundation, either 13 | * version 3 of the License, or (at your option) any later version. 14 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 15 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 16 | * See the GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License along with this 19 | * program. If not, see https://www.gnu.org/licenses/. 20 | * 21 | * Source code: https://github.com/openvk/mobile-android-refresh 22 | **/ 23 | 24 | public class Authorization { 25 | private String access_token; 26 | private String response; 27 | private JSONParser jsonParser; 28 | public static String ACCOUNT_TYPE = "uk.openvk.android.refresh.account"; 29 | 30 | public Authorization(String response) { 31 | this.response = response; 32 | jsonParser = new JSONParser(); 33 | JSONObject json = jsonParser.parseJSON(response); 34 | if(json != null) { 35 | try { 36 | this.access_token = json.getString("access_token"); 37 | } catch (JSONException e) { 38 | e.printStackTrace(); 39 | } 40 | } 41 | } 42 | 43 | public String getAccessToken() { 44 | return access_token; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/Comment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import android.graphics.Bitmap; 4 | 5 | import java.util.ArrayList; 6 | 7 | import uk.openvk.android.refresh.api.attachments.Attachment; 8 | import uk.openvk.android.refresh.api.wrappers.JSONParser; 9 | 10 | /** Copyleft © 2022, 2023 OpenVK Team 11 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 12 | * 13 | * This program is free software: you can redistribute it and/or modify it under the terms of 14 | * the GNU Affero General Public License as published by the Free Software Foundation, either 15 | * version 3 of the License, or (at your option) any later version. 16 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 17 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 18 | * See the GNU Affero General Public License for more details. 19 | * 20 | * You should have received a copy of the GNU Affero General Public License along with this 21 | * program. If not, see https://www.gnu.org/licenses/. 22 | * 23 | * Source code: https://github.com/openvk/mobile-android-refresh 24 | **/ 25 | 26 | public class Comment { 27 | public String author; 28 | public long author_id; 29 | public long date; 30 | public String text; 31 | public long id; 32 | public Bitmap avatar; 33 | public String avatar_url; 34 | private JSONParser jsonParser; 35 | public ArrayList attachments; 36 | 37 | public Comment() { 38 | jsonParser = new JSONParser(); 39 | } 40 | 41 | public Comment(int id, long author_id, String author, int date, String text, 42 | ArrayList attachments) { 43 | this.author_id = author_id; 44 | this.author = author; 45 | this.date = date; 46 | this.text = text; 47 | this.id = id; 48 | this.attachments = attachments; 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/InstanceAdmin.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import android.os.Parcel; 4 | import android.os.Parcelable; 5 | 6 | /** Copyleft © 2022, 2023 OpenVK Team 7 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 8 | * 9 | * This program is free software: you can redistribute it and/or modify it under the terms of 10 | * the GNU Affero General Public License as published by the Free Software Foundation, either 11 | * version 3 of the License, or (at your option) any later version. 12 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 13 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 14 | * See the GNU Affero General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU Affero General Public License along with this 17 | * program. If not, see https://www.gnu.org/licenses/. 18 | * 19 | * Source code: https://github.com/openvk/mobile-android-refresh 20 | **/ 21 | 22 | public class InstanceAdmin implements Parcelable { 23 | public String first_name; 24 | public String last_name; 25 | public int id; 26 | public InstanceAdmin(String first_name, String last_name, int id) { 27 | this.first_name = first_name; 28 | this.last_name = last_name; 29 | this.id = id; 30 | } 31 | 32 | protected InstanceAdmin(Parcel in) { 33 | first_name = in.readString(); 34 | last_name = in.readString(); 35 | id = in.readInt(); 36 | } 37 | 38 | public static final Creator CREATOR = new Creator() { 39 | @Override 40 | public InstanceAdmin createFromParcel(Parcel in) { 41 | return new InstanceAdmin(in); 42 | } 43 | 44 | @Override 45 | public InstanceAdmin[] newArray(int size) { 46 | return new InstanceAdmin[size]; 47 | } 48 | }; 49 | 50 | @Override 51 | public int describeContents() { 52 | return 0; 53 | } 54 | 55 | @Override 56 | public void writeToParcel(Parcel parcel, int i) { 57 | parcel.writeString(first_name); 58 | parcel.writeString(last_name); 59 | parcel.writeInt(id); 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/InstanceLink.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class InstanceLink { 20 | public String name; 21 | public String url; 22 | public InstanceLink(String name, String url) { 23 | this.name = name; 24 | this.url = url; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/InstanceStatistics.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class InstanceStatistics { 20 | public long users_count; 21 | public long online_users_count; 22 | public long active_users_count; 23 | public long groups_count; 24 | public long wall_posts_count; 25 | public InstanceStatistics(long users_count, long online_users_count, long active_users_count, 26 | long groups_count, long wall_posts_count) { 27 | this.users_count = users_count; 28 | this.online_users_count = online_users_count; 29 | this.active_users_count = active_users_count; 30 | this.groups_count = groups_count; 31 | this.wall_posts_count = wall_posts_count; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/LongPollServer.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class LongPollServer { 20 | public String address; 21 | public String key; 22 | public int ts; 23 | 24 | public LongPollServer() { 25 | 26 | } 27 | 28 | public LongPollServer(String address, String key, int ts) { 29 | this.address = address; 30 | this.key = key; 31 | this.ts = ts; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/Note.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class Note { 20 | public long id; 21 | public long owner_id; 22 | public long date; 23 | public String content; 24 | public String title; 25 | 26 | public Note(long id, long owner_id, String title, String content, long date) { 27 | this.id = id; 28 | this.owner_id = owner_id; 29 | this.title = title; 30 | this.content = content; 31 | this.date = date; 32 | } 33 | 34 | public Note() { 35 | 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/OvkExpandableText.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import android.text.Spanned; 4 | 5 | /** Copyleft © 2022, 2023 OpenVK Team 6 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 7 | * 8 | * This program is free software: you can redistribute it and/or modify it under the terms of 9 | * the GNU Affero General Public License as published by the Free Software Foundation, either 10 | * version 3 of the License, or (at your option) any later version. 11 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 12 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 13 | * See the GNU Affero General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU Affero General Public License along with this 16 | * program. If not, see https://www.gnu.org/licenses/. 17 | * 18 | * Source code: https://github.com/openvk/mobile-android-refresh 19 | **/ 20 | 21 | public class OvkExpandableText { 22 | public Spanned sp_text; 23 | public long real_length; 24 | public boolean expandable; 25 | public OvkExpandableText(Spanned sp_text, long real_length, long limit) { 26 | this.sp_text = sp_text; 27 | this.real_length = real_length; 28 | expandable = real_length >= limit; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/OvkLink.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class OvkLink { 20 | public String name; 21 | public String screen_name; 22 | public String url; 23 | public OvkLink() { 24 | this.name = ""; 25 | this.screen_name = ""; 26 | this.url = ""; 27 | } 28 | public OvkLink(String name, String screen_name, String url) { 29 | this.name = name; 30 | this.screen_name = screen_name; 31 | this.url = url; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/Photo.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class Photo { 20 | public long id; 21 | public long album_id; 22 | public long owner_id; 23 | public String url; 24 | public String original_url; 25 | 26 | public Photo() { 27 | 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/PhotoAlbum.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import java.util.ArrayList; 4 | 5 | /** Copyleft © 2022, 2023 OpenVK Team 6 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 7 | * 8 | * This program is free software: you can redistribute it and/or modify it under the terms of 9 | * the GNU Affero General Public License as published by the Free Software Foundation, either 10 | * version 3 of the License, or (at your option) any later version. 11 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 12 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 13 | * See the GNU Affero General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU Affero General Public License along with this 16 | * program. If not, see https://www.gnu.org/licenses/. 17 | * 18 | * Source code: https://github.com/openvk/mobile-android-refresh 19 | **/ 20 | 21 | public class PhotoAlbum { 22 | public long[] ids = new long[2]; 23 | public String title; 24 | public long size; 25 | public String thumbnail_url; 26 | public ArrayList photos; 27 | public PhotoAlbum(String str_ids) { 28 | String[] ids = str_ids.split("_"); 29 | try { 30 | if (ids.length >= 2) { 31 | long owner_id = Long.parseLong(ids[0]); 32 | long album_id = Long.parseLong(ids[1]); 33 | this.ids[0] = owner_id; 34 | this.ids[1] = album_id; 35 | } 36 | } catch (Exception ex) { 37 | ex.printStackTrace(); 38 | } 39 | } 40 | 41 | public PhotoAlbum(long owner_id, long album_id) { 42 | ids = new long[2]; 43 | this.ids[0] = owner_id; 44 | this.ids[1] = album_id; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/PollAnswer.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | /** Copyleft © 2022, 2023 OpenVK Team 4 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 5 | * 6 | * This program is free software: you can redistribute it and/or modify it under the terms of 7 | * the GNU Affero General Public License as published by the Free Software Foundation, either 8 | * version 3 of the License, or (at your option) any later version. 9 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 11 | * See the GNU Affero General Public License for more details. 12 | * 13 | * You should have received a copy of the GNU Affero General Public License along with this 14 | * program. If not, see https://www.gnu.org/licenses/. 15 | * 16 | * Source code: https://github.com/openvk/mobile-android-refresh 17 | **/ 18 | 19 | public class PollAnswer { 20 | public int id; 21 | public int rate; 22 | public int votes; 23 | public String text; 24 | public boolean is_voted; 25 | public PollAnswer(int id, int rate, int votes, String text) { 26 | this.id = id; 27 | this.rate = rate; 28 | this.votes = votes; 29 | this.text = text; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/entities/WallPostSource.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.entities; 2 | 3 | import android.os.Parcel; 4 | import android.os.Parcelable; 5 | 6 | /** Copyleft © 2022, 2023 OpenVK Team 7 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 8 | * 9 | * This program is free software: you can redistribute it and/or modify it under the terms of 10 | * the GNU Affero General Public License as published by the Free Software Foundation, either 11 | * version 3 of the License, or (at your option) any later version. 12 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 13 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 14 | * See the GNU Affero General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU Affero General Public License along with this 17 | * program. If not, see https://www.gnu.org/licenses/. 18 | * 19 | * Source code: https://github.com/openvk/mobile-android-refresh 20 | **/ 21 | 22 | public class WallPostSource implements Parcelable { 23 | public String type; 24 | public String platform; 25 | 26 | public WallPostSource(String type, String platform) { 27 | this.type = type; 28 | this.platform = platform; 29 | } 30 | 31 | protected WallPostSource(Parcel in) { 32 | type = in.readString(); 33 | platform = in.readString(); 34 | } 35 | 36 | public static final Creator CREATOR = new Creator() { 37 | @Override 38 | public WallPostSource createFromParcel(Parcel in) { 39 | return new WallPostSource(in); 40 | } 41 | 42 | @Override 43 | public WallPostSource[] newArray(int size) { 44 | return new WallPostSource[size]; 45 | } 46 | }; 47 | 48 | @Override 49 | public int describeContents() { 50 | return 0; 51 | } 52 | 53 | @Override 54 | public void writeToParcel(Parcel dest, int flags) { 55 | dest.writeString(type); 56 | dest.writeString(platform); 57 | } 58 | } 59 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/api/models/PhotoUploadParams.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.api.models; 2 | 3 | import org.json.JSONException; 4 | import org.json.JSONObject; 5 | 6 | import uk.openvk.android.refresh.api.wrappers.JSONParser; 7 | 8 | /** Copyleft © 2022, 2023 OpenVK Team 9 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 10 | * 11 | * This program is free software: you can redistribute it and/or modify it under the terms of 12 | * the GNU Affero General Public License as published by the Free Software Foundation, either 13 | * version 3 of the License, or (at your option) any later version. 14 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 15 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 16 | * See the GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License along with this 19 | * program. If not, see https://www.gnu.org/licenses/. 20 | * 21 | * Source code: https://github.com/openvk/mobile-android-refresh 22 | **/ 23 | 24 | public class PhotoUploadParams { 25 | private JSONParser jsonParser; 26 | public String server; 27 | public String photo; 28 | public String hash; 29 | 30 | public PhotoUploadParams(String response) { 31 | try { 32 | jsonParser = new JSONParser(); 33 | JSONObject json = jsonParser.parseJSON(response); 34 | server = json.getString("server"); 35 | photo = json.getString("photo"); 36 | hash = json.getString("hash"); 37 | } catch (JSONException e) { 38 | e.printStackTrace(); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/receivers/LongPollReceiver.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.legacy.receivers; 2 | 3 | import android.content.BroadcastReceiver; 4 | import android.content.Context; 5 | import android.content.Intent; 6 | import android.util.Log; 7 | 8 | public class LongPollReceiver extends BroadcastReceiver { 9 | 10 | static final String TAG = "LPReceiver"; 11 | 12 | private static LongPollReceiver receiver; 13 | private static int networkType = -1; 14 | private Context ctx; 15 | 16 | public LongPollReceiver(Context ctx) { 17 | this.ctx = ctx; 18 | receiver = this; 19 | } 20 | 21 | public LongPollReceiver() { 22 | receiver = this; 23 | } 24 | 25 | public static LongPollReceiver getInstance() { 26 | if(receiver == null) { 27 | receiver = new LongPollReceiver(null); 28 | } 29 | return receiver; 30 | } 31 | 32 | @Override 33 | public void onReceive(Context context, Intent intent) { 34 | Log.d(TAG, "onReceive " + intent); 35 | } 36 | 37 | } 38 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/services/AuthenticatorService.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.services; 2 | 3 | import android.app.Service; 4 | import android.content.Intent; 5 | import android.os.IBinder; 6 | 7 | import androidx.annotation.Nullable; 8 | import uk.openvk.android.refresh.utils.AccountAuthentificator; 9 | 10 | /** 11 | * Copyleft © 2022, 2023 OpenVK Team 12 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 13 | * 14 | * This program is free software: you can redistribute it and/or modify it under the terms of 15 | * the GNU Affero General Public License as published by the Free Software Foundation, either 16 | * version 3 of the License, or (at your option) any later version. 17 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 18 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 19 | * See the GNU Affero General Public License for more details. 20 | * 21 | * You should have received a copy of the GNU Affero General Public License along with this 22 | * program. If not, see https://www.gnu.org/licenses/. 23 | * 24 | * Source code: https://github.com/openvk/mobile-android-legacy 25 | */ 26 | 27 | public class AuthenticatorService extends Service { 28 | @Nullable 29 | @Override 30 | public IBinder onBind(Intent intent) { 31 | AccountAuthentificator authenticator = new AccountAuthentificator(this); 32 | return authenticator.getIBinder(); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/activities/MainActivity.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.activities; 2 | 3 | import androidx.core.splashscreen.SplashScreen; 4 | 5 | import android.content.Intent; 6 | import android.os.Bundle; 7 | 8 | import com.kieronquinn.monetcompat.app.MonetCompatActivity; 9 | 10 | import uk.openvk.android.refresh.OvkApplication; 11 | 12 | public class MainActivity extends MonetCompatActivity { 13 | 14 | private OvkApplication app; 15 | 16 | @Override 17 | protected void onCreate(Bundle savedInstanceState) { 18 | // Splash screen code 19 | SplashScreen.installSplashScreen(this); 20 | super.onCreate(savedInstanceState); 21 | app = ((OvkApplication) getApplicationContext()); 22 | if(app.getInstancePreferences().getString("server", "") 23 | .length() == 0 || 24 | app.getInstancePreferences().getString("access_token", "") 25 | .length() == 0 || 26 | app.getInstancePreferences().getString("account_password_sha256", "") 27 | .length() == 0) { 28 | Intent intent = new Intent(getApplicationContext(), AuthActivity.class); 29 | startActivity(intent); 30 | finish(); 31 | } else { 32 | Intent intent = new Intent(getApplicationContext(), AppActivity.class); 33 | startActivity(intent); 34 | finish(); 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/enumerations/FontFamily.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.enumerations; 2 | 3 | public class FontFamily { 4 | public static int COMFORTAA = 10; 5 | public static int COMFORTAA_BOLD = 11; 6 | public static int COMFORTAA_LIGHT = 12; 7 | public static int INTER = 20; 8 | public static int INTER_BOLD = 21; 9 | public static int INTER_EXTRABOLD = 22; 10 | public static int INTER_LIGHT = 23; 11 | public static int INTER_MEDIUM = 24; 12 | public static int OPEN_SANS = 30; 13 | public static int OPEN_SANS_BOLD = 31; 14 | public static int OPEN_SANS_BOLD_ITALIC = 32; 15 | public static int OPEN_SANS_ITALIC = 33; 16 | public static int OPEN_SANS_LIGHT = 34; 17 | public static int OPEN_SANS_LIGHT_ITALIC = 35; 18 | public static int RALEWAY = 40; 19 | public static int RALEWAY_BOLD = 41; 20 | public static int RALEWAY_BOLD_ITALIC = 42; 21 | public static int RALEWAY_ITALIC = 43; 22 | public static int RALEWAY_LIGHT = 44; 23 | public static int RALEWAY_LIGHT_ITALIC = 45; 24 | public static int RALEWAY_MEDIUM = 46; 25 | public static int RALEWAY_MEDIUM_ITALIC = 47; 26 | public static int ROBOTO = 50; 27 | public static int ROBOTO_BOLD = 51; 28 | public static int ROBOTO_BOLD_ITALIC = 52; 29 | public static int ROBOTO_LIGHT = 53; 30 | public static int ROBOTO_LIGHT_ITALIC = 54; 31 | public static int ROBOTO_MEDIUM = 55; 32 | public static int ROBOTO_MEDIUM_ITALIC = 56; 33 | public static int RUBIK = 60; 34 | public static int RUBIK_BOLD = 61; 35 | public static int RUBIK_BOLD_ITALIC = 62; 36 | public static int RUBIK_ITALIC = 63; 37 | public static int RUBIK_LIGHT = 64; 38 | public static int RUBIK_LIGHT_ITALIC = 65; 39 | public static int RUBIK_MEDIUM = 66; 40 | public static int RUBIK_MEDIUM_ITALIC = 67; 41 | } 42 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/enumerations/PublicPageCounters.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.enumerations; 2 | 3 | public class PublicPageCounters { 4 | public static int FRIENDS = 0; 5 | public static int GROUPS = 1; 6 | public static int SUBSCRIBERS = 2; 7 | public static int MEMBERS = 3; 8 | } 9 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/enumerations/UiMessages.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.enumerations; 2 | 3 | public class UiMessages { 4 | public static int SHOW_WARNING_DIALOG = 10000; 5 | public static int TOAST_SAVED_TO_MEMORY = 10001; 6 | public static final int UPTIME_QUICK_SEARCH = 10002; 7 | public static int TOAST_SAVE_PHOTO_ERROR = -10000; 8 | } 9 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/fragments/app/BlankFragment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.fragments.app; 2 | 3 | import android.os.Bundle; 4 | 5 | import androidx.fragment.app.Fragment; 6 | 7 | import android.view.LayoutInflater; 8 | import android.view.View; 9 | import android.view.ViewGroup; 10 | 11 | import uk.openvk.android.refresh.R; 12 | 13 | public class BlankFragment extends Fragment { 14 | 15 | 16 | public BlankFragment() { 17 | // Required empty public constructor 18 | } 19 | 20 | @Override 21 | public void onCreate(Bundle savedInstanceState) { 22 | super.onCreate(savedInstanceState); 23 | } 24 | 25 | @Override 26 | public View onCreateView(LayoutInflater inflater, ViewGroup container, 27 | Bundle savedInstanceState) { 28 | return inflater.inflate(R.layout.blank_fragment, container, false); 29 | } 30 | } -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/fragments/auth/AuthProgressFragment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.fragments.auth; 2 | 3 | import android.content.res.ColorStateList; 4 | import android.os.Bundle; 5 | import android.preference.PreferenceManager; 6 | import android.view.LayoutInflater; 7 | import android.view.View; 8 | import android.view.ViewGroup; 9 | import android.widget.ProgressBar; 10 | 11 | import androidx.fragment.app.Fragment; 12 | 13 | import com.kieronquinn.monetcompat.core.MonetCompat; 14 | 15 | import java.util.Objects; 16 | 17 | import uk.openvk.android.refresh.Global; 18 | import uk.openvk.android.refresh.R; 19 | 20 | public class AuthProgressFragment extends Fragment { 21 | @Override 22 | public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { 23 | View view = inflater.inflate(R.layout.auth_progress, container, false); 24 | boolean isDarkTheme = PreferenceManager.getDefaultSharedPreferences( 25 | requireContext()).getBoolean("dark_theme", false); 26 | if(Global.checkMonet(requireContext())) { 27 | int accentColor; 28 | MonetCompat monet = MonetCompat.getInstance(); 29 | if (isDarkTheme) { 30 | accentColor = Global.getMonetIntColor(monet, "accent", 200); 31 | } else { 32 | accentColor = Global.getMonetIntColor(monet, "accent", 500); 33 | } 34 | ((ProgressBar) view.findViewById(R.id.auth_progress)).setProgressTintList(ColorStateList 35 | .valueOf(accentColor)); 36 | } 37 | return view; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/fragments/auth/AuthTwoFactorFragment.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.fragments.auth; 2 | 3 | import android.os.Bundle; 4 | import android.view.LayoutInflater; 5 | import android.view.View; 6 | import android.view.ViewGroup; 7 | import android.widget.TextView; 8 | 9 | import androidx.fragment.app.Fragment; 10 | 11 | import com.google.android.material.button.MaterialButton; 12 | 13 | import uk.openvk.android.refresh.R; 14 | import uk.openvk.android.refresh.ui.core.activities.AuthActivity; 15 | 16 | public class AuthTwoFactorFragment extends Fragment { 17 | @Override 18 | public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { 19 | View view = inflater.inflate(R.layout.fragment_auth_2fa, container, false); 20 | TextView twofactor_edit = view.findViewById(R.id.twofactor_edit); 21 | ((MaterialButton) view.findViewById(R.id.twofactor_confirm_btn)).setOnClickListener( 22 | new View.OnClickListener() { 23 | @Override 24 | public void onClick(View view) { 25 | if (getActivity() != null) { 26 | if (getActivity().getClass().getSimpleName().equals("AuthActivity")) { 27 | ((AuthActivity) getActivity()).signIn(twofactor_edit.getText().toString()); 28 | } 29 | } 30 | } 31 | }); 32 | ((MaterialButton) view.findViewById(R.id.twofactor_cancel_btn)).setOnClickListener( 33 | new View.OnClickListener() { 34 | @Override 35 | public void onClick(View view) { 36 | if(getActivity() != null) { 37 | if (getActivity().getClass().getSimpleName().equals("AuthActivity")) { 38 | ((AuthActivity) getActivity()).changeFragment("auth_form"); 39 | } 40 | } 41 | } 42 | }); 43 | return view; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/listeners/AppBarStateChangeListener.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.listeners; 2 | 3 | import com.google.android.material.appbar.AppBarLayout; 4 | 5 | public abstract class AppBarStateChangeListener implements AppBarLayout.OnOffsetChangedListener { 6 | 7 | public enum State { 8 | EXPANDED, 9 | COLLAPSED, 10 | IDLE 11 | } 12 | 13 | private State mCurrentState = State.IDLE; 14 | 15 | @Override 16 | public final void onOffsetChanged(AppBarLayout appBarLayout, int i) { 17 | if (i == 0) { 18 | if (mCurrentState != State.EXPANDED) { 19 | onStateChanged(appBarLayout, State.EXPANDED); 20 | } 21 | mCurrentState = State.EXPANDED; 22 | } else if (Math.abs(i) >= appBarLayout.getTotalScrollRange()) { 23 | if (mCurrentState != State.COLLAPSED) { 24 | onStateChanged(appBarLayout, State.COLLAPSED); 25 | } 26 | mCurrentState = State.COLLAPSED; 27 | } else { 28 | if (mCurrentState != State.IDLE) { 29 | onStateChanged(appBarLayout, State.IDLE); 30 | } 31 | mCurrentState = State.IDLE; 32 | } 33 | } 34 | 35 | public abstract void onStateChanged(AppBarLayout appBarLayout, State state); 36 | } 37 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/listeners/OnKeyboardStateListener.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.listeners; 2 | 3 | public interface OnKeyboardStateListener { 4 | public void onKeyboardStateChanged(boolean param1Boolean); 5 | } 6 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/listeners/OnRecyclerScrollListener.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.listeners; 2 | 3 | import uk.openvk.android.refresh.ui.view.InfinityRecyclerView; 4 | import uk.openvk.android.refresh.ui.view.InfinityScrollView; 5 | 6 | public interface OnRecyclerScrollListener { 7 | void onScroll(InfinityRecyclerView infinityRecyclerView, int x, int y, int old_x, int old_y); 8 | } 9 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/core/listeners/OnScrollListener.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.core.listeners; 2 | 3 | import uk.openvk.android.refresh.ui.view.InfinityRecyclerView; 4 | import uk.openvk.android.refresh.ui.view.InfinityScrollView; 5 | 6 | public interface OnScrollListener { 7 | void onScroll(InfinityScrollView infinityScrollView, int x, int y, int old_x, int old_y); 8 | } 9 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/list/items/PublicPageAboutItem.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.list.items; 2 | 3 | public class PublicPageAboutItem { 4 | public String title; 5 | public String subtitle; 6 | 7 | public PublicPageAboutItem(String title, String subtitle) { 8 | this.title = title; 9 | this.subtitle = subtitle; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/list/items/ToolbarSpinnerItem.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.list.items; 2 | 3 | public class ToolbarSpinnerItem { 4 | public String name; 5 | public String category; 6 | public long id; 7 | 8 | public ToolbarSpinnerItem(String category, String name, long id) { 9 | this.category = category; 10 | this.name = name; 11 | this.id = id; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/util/glide/GlideShh.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.util.glide; 2 | 3 | import android.content.Context; 4 | import android.util.Log; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | import com.bumptech.glide.GlideBuilder; 9 | import com.bumptech.glide.annotation.GlideModule; 10 | import com.bumptech.glide.module.AppGlideModule; 11 | 12 | @GlideModule 13 | public class GlideShh extends AppGlideModule { 14 | @Override 15 | public void applyOptions(@NonNull Context context, GlideBuilder builder) { 16 | builder.setLogLevel(Log.ERROR); // заткнись 17 | } 18 | } 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/InfinityRecyclerView.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view; 2 | 3 | import android.content.Context; 4 | import android.util.AttributeSet; 5 | import android.widget.ScrollView; 6 | 7 | import androidx.recyclerview.widget.RecyclerView; 8 | 9 | import uk.openvk.android.refresh.ui.core.listeners.OnRecyclerScrollListener; 10 | import uk.openvk.android.refresh.ui.core.listeners.OnScrollListener; 11 | 12 | public class InfinityRecyclerView extends RecyclerView { 13 | 14 | private OnRecyclerScrollListener onScrollListener; 15 | 16 | public InfinityRecyclerView(Context context) { 17 | super(context); 18 | } 19 | 20 | public InfinityRecyclerView(Context context, AttributeSet attrs) { 21 | super(context, attrs); 22 | } 23 | 24 | public void setOnScrollListener(OnRecyclerScrollListener scrollListener) { 25 | this.onScrollListener = scrollListener; 26 | } 27 | 28 | @Override 29 | protected void onScrollChanged(int l, int t, int oldl, int oldt) { 30 | super.onScrollChanged(l, t, oldl, oldt); 31 | if(onScrollListener != null) { 32 | try { 33 | onScrollListener.onScroll(this, l, t, oldl, oldt); 34 | } catch(Exception ex) { 35 | ex.printStackTrace(); 36 | } 37 | } 38 | } 39 | } -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/InfinityScrollView.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view; 2 | 3 | import android.content.Context; 4 | import android.util.AttributeSet; 5 | import android.widget.ScrollView; 6 | 7 | import uk.openvk.android.refresh.ui.core.listeners.OnScrollListener; 8 | 9 | public class InfinityScrollView extends ScrollView { 10 | 11 | private OnScrollListener onScrollListener; 12 | 13 | public InfinityScrollView(Context context) { 14 | super(context); 15 | } 16 | 17 | public InfinityScrollView(Context context, AttributeSet attrs) { 18 | super(context, attrs); 19 | } 20 | 21 | public void setOnScrollListener(OnScrollListener scrollListener) { 22 | this.onScrollListener = scrollListener; 23 | } 24 | 25 | @Override 26 | protected void onScrollChanged(int l, int t, int oldl, int oldt) { 27 | super.onScrollChanged(l, t, oldl, oldt); 28 | if(onScrollListener != null) { 29 | onScrollListener.onScroll(this, l, t, oldl, oldt); 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/TightTextView.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view; 2 | 3 | import android.content.Context; 4 | import android.text.Layout; 5 | import android.util.AttributeSet; 6 | 7 | public class TightTextView extends androidx.appcompat.widget.AppCompatTextView { 8 | public TightTextView(Context context) { 9 | super(context); 10 | } 11 | 12 | public TightTextView(Context context, AttributeSet attrs) { 13 | super(context, attrs); 14 | } 15 | 16 | public TightTextView(Context context, AttributeSet attrs, int defStyle) { 17 | super(context, attrs, defStyle); 18 | } 19 | 20 | @Override 21 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { 22 | super.onMeasure(widthMeasureSpec, heightMeasureSpec); 23 | 24 | int specModeW = MeasureSpec.getMode(widthMeasureSpec); 25 | if (specModeW != MeasureSpec.EXACTLY) { 26 | Layout layout = getLayout(); 27 | if (layout != null) { 28 | int w = (int) Math.ceil(getMaxLineWidth(layout)) + getCompoundPaddingLeft() + 29 | getCompoundPaddingRight(); 30 | if (w < getMeasuredWidth()) { 31 | super.onMeasure(MeasureSpec.makeMeasureSpec(w, MeasureSpec.AT_MOST), 32 | heightMeasureSpec); 33 | } 34 | } 35 | } 36 | } 37 | 38 | private float getMaxLineWidth(Layout layout) { 39 | float max_width = 0.0f; 40 | int lines = layout.getLineCount(); 41 | for (int i = 0; i < lines; i++) { 42 | if (layout.getLineWidth(i) > max_width) { 43 | max_width = layout.getLineWidth(i); 44 | } 45 | } 46 | return max_width; 47 | } 48 | } -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/layouts/ErrorLayout.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view.layouts; 2 | 3 | import android.annotation.SuppressLint; 4 | import android.content.Context; 5 | import android.util.AttributeSet; 6 | import android.view.LayoutInflater; 7 | import android.view.View; 8 | import android.widget.RelativeLayout; 9 | 10 | import androidx.annotation.NonNull; 11 | import androidx.annotation.Nullable; 12 | import androidx.appcompat.widget.LinearLayoutCompat; 13 | 14 | import uk.openvk.android.refresh.R; 15 | 16 | public class ErrorLayout extends LinearLayoutCompat { 17 | public ErrorLayout(@NonNull Context context, @Nullable AttributeSet attrs) { 18 | super(context, attrs); 19 | @SuppressLint("InflateParams") View view = LayoutInflater.from(getContext()).inflate( 20 | R.layout.layout_error, null); 21 | this.addView(view); 22 | LinearLayoutCompat.LayoutParams layoutParams = (LinearLayoutCompat.LayoutParams) 23 | view.getLayoutParams(); 24 | layoutParams.width = RelativeLayout.LayoutParams.MATCH_PARENT; 25 | layoutParams.height = RelativeLayout.LayoutParams.MATCH_PARENT; 26 | view.setLayoutParams(layoutParams); 27 | } 28 | 29 | public void setRetryButtonClickListener(OnClickListener listener) { 30 | findViewById(R.id.retry_btn).setOnClickListener(listener); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/layouts/PhotoAttachmentLayout.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view.layouts; 2 | 3 | import android.content.Context; 4 | import android.util.AttributeSet; 5 | import android.view.LayoutInflater; 6 | import android.view.View; 7 | import android.widget.ImageView; 8 | import android.widget.RelativeLayout; 9 | 10 | import androidx.constraintlayout.widget.ConstraintLayout; 11 | 12 | import uk.openvk.android.refresh.R; 13 | 14 | public class PhotoAttachmentLayout extends ConstraintLayout { 15 | 16 | private View view; 17 | 18 | public PhotoAttachmentLayout(Context context) { 19 | super(context); 20 | View view = LayoutInflater.from(getContext()).inflate( 21 | R.layout.attachment_photo, null); 22 | 23 | this.addView(view); 24 | ConstraintLayout.LayoutParams layoutParams = (ConstraintLayout.LayoutParams) 25 | view.getLayoutParams(); 26 | layoutParams.width = RelativeLayout.LayoutParams.MATCH_PARENT; 27 | layoutParams.height = RelativeLayout.LayoutParams.WRAP_CONTENT; 28 | view.setLayoutParams(layoutParams); 29 | } 30 | 31 | public PhotoAttachmentLayout(Context context, AttributeSet attrs) { 32 | super(context, attrs); 33 | view = LayoutInflater.from(getContext()).inflate( 34 | R.layout.attachment_photo, null); 35 | 36 | this.addView(view); 37 | ConstraintLayout.LayoutParams layoutParams = (ConstraintLayout.LayoutParams) 38 | view.getLayoutParams(); 39 | layoutParams.width = RelativeLayout.LayoutParams.MATCH_PARENT; 40 | layoutParams.height = RelativeLayout.LayoutParams.WRAP_CONTENT; 41 | view.setLayoutParams(layoutParams); 42 | } 43 | 44 | public ImageView getImageView() { 45 | return ((ImageView) view.findViewById(R.id.thumbnail_view)); 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/layouts/SendTextBottomPanel.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view.layouts; 2 | 3 | import android.content.Context; 4 | import android.util.AttributeSet; 5 | import android.view.LayoutInflater; 6 | import android.view.View; 7 | import android.widget.RelativeLayout; 8 | 9 | import androidx.annotation.NonNull; 10 | import androidx.annotation.Nullable; 11 | import androidx.constraintlayout.widget.ConstraintLayout; 12 | 13 | import com.google.android.material.textfield.TextInputEditText; 14 | 15 | import java.util.Objects; 16 | 17 | import uk.openvk.android.refresh.R; 18 | 19 | public class SendTextBottomPanel extends ConstraintLayout { 20 | public SendTextBottomPanel(@NonNull Context context, @Nullable AttributeSet attrs) { 21 | super(context, attrs); 22 | View view = LayoutInflater.from(getContext()).inflate( 23 | R.layout.panel_sendtext_bottom, null); 24 | 25 | this.addView(view); 26 | ConstraintLayout.LayoutParams layoutParams = (ConstraintLayout.LayoutParams) view.getLayoutParams(); 27 | layoutParams.width = RelativeLayout.LayoutParams.MATCH_PARENT; 28 | layoutParams.height = RelativeLayout.LayoutParams.WRAP_CONTENT; 29 | view.setLayoutParams(layoutParams); 30 | } 31 | 32 | public void setOnSendButtonClickListener(OnClickListener listener) { 33 | findViewById(R.id.send_btn).setOnClickListener(listener); 34 | } 35 | 36 | public String getText() { 37 | return Objects.requireNonNull(((TextInputEditText) findViewById(R.id.send_text)) 38 | .getText()).toString(); 39 | } 40 | 41 | public void clearText() { 42 | Objects.requireNonNull(((TextInputEditText) findViewById(R.id.send_text))).setText(""); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/pager/adapters/FriendsPagerAdapter.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view.pager.adapters; 2 | 3 | import android.os.Bundle; 4 | 5 | import androidx.annotation.NonNull; 6 | import androidx.fragment.app.Fragment; 7 | import androidx.viewpager2.adapter.FragmentStateAdapter; 8 | 9 | import java.util.ArrayList; 10 | 11 | import uk.openvk.android.refresh.ui.core.fragments.app.friends.FriendRequestsFragment; 12 | import uk.openvk.android.refresh.ui.core.fragments.app.friends.FriendsListFragment; 13 | import uk.openvk.android.refresh.ui.core.fragments.app.pub_pages.AboutFragment; 14 | 15 | public class FriendsPagerAdapter extends FragmentStateAdapter { 16 | 17 | private String[] frgData; 18 | private int pages_count; 19 | 20 | ArrayList fragments; 21 | 22 | public FriendsPagerAdapter(@NonNull Fragment fragment) { 23 | super(fragment); 24 | fragments = new ArrayList<>(); 25 | } 26 | 27 | public FriendsPagerAdapter(@NonNull Fragment fragment, String[] frgData, int pages_count) { 28 | super(fragment); 29 | fragments = new ArrayList<>(); 30 | this.frgData = frgData; 31 | this.pages_count = pages_count; 32 | } 33 | 34 | @NonNull 35 | @Override 36 | public Fragment createFragment(int position) { 37 | Bundle bundle = new Bundle(); 38 | bundle.putString("key", frgData[position]); 39 | Fragment fragment; 40 | if(position == 0) { 41 | fragment = new FriendsListFragment(); 42 | } else { 43 | fragment = new FriendRequestsFragment(); 44 | } 45 | fragment.setArguments(bundle); 46 | fragments.add(position, fragment); 47 | return fragment; 48 | } 49 | 50 | @Override 51 | public int getItemCount() { 52 | return pages_count; 53 | } 54 | 55 | public Fragment getFragment(int position) { 56 | try { 57 | if (position == 1 && fragments.get(position) instanceof FriendsListFragment) { 58 | fragments.set(position, FriendRequestsFragment.createInstance(position)); 59 | } 60 | } catch (Exception ignored) { 61 | 62 | } 63 | return fragments.get(position); 64 | } 65 | } 66 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/view/pager/adapters/PublicPagerAdapter.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.view.pager.adapters; 2 | 3 | import android.os.Bundle; 4 | 5 | import androidx.annotation.NonNull; 6 | import androidx.fragment.app.Fragment; 7 | import androidx.viewpager2.adapter.FragmentStateAdapter; 8 | 9 | import java.util.ArrayList; 10 | 11 | import uk.openvk.android.refresh.ui.core.fragments.app.pub_pages.AboutFragment; 12 | import uk.openvk.android.refresh.ui.core.fragments.app.pub_pages.WallFragment; 13 | 14 | public class PublicPagerAdapter extends FragmentStateAdapter { 15 | 16 | private String[] frgData; 17 | private int pages_count; 18 | 19 | ArrayList fragments; 20 | 21 | public PublicPagerAdapter(@NonNull Fragment fragment) { 22 | super(fragment); 23 | fragments = new ArrayList<>(); 24 | } 25 | 26 | public PublicPagerAdapter(@NonNull Fragment fragment, String[] frgData, int pages_count) { 27 | super(fragment); 28 | fragments = new ArrayList<>(); 29 | this.frgData = frgData; 30 | this.pages_count = pages_count; 31 | } 32 | 33 | @NonNull 34 | @Override 35 | public Fragment createFragment(int position) { 36 | Bundle bundle = new Bundle(); 37 | bundle.putString("key", frgData[position]); 38 | Fragment fragment; 39 | if(position == 0) { 40 | fragment = new WallFragment(); 41 | } else { 42 | fragment = new AboutFragment(); 43 | } 44 | fragment.setArguments(bundle); 45 | fragments.add(position, fragment); 46 | return fragment; 47 | } 48 | 49 | @Override 50 | public int getItemCount() { 51 | return 2; 52 | } 53 | 54 | public Fragment getFragment(int position) { 55 | if(position == 1 && fragments.get(position) instanceof WallFragment) { 56 | fragments.set(position, AboutFragment.createInstance(position)); 57 | } 58 | return fragments.get(position); 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/wrappers/LocaleContextWrapper.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.wrappers; 2 | 3 | import android.annotation.SuppressLint; 4 | import android.annotation.TargetApi; 5 | import android.content.Context; 6 | import android.content.ContextWrapper; 7 | import android.content.res.Configuration; 8 | import android.content.res.Resources; 9 | import android.os.Build; 10 | import android.os.LocaleList; 11 | 12 | import java.util.Locale; 13 | 14 | /** 15 | * Created by Dmitry on 23.01.2023. 16 | */ 17 | 18 | public class LocaleContextWrapper extends ContextWrapper { 19 | public LocaleContextWrapper(Context base) { 20 | super(base); 21 | } 22 | 23 | @SuppressLint("ObsoleteSdkInt") 24 | @TargetApi(Build.VERSION_CODES.N) 25 | public static ContextWrapper wrap(Context context, Locale newLocale) { 26 | Resources res = context.getResources(); 27 | Configuration configuration = res.getConfiguration(); 28 | 29 | if (Build.VERSION.SDK_INT > Build.VERSION_CODES.N) { 30 | configuration.setLocale(newLocale); 31 | 32 | LocaleList localeList = new LocaleList(newLocale); 33 | LocaleList.setDefault(localeList); 34 | configuration.setLocales(localeList); 35 | 36 | context = context.createConfigurationContext(configuration); 37 | 38 | } else if (Build.VERSION.SDK_INT > Build.VERSION_CODES.JELLY_BEAN_MR1) { 39 | configuration.setLocale(newLocale); 40 | context = context.createConfigurationContext(configuration); 41 | } else { 42 | configuration.locale = newLocale; 43 | res.updateConfiguration(configuration, res.getDisplayMetrics()); 44 | } 45 | 46 | return new ContextWrapper(context); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/ui/wrappers/TypefaceUtil.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.ui.wrappers; 2 | 3 | import android.annotation.SuppressLint; 4 | import android.content.Context; 5 | import android.graphics.Typeface; 6 | import android.os.Build; 7 | 8 | import androidx.core.content.res.ResourcesCompat; 9 | 10 | import java.lang.reflect.Field; 11 | import java.util.HashMap; 12 | import java.util.Map; 13 | 14 | @SuppressWarnings("JavaReflectionMemberAccess") 15 | public class TypefaceUtil { 16 | 17 | /** 18 | * Using reflection to override default typeface 19 | * NOTICE: DO NOT FORGET TO SET TYPEFACE FOR APP THEME AS DEFAULT TYPEFACE WHICH WILL BE OVERRIDDEN 20 | * 21 | * @param context to work with assets 22 | * @param defaultFontNameToOverride for example "monospace" 23 | */ 24 | @SuppressLint("ObsoleteSdkInt") 25 | public static void overrideFont(Context context, String defaultFontNameToOverride, int fontId) { 26 | 27 | final Typeface customFontTypeface = ResourcesCompat.getFont(context, fontId); 28 | 29 | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { 30 | Map newMap = new HashMap(); 31 | newMap.put("serif", customFontTypeface); 32 | try { 33 | @SuppressLint("DiscouragedPrivateApi") final Field staticField = Typeface.class 34 | .getDeclaredField("sSystemFontMap"); 35 | staticField.setAccessible(true); 36 | staticField.set(null, newMap); 37 | } catch (NoSuchFieldException | IllegalAccessException e) { 38 | e.printStackTrace(); 39 | } 40 | } else { 41 | try { 42 | final Field defaultFontTypefaceField = Typeface.class. 43 | getDeclaredField(defaultFontNameToOverride); 44 | defaultFontTypefaceField.setAccessible(true); 45 | defaultFontTypefaceField.set(null, customFontTypeface); 46 | } catch (Exception e) { 47 | } 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /app/src/main/java/uk/openvk/android/refresh/utils/LibraryLoader.java: -------------------------------------------------------------------------------- 1 | package uk.openvk.android.refresh.utils; 2 | 3 | import android.content.Context; 4 | 5 | /** 6 | * Copyleft © 2022, 2023 OpenVK Team 7 | * Copyleft © 2022, 2023 Dmitry Tretyakov (aka. Tinelix) 8 | * 9 | * This program is free software: you can redistribute it and/or modify it under the terms of 10 | * the GNU Affero General Public License as published by the Free Software Foundation, either 11 | * version 3 of the License, or (at your option) any later version. 12 | * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 13 | * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 14 | * See the GNU Affero General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU Affero General Public License along with this 17 | * program. If not, see https://www.gnu.org/licenses/. 18 | * 19 | * Source code: https://github.com/openvk/mobile-android-refresh 20 | */ 21 | 22 | public interface LibraryLoader { 23 | void loadSharedLibrary(Context ctx, String library_name) throws UnsatisfiedLinkError, SecurityException, Exception; 24 | } 25 | -------------------------------------------------------------------------------- /app/src/main/res/color-night/nv_items.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/color/bnv_items.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/color/counter_btn.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/color/nv_items.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-anydpi-v24/ic_ovk_notif.xml: -------------------------------------------------------------------------------- 1 | 7 | 11 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/ic_ovk_notif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-hdpi/ic_ovk_notif.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/photo_loading_error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-hdpi/photo_loading_error.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-hdpi/warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-hdpi/warning.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-mdpi/ic_ovk_notif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-mdpi/ic_ovk_notif.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-night/item_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-nodpi/circular_avatar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-nodpi/circular_avatar.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/ic_ovk_notif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-xhdpi/ic_ovk_notif.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/photo_loading_error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-xhdpi/photo_loading_error.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xhdpi/warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-xhdpi/warning.png -------------------------------------------------------------------------------- /app/src/main/res/drawable-xxhdpi/ic_ovk_notif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/drawable-xxhdpi/ic_ovk_notif.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/bottom_shadow.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_account.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_add.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_api.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_api_android.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_api_default.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_api_iphone.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_arrow_back.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_arrow_drop_down_24.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_campaign.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_campaign_16.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_campaign_18.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_campaign_custom.xml: -------------------------------------------------------------------------------- 1 | 6 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_campaign_custom_18.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_chat.xml: -------------------------------------------------------------------------------- 1 | 8 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_comment.xml: -------------------------------------------------------------------------------- 1 | 8 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_comment_16.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_comment_18.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_error.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_favorite.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_favorite_16.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_favorite_18.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_favorite_18_accent.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_feed.xml: -------------------------------------------------------------------------------- 1 | 8 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_file_download.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_help_outline.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_home.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_info.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_instance.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_language.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_list_alt.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_logout.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_menu.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_more.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_openvk_compact_logo.xml: -------------------------------------------------------------------------------- 1 | 3 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_openvk_compact_logo_color.xml: -------------------------------------------------------------------------------- 1 | 3 | 5 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_pause_large.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_people.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_person.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_person_add.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_person_remove.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_personalization.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_play.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_play_large.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_post_add.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_search.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_send.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_settings.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_verified.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_video_file_large.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_video_file_placeholder.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_video_library.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_warning_amber.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_zoom_in_large.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_zoom_out_large.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/item_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/photo_placeholder.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/font/inter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 12 | 13 | 16 | 17 | 20 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/font/inter_bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_bold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/inter_extrabold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_extrabold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/inter_extralight.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_extralight.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/inter_light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_light.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/inter_medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_medium.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/inter_regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/inter_regular.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 12 | 13 | 16 | 17 | 20 | 21 | 25 | 26 | -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_bold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_bold_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_bold_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_light.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_light_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_light_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/open_sans_regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/open_sans_regular.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 9 | 10 | 13 | 14 | 17 | 18 | 21 | 22 | 25 | 26 | 29 | 30 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_bold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_bold_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_bold_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_light.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_light_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_light_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_medium.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_medium_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_medium_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/raleway_regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/raleway_regular.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 12 | 13 | 16 | 17 | 21 | 22 | 25 | 26 | 29 | 30 | 33 | 34 | 38 | 39 | -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_bold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_bold_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_bold_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_light.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_light_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_light_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_medium.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_medium_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_medium_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/roboto_regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/roboto_regular.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 12 | 13 | 16 | 17 | 21 | 22 | 25 | 26 | 29 | 30 | 33 | 34 | 38 | 39 | -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_bold.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_bold_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_bold_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_light.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_light_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_light_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_medium.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_medium_italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_medium_italic.ttf -------------------------------------------------------------------------------- /app/src/main/res/font/rubik_regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OpenVK/mobile-android-refresh/7a39f5396c069d1f8ad3a62b12ec3966b15ae150/app/src/main/res/font/rubik_regular.ttf -------------------------------------------------------------------------------- /app/src/main/res/layout-night/activity_intent.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 15 | 16 | 30 | 31 | 32 | 42 | 43 | -------------------------------------------------------------------------------- /app/src/main/res/layout-sw600dp/fragment_newsfeed.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 24 | 25 | 31 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /app/src/main/res/layout-sw600dp/tab_wall.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 15 | 16 | 24 | 25 | 26 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/layout/actionbar_spinner_dropdown_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 22 | -------------------------------------------------------------------------------- /app/src/main/res/layout/actionbar_spinner_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 12 | 13 | 21 | 22 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_conversation.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 19 | 20 | 28 | 29 | 44 | 45 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_intent.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 23 | 24 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/layout/app_host.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/res/layout/attachment_photo.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | -------------------------------------------------------------------------------- /app/src/main/res/layout/attachment_poll.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 27 | 28 | 34 | 35 | 36 | 37 | 46 | -------------------------------------------------------------------------------- /app/src/main/res/layout/auth_progress.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 17 | 18 | 26 | -------------------------------------------------------------------------------- /app/src/main/res/layout/blank_fragment.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/layout/blank_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/layout/dialog_choose_list.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/layout/fragment_conversations.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 13 | 14 | 15 | 16 | 25 | 26 | 36 | 37 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /app/src/main/res/layout/fragment_groups.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 13 | 14 | 15 | 16 | 25 | 26 | 36 | 37 | 45 | 46 | -------------------------------------------------------------------------------- /app/src/main/res/layout/fragment_newsfeed.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 28 | 29 | 33 | 34 | 35 | 36 | 37 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /app/src/main/res/layout/layout_error.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 19 | 20 | 27 | 28 | 35 | 36 | 43 | 44 |