├── .github └── workflows │ └── test.yml ├── .gitignore ├── .idea ├── .name ├── codeStyles │ └── Project.xml ├── compiler.xml ├── jarRepositories.xml └── misc.xml ├── LICENSE ├── README.md ├── app ├── build.gradle ├── libs │ ├── dec-0.1.2.jar │ ├── lib-decoder-ffmpeg-release.aar │ ├── thunder.jar │ └── xwalk_shared_library-23.53.589.4.aar ├── proguard-python.pro ├── proguard-rules.pro ├── schemas │ └── com.github.tvbox.osc.data.AppDataBase │ │ ├── .gitignore │ │ ├── 1.json │ │ └── 3.json └── src │ ├── main │ ├── AndroidManifest.xml │ ├── assets │ │ ├── epg_data.json │ │ ├── js │ │ │ └── lib │ │ │ │ ├── cat.js │ │ │ │ ├── cheerio.min.js │ │ │ │ ├── crypto-js.js │ │ │ │ ├── gbk.js │ │ │ │ ├── net.js │ │ │ │ ├── similarity.js │ │ │ │ ├── utils.js │ │ │ │ └── 模板.js │ │ └── ua.db │ ├── java │ │ ├── com │ │ │ ├── acsbendi │ │ │ │ └── requestinspectorwebview │ │ │ │ │ ├── RequestInspectorJavaScriptInterface.kt │ │ │ │ │ ├── RequestInspectorOptions.kt │ │ │ │ │ ├── RequestInspectorWebViewClient.kt │ │ │ │ │ ├── WebViewRequest.kt │ │ │ │ │ └── WebViewRequestType.kt │ │ │ ├── aminography │ │ │ │ └── redirectglide │ │ │ │ │ ├── BaseApiCallGlideUrl.kt │ │ │ │ │ ├── OkHttpApiCallUrlFetcher.kt │ │ │ │ │ ├── OkHttpAppGlideModule.kt │ │ │ │ │ ├── OkHttpRedirectUrlFetcher.kt │ │ │ │ │ ├── OkHttpStreamFetcher.kt │ │ │ │ │ ├── OkHttpUrlLoader.kt │ │ │ │ │ ├── RedirectException.kt │ │ │ │ │ └── RedirectGlideUrl.kt │ │ │ ├── github │ │ │ │ ├── catvod │ │ │ │ │ ├── Init.java │ │ │ │ │ ├── crawler │ │ │ │ │ │ ├── JarLoader.java │ │ │ │ │ │ ├── JsLoader.java │ │ │ │ │ │ ├── Spider.java │ │ │ │ │ │ ├── SpiderDebug.java │ │ │ │ │ │ ├── SpiderNull.java │ │ │ │ │ │ └── python │ │ │ │ │ │ │ └── IPyLoader.java │ │ │ │ │ ├── net │ │ │ │ │ │ ├── OkHttp.java │ │ │ │ │ │ ├── OkhttpInterceptor.java │ │ │ │ │ │ ├── ProxySelector.java │ │ │ │ │ │ └── SSLCompat.java │ │ │ │ │ └── utils │ │ │ │ │ │ ├── Path.java │ │ │ │ │ │ └── Util.java │ │ │ │ └── tvbox │ │ │ │ │ └── osc │ │ │ │ │ ├── api │ │ │ │ │ └── ApiConfig.java │ │ │ │ │ ├── base │ │ │ │ │ ├── App.java │ │ │ │ │ ├── BaseActivity.java │ │ │ │ │ └── BaseLazyFragment.java │ │ │ │ │ ├── bean │ │ │ │ │ ├── AbsJson.java │ │ │ │ │ ├── AbsSortJson.java │ │ │ │ │ ├── AbsSortXml.java │ │ │ │ │ ├── AbsXml.java │ │ │ │ │ ├── AppInfo.java │ │ │ │ │ ├── Danmu.java │ │ │ │ │ ├── Doh.java │ │ │ │ │ ├── DriveFolderFile.java │ │ │ │ │ ├── Epginfo.java │ │ │ │ │ ├── IJKCode.java │ │ │ │ │ ├── LiveChannelGroup.java │ │ │ │ │ ├── LiveChannelItem.java │ │ │ │ │ ├── LiveEpgDate.java │ │ │ │ │ ├── LivePlayerManager.java │ │ │ │ │ ├── LiveSettingGroup.java │ │ │ │ │ ├── LiveSettingItem.java │ │ │ │ │ ├── Movie.java │ │ │ │ │ ├── MovieSort.java │ │ │ │ │ ├── ParseBean.java │ │ │ │ │ ├── SearchResultWrapper.java │ │ │ │ │ ├── SourceBean.java │ │ │ │ │ ├── SubtitleBean.java │ │ │ │ │ ├── SubtitleData.java │ │ │ │ │ ├── VodInfo.java │ │ │ │ │ └── VodSeriesGroup.java │ │ │ │ │ ├── cache │ │ │ │ │ ├── Cache.java │ │ │ │ │ ├── CacheDao.java │ │ │ │ │ ├── CacheManager.java │ │ │ │ │ ├── RoomDataManger.java │ │ │ │ │ ├── SearchDao.java │ │ │ │ │ ├── SearchHistory.java │ │ │ │ │ ├── StorageDrive.java │ │ │ │ │ ├── StorageDriveDao.java │ │ │ │ │ ├── VodCollect.java │ │ │ │ │ ├── VodCollectDao.java │ │ │ │ │ ├── VodRecord.java │ │ │ │ │ └── VodRecordDao.java │ │ │ │ │ ├── callback │ │ │ │ │ ├── EmptyCallback.java │ │ │ │ │ └── LoadingCallback.java │ │ │ │ │ ├── data │ │ │ │ │ ├── AppDataBase.java │ │ │ │ │ ├── AppDataManager.java │ │ │ │ │ ├── DbHelper.java │ │ │ │ │ └── SearchPresenter.java │ │ │ │ │ ├── event │ │ │ │ │ ├── HistoryStateEvent.java │ │ │ │ │ ├── InputMsgEvent.java │ │ │ │ │ ├── LogEvent.java │ │ │ │ │ ├── RefreshEvent.java │ │ │ │ │ ├── ServerEvent.java │ │ │ │ │ └── TopStateEvent.java │ │ │ │ │ ├── player │ │ │ │ │ ├── EXOmPlayer.java │ │ │ │ │ ├── IjkmPlayer.java │ │ │ │ │ ├── MyVideoView.java │ │ │ │ │ ├── TrackInfo.java │ │ │ │ │ ├── TrackInfoBean.java │ │ │ │ │ ├── controller │ │ │ │ │ │ ├── BaseController.java │ │ │ │ │ │ ├── LiveController.java │ │ │ │ │ │ └── VodController.java │ │ │ │ │ ├── danmu │ │ │ │ │ │ └── Parser.java │ │ │ │ │ ├── render │ │ │ │ │ │ ├── SurfaceRenderView.java │ │ │ │ │ │ └── SurfaceRenderViewFactory.java │ │ │ │ │ └── thirdparty │ │ │ │ │ │ ├── Kodi.java │ │ │ │ │ │ ├── MXPlayer.java │ │ │ │ │ │ └── ReexPlayer.java │ │ │ │ │ ├── receiver │ │ │ │ │ ├── CustomWebReceiver.java │ │ │ │ │ ├── DetailReceiver.java │ │ │ │ │ └── SearchReceiver.java │ │ │ │ │ ├── server │ │ │ │ │ ├── ControlManager.java │ │ │ │ │ ├── DataReceiver.java │ │ │ │ │ ├── InputRequestProcess.java │ │ │ │ │ ├── PlayService.java │ │ │ │ │ ├── RawRequestProcess.java │ │ │ │ │ ├── RemoteServer.java │ │ │ │ │ ├── RequestProcess.java │ │ │ │ │ ├── ShellUtils.java │ │ │ │ │ └── WebController.kt │ │ │ │ │ ├── subtitle │ │ │ │ │ ├── DefaultSubtitleEngine.java │ │ │ │ │ ├── SubtitleEngine.java │ │ │ │ │ ├── SubtitleFinder.java │ │ │ │ │ ├── SubtitleLoadSuccessResult.java │ │ │ │ │ ├── SubtitleLoader.java │ │ │ │ │ ├── UIRenderTask.java │ │ │ │ │ ├── exception │ │ │ │ │ │ └── FatalParsingException.java │ │ │ │ │ ├── format │ │ │ │ │ │ ├── FormatASS.java │ │ │ │ │ │ ├── FormatSCC.java │ │ │ │ │ │ ├── FormatSRT.java │ │ │ │ │ │ ├── FormatSTL.java │ │ │ │ │ │ ├── FormatTTML.java │ │ │ │ │ │ └── TimedTextFileFormat.java │ │ │ │ │ ├── model │ │ │ │ │ │ ├── Region.java │ │ │ │ │ │ ├── Style.java │ │ │ │ │ │ ├── Subtitle.java │ │ │ │ │ │ ├── Time.java │ │ │ │ │ │ └── TimedTextObject.java │ │ │ │ │ ├── runtime │ │ │ │ │ │ ├── AppTaskExecutor.java │ │ │ │ │ │ ├── DefaultTaskExecutor.java │ │ │ │ │ │ └── TaskExecutor.java │ │ │ │ │ └── widget │ │ │ │ │ │ └── SimpleSubtitleView.java │ │ │ │ │ ├── ui │ │ │ │ │ ├── activity │ │ │ │ │ │ ├── AppsActivity.java │ │ │ │ │ │ ├── CollectActivity.java │ │ │ │ │ │ ├── DetailActivity.java │ │ │ │ │ │ ├── DriveActivity.java │ │ │ │ │ │ ├── FastSearchActivity.java │ │ │ │ │ │ ├── HistoryActivity.java │ │ │ │ │ │ ├── HomeActivity.java │ │ │ │ │ │ ├── LivePlayActivity.java │ │ │ │ │ │ ├── PlayActivity.java │ │ │ │ │ │ ├── PushActivity.java │ │ │ │ │ │ ├── SearchActivity.java │ │ │ │ │ │ └── SettingActivity.java │ │ │ │ │ ├── adapter │ │ │ │ │ │ ├── ApiHistoryDialogAdapter.java │ │ │ │ │ │ ├── AppsAdapter.java │ │ │ │ │ │ ├── BackupAdapter.java │ │ │ │ │ │ ├── ButtonAdapter.java │ │ │ │ │ │ ├── CheckboxSearchAdapter.java │ │ │ │ │ │ ├── CollectAdapter.java │ │ │ │ │ │ ├── DriveAdapter.java │ │ │ │ │ │ ├── FastListAdapter.java │ │ │ │ │ │ ├── FastSearchAdapter.java │ │ │ │ │ │ ├── GridAdapter.java │ │ │ │ │ │ ├── GridFilterKVAdapter.java │ │ │ │ │ │ ├── HistoryAdapter.java │ │ │ │ │ │ ├── HomeHotVodAdapter.java │ │ │ │ │ │ ├── HomePageAdapter.java │ │ │ │ │ │ ├── LiveChannelGroupAdapter.java │ │ │ │ │ │ ├── LiveChannelItemAdapter.java │ │ │ │ │ │ ├── LiveEpgAdapter.java │ │ │ │ │ │ ├── LiveEpgDateAdapter.java │ │ │ │ │ │ ├── LiveSettingGroupAdapter.java │ │ │ │ │ │ ├── LiveSettingItemAdapter.java │ │ │ │ │ │ ├── ParseAdapter.java │ │ │ │ │ │ ├── PinyinAdapter.java │ │ │ │ │ │ ├── QuickSearchAdapter.java │ │ │ │ │ │ ├── SearchAdapter.java │ │ │ │ │ │ ├── SearchSubtitleAdapter.java │ │ │ │ │ │ ├── SearchWordAdapter.java │ │ │ │ │ │ ├── SelectDialogAdapter.java │ │ │ │ │ │ ├── SeriesAdapter.java │ │ │ │ │ │ ├── SeriesFlagAdapter.java │ │ │ │ │ │ ├── SeriesGroupAdapter.java │ │ │ │ │ │ ├── SettingMenuAdapter.java │ │ │ │ │ │ ├── SettingPageAdapter.java │ │ │ │ │ │ └── SortAdapter.java │ │ │ │ │ ├── dialog │ │ │ │ │ │ ├── AboutDialog.java │ │ │ │ │ │ ├── AlistDriveDialog.java │ │ │ │ │ │ ├── ApiDialog.java │ │ │ │ │ │ ├── ApiHistoryDialog.java │ │ │ │ │ │ ├── BackupDialog.java │ │ │ │ │ │ ├── BaseDialog.java │ │ │ │ │ │ ├── ConfirmClearDialog.java │ │ │ │ │ │ ├── DanmuSettingDialog.java │ │ │ │ │ │ ├── DescDialog.java │ │ │ │ │ │ ├── GridFilterDialog.java │ │ │ │ │ │ ├── HomeIconDialog.java │ │ │ │ │ │ ├── LivePasswordDialog.java │ │ │ │ │ │ ├── MediaSettingDialog.java │ │ │ │ │ │ ├── PushDialog.java │ │ │ │ │ │ ├── QuickSearchDialog.java │ │ │ │ │ │ ├── RemoteDialog.java │ │ │ │ │ │ ├── ResetDialog.java │ │ │ │ │ │ ├── SearchCheckboxDialog.java │ │ │ │ │ │ ├── SearchSubtitleDialog.java │ │ │ │ │ │ ├── SelectDialog.java │ │ │ │ │ │ ├── SubtitleDialog.java │ │ │ │ │ │ ├── TipDialog.java │ │ │ │ │ │ ├── WebdavDialog.java │ │ │ │ │ │ └── XWalkInitDialog.java │ │ │ │ │ ├── fragment │ │ │ │ │ │ ├── GridFragment.java │ │ │ │ │ │ ├── ModelSettingFragment.java │ │ │ │ │ │ ├── PlayFragment.java │ │ │ │ │ │ └── UserFragment.java │ │ │ │ │ └── tv │ │ │ │ │ │ ├── QRCodeGen.java │ │ │ │ │ │ └── widget │ │ │ │ │ │ ├── AudioWaveView.java │ │ │ │ │ │ ├── ChannelListView.java │ │ │ │ │ │ ├── CustomEditText.java │ │ │ │ │ │ ├── DefaultTransformer.java │ │ │ │ │ │ ├── FixedSpeedScroller.java │ │ │ │ │ │ ├── LoadMoreView.java │ │ │ │ │ │ ├── MarqueeTextView.java │ │ │ │ │ │ ├── NoScrollViewPager.java │ │ │ │ │ │ ├── SearchKeyboard.java │ │ │ │ │ │ └── ViewObj.java │ │ │ │ │ ├── util │ │ │ │ │ ├── AES.java │ │ │ │ │ ├── AdBlocker.java │ │ │ │ │ ├── AppManager.java │ │ │ │ │ ├── CollUtil.java │ │ │ │ │ ├── ColorHelper.java │ │ │ │ │ ├── DefaultConfig.java │ │ │ │ │ ├── EpgUtil.java │ │ │ │ │ ├── FastClickCheckUtil.java │ │ │ │ │ ├── FileUtils.java │ │ │ │ │ ├── HawkConfig.java │ │ │ │ │ ├── HawkUtils.java │ │ │ │ │ ├── HistoryHelper.java │ │ │ │ │ ├── ImgUtil.java │ │ │ │ │ ├── JavaUtil.kt │ │ │ │ │ ├── LOG.java │ │ │ │ │ ├── LocalIPAddress.java │ │ │ │ │ ├── LocaleHelper.java │ │ │ │ │ ├── M3U8.java │ │ │ │ │ ├── MD5.java │ │ │ │ │ ├── OkGoHelper.java │ │ │ │ │ ├── PlayerHelper.java │ │ │ │ │ ├── Proxy.java │ │ │ │ │ ├── RegexUtils.java │ │ │ │ │ ├── ScreenUtils.java │ │ │ │ │ ├── SearchHelper.java │ │ │ │ │ ├── SettingsUtil.java │ │ │ │ │ ├── StorageDriveType.java │ │ │ │ │ ├── StringUtils.java │ │ │ │ │ ├── SubtitleHelper.java │ │ │ │ │ ├── TLSSocketFactory.java │ │ │ │ │ ├── ToastHelper.java │ │ │ │ │ ├── UA.java │ │ │ │ │ ├── UnicodeReader.java │ │ │ │ │ ├── VideoParseRuler.java │ │ │ │ │ ├── XWalkUtils.java │ │ │ │ │ ├── js │ │ │ │ │ │ ├── Async.java │ │ │ │ │ │ ├── Connect.java │ │ │ │ │ │ ├── Crypto.java │ │ │ │ │ │ ├── FunCall.java │ │ │ │ │ │ ├── Global.java │ │ │ │ │ │ ├── HtmlParser.java │ │ │ │ │ │ ├── JsSpider.java │ │ │ │ │ │ ├── Json.java │ │ │ │ │ │ ├── Req.java │ │ │ │ │ │ ├── Res.java │ │ │ │ │ │ ├── SpiderJS.java │ │ │ │ │ │ ├── Trans.java │ │ │ │ │ │ ├── UTF8BOMFighter.java │ │ │ │ │ │ ├── local.java │ │ │ │ │ │ └── rsa │ │ │ │ │ │ │ ├── DataUtils.java │ │ │ │ │ │ │ └── RSAEncrypt.java │ │ │ │ │ ├── live │ │ │ │ │ │ └── TxtSubscribe.java │ │ │ │ │ ├── parser │ │ │ │ │ │ ├── JsonParallel.java │ │ │ │ │ │ ├── SuperParse.java │ │ │ │ │ │ └── Utils.java │ │ │ │ │ ├── thunder │ │ │ │ │ │ ├── Jianpian.java │ │ │ │ │ │ └── Thunder.java │ │ │ │ │ └── urlhttp │ │ │ │ │ │ ├── BrotliInterceptor.java │ │ │ │ │ │ ├── CallBackUtil.java │ │ │ │ │ │ ├── OKCallBack.java │ │ │ │ │ │ ├── OKRequest.java │ │ │ │ │ │ ├── OkHttpUtil.java │ │ │ │ │ │ ├── RealRequest.java │ │ │ │ │ │ ├── RealResponse.java │ │ │ │ │ │ ├── RequestUtil.java │ │ │ │ │ │ ├── SSLSocketFactoryCompat.java │ │ │ │ │ │ ├── UrlHttpUtil.java │ │ │ │ │ │ └── internal │ │ │ │ │ │ └── BrotliSource.java │ │ │ │ │ ├── viewmodel │ │ │ │ │ ├── SourceViewModel.java │ │ │ │ │ ├── SubtitleViewModel.java │ │ │ │ │ └── drive │ │ │ │ │ │ ├── AbstractDriveViewModel.java │ │ │ │ │ │ ├── AlistDriveViewModel.java │ │ │ │ │ │ ├── LocalDriveViewModel.java │ │ │ │ │ │ └── WebDAVDriveViewModel.java │ │ │ │ │ └── widget │ │ │ │ │ ├── OnItemClickListener.java │ │ │ │ │ └── OnItemSelectedListener.java │ │ │ ├── google │ │ │ │ └── androidx │ │ │ │ │ └── media3 │ │ │ │ │ └── exoplayer │ │ │ │ │ ├── ext │ │ │ │ │ └── okhttp │ │ │ │ │ │ └── OkHttpDataSource.java │ │ │ │ │ └── extractor │ │ │ │ │ └── ts │ │ │ │ │ ├── MyTsExtractor.java │ │ │ │ │ ├── TsBinarySearchSeeker.java │ │ │ │ │ └── TsDurationReader.java │ │ │ └── p2p │ │ │ │ └── P2PClass.java │ │ ├── okhttp3 │ │ │ └── dnsoverhttps │ │ │ │ ├── BootstrapDns.java │ │ │ │ ├── DnsOverHttps.java │ │ │ │ └── DnsRecordCodec.java │ │ ├── tv │ │ │ └── danmaku │ │ │ │ └── ijk │ │ │ │ └── media │ │ │ │ └── player │ │ │ │ ├── AbstractMediaPlayer.java │ │ │ │ ├── AndroidMediaPlayer.java │ │ │ │ ├── IMediaPlayer.java │ │ │ │ ├── ISurfaceTextureHolder.java │ │ │ │ ├── ISurfaceTextureHost.java │ │ │ │ ├── IjkLibLoader.java │ │ │ │ ├── IjkMediaCodecInfo.java │ │ │ │ ├── IjkMediaMeta.java │ │ │ │ ├── IjkMediaPlayer.java │ │ │ │ ├── IjkTimedText.java │ │ │ │ ├── MediaInfo.java │ │ │ │ ├── MediaPlayerProxy.java │ │ │ │ ├── TextureMediaPlayer.java │ │ │ │ ├── annotations │ │ │ │ ├── AccessedByNative.java │ │ │ │ └── CalledByNative.java │ │ │ │ ├── exceptions │ │ │ │ └── IjkMediaException.java │ │ │ │ ├── ffmpeg │ │ │ │ └── FFmpegApi.java │ │ │ │ ├── misc │ │ │ │ ├── AndroidMediaFormat.java │ │ │ │ ├── AndroidTrackInfo.java │ │ │ │ ├── IAndroidIO.java │ │ │ │ ├── IMediaDataSource.java │ │ │ │ ├── IMediaFormat.java │ │ │ │ ├── ITrackInfo.java │ │ │ │ ├── IjkMediaFormat.java │ │ │ │ └── IjkTrackInfo.java │ │ │ │ └── pragma │ │ │ │ ├── DebugLog.java │ │ │ │ └── Pragma.java │ │ └── xyz │ │ │ └── doikki │ │ │ └── videoplayer │ │ │ ├── aliplayer │ │ │ ├── AliMediaPlayer.java │ │ │ └── AliyunMediaPlayerFactory.java │ │ │ ├── controller │ │ │ ├── BaseVideoController.java │ │ │ ├── ControlWrapper.java │ │ │ ├── GestureVideoController.java │ │ │ ├── IControlComponent.java │ │ │ ├── IGestureComponent.java │ │ │ ├── IVideoController.java │ │ │ ├── MediaPlayerControl.java │ │ │ └── OrientationHelper.java │ │ │ ├── exo │ │ │ ├── ExoMediaPlayer.java │ │ │ ├── ExoMediaPlayerFactory.java │ │ │ ├── ExoMediaSourceHelper.java │ │ │ ├── ExoTrackNameProvider.java │ │ │ ├── MyBundledHlsMediaChunkExtractor.java │ │ │ └── MyHlsExtractorFactory.java │ │ │ ├── ijk │ │ │ ├── IjkPlayer.java │ │ │ ├── IjkPlayerFactory.java │ │ │ └── RawDataSourceProvider.java │ │ │ ├── player │ │ │ ├── AbstractPlayer.java │ │ │ ├── AndroidMediaPlayer.java │ │ │ ├── AndroidMediaPlayerFactory.java │ │ │ ├── AudioFocusHelper.java │ │ │ ├── BaseVideoView.java │ │ │ ├── PlayerFactory.java │ │ │ ├── ProgressManager.java │ │ │ ├── VideoView.java │ │ │ ├── VideoViewConfig.java │ │ │ └── VideoViewManager.java │ │ │ ├── render │ │ │ ├── IRenderView.java │ │ │ ├── MeasureHelper.java │ │ │ ├── PlayerViewRenderView.java │ │ │ ├── PlayerViewRenderViewFactory.java │ │ │ ├── RenderViewFactory.java │ │ │ ├── TextureRenderView.java │ │ │ └── TextureRenderViewFactory.java │ │ │ └── util │ │ │ ├── CutoutUtil.java │ │ │ ├── L.java │ │ │ └── PlayerUtils.java │ ├── jniLibs │ │ ├── arm64-v8a │ │ │ ├── libijkffmpeg.so │ │ │ ├── libijkplayer.so │ │ │ ├── libijksdl.so │ │ │ ├── libp2p.so │ │ │ ├── libxl_stat.so │ │ │ └── libxl_thunder_sdk.so │ │ └── armeabi-v7a │ │ │ ├── libijkffmpeg.so │ │ │ ├── libijkplayer.so │ │ │ ├── libijksdl.so │ │ │ ├── libp2p.so │ │ │ ├── libxl_stat.so │ │ │ └── libxl_thunder_sdk.so │ └── res │ │ ├── color │ │ └── font_home_selector.xml │ │ ├── drawable-v21 │ │ ├── button_detail_all.xml │ │ ├── button_dialog_main.xml │ │ ├── button_dialog_vod.xml │ │ ├── button_home_select.xml │ │ └── shape_setting_model_focus.xml │ │ ├── drawable │ │ ├── anim_loading.xml │ │ ├── app_banner.png │ │ ├── app_bg.png │ │ ├── app_icon.png │ │ ├── bg_live.xml │ │ ├── box_controller_bottom_bg.xml │ │ ├── box_controller_top_bg.xml │ │ ├── button_detail_all.xml │ │ ├── button_detail_collect.xml │ │ ├── button_detail_link.xml │ │ ├── button_detail_preview.xml │ │ ├── button_dialog_main.xml │ │ ├── button_dialog_vod.xml │ │ ├── button_home_select.xml │ │ ├── button_home_sort_focus.xml │ │ ├── channel_num_bg.xml │ │ ├── flow_tag_bg.xml │ │ ├── hm_drawer.xml │ │ ├── hm_fav.xml │ │ ├── hm_folder.xml │ │ ├── hm_history.xml │ │ ├── hm_lan.xml │ │ ├── hm_left_right.xml │ │ ├── hm_live.xml │ │ ├── hm_mobile.xml │ │ ├── hm_push.xml │ │ ├── hm_search.xml │ │ ├── hm_settings.xml │ │ ├── hm_up_down.xml │ │ ├── hm_wifi.xml │ │ ├── hm_wifi_no.xml │ │ ├── htov.png │ │ ├── ic_clock.xml │ │ ├── ic_notify_next.png │ │ ├── ic_notify_pause.png │ │ ├── ic_notify_play.png │ │ ├── ic_notify_pre.png │ │ ├── ic_pause.png │ │ ├── ic_play_next.png │ │ ├── ic_play_pre.png │ │ ├── icon_alist.xml │ │ ├── icon_circle_node.xml │ │ ├── icon_circle_plus.xml │ │ ├── icon_clear.xml │ │ ├── icon_delete.xml │ │ ├── icon_drive.xml │ │ ├── icon_empty.xml │ │ ├── icon_error.xml │ │ ├── icon_file.xml │ │ ├── icon_film.xml │ │ ├── icon_filter.xml │ │ ├── icon_folder.xml │ │ ├── icon_home.xml │ │ ├── icon_img_placeholder.xml │ │ ├── icon_loading.png │ │ ├── icon_lock.xml │ │ ├── icon_sdcard.xml │ │ ├── icon_setting.xml │ │ ├── icon_sort.xml │ │ ├── icon_trash_solid.xml │ │ ├── icon_unlock.xml │ │ ├── img_loading_placeholder.xml │ │ ├── img_logo_placeholder.xml │ │ ├── input_dialog_api_input.xml │ │ ├── input_search.xml │ │ ├── item_bg_selector_left.xml │ │ ├── item_bg_selector_right.xml │ │ ├── item_right_bg.xml │ │ ├── play_brightness.xml │ │ ├── play_ffwd.xml │ │ ├── play_pause.xml │ │ ├── play_play.xml │ │ ├── play_progress_horizontal.xml │ │ ├── play_progress_vertical.xml │ │ ├── play_rewind.xml │ │ ├── play_skip.xml │ │ ├── play_volume.xml │ │ ├── scrollviewleft.xml │ │ ├── scrollviewright.xml │ │ ├── selector_checkbox.xml │ │ ├── set_hm.xml │ │ ├── set_play.xml │ │ ├── set_setting.xml │ │ ├── shape_dialog_bg.xml │ │ ├── shape_dialog_bg_main.xml │ │ ├── shape_dialog_filter_bg.xml │ │ ├── shape_live_bg_bottom.xml │ │ ├── shape_live_channel_num.xml │ │ ├── shape_live_focus.xml │ │ ├── shape_live_select.xml │ │ ├── shape_player_control_vod_seek.xml │ │ ├── shape_player_control_vod_seek_thumb.xml │ │ ├── shape_player_control_vod_seek_thumb_normal.xml │ │ ├── shape_player_control_vod_seek_thumb_press.xml │ │ ├── shape_player_tap.xml │ │ ├── shape_search_checkall.xml │ │ ├── shape_search_clearall.xml │ │ ├── shape_setting_model_focus.xml │ │ ├── shape_setting_sort_focus.xml │ │ ├── shape_source_flag_focus.xml │ │ ├── shape_source_flag_line.xml │ │ ├── shape_source_series_focus.xml │ │ ├── shape_speed_hint.xml │ │ ├── shape_thumb_bottom_name.xml │ │ ├── shape_thumb_lang.xml │ │ ├── shape_thumb_note.xml │ │ ├── shape_thumb_year.xml │ │ ├── shape_user_delete.xml │ │ ├── shape_user_focus.xml │ │ ├── shape_user_home.xml │ │ ├── shape_user_pause.xml │ │ ├── shape_user_pause_r.xml │ │ ├── shape_user_search.xml │ │ ├── subtitle_circle.xml │ │ ├── v_aspect.xml │ │ ├── v_audio.xml │ │ ├── v_back.xml │ │ ├── v_danmu.xml │ │ ├── v_ffwd.xml │ │ ├── v_next.xml │ │ ├── v_pause.xml │ │ ├── v_play.xml │ │ ├── v_prev.xml │ │ ├── v_replay.xml │ │ ├── v_subtitle.xml │ │ ├── v_type.xml │ │ ├── vod_ffwd.xml │ │ ├── vod_play.xml │ │ ├── vod_skip.xml │ │ └── vtoh.png │ │ ├── font │ │ └── advent_pro_extralight.ttf │ │ ├── layout-v21 │ │ ├── activity_play.xml │ │ ├── dialog_search_subtitle.xml │ │ ├── fragment_model.xml │ │ └── loadsir_loading_layout.xml │ │ ├── layout │ │ ├── activity_apps.xml │ │ ├── activity_collect.xml │ │ ├── activity_detail.xml │ │ ├── activity_drive.xml │ │ ├── activity_fast_search.xml │ │ ├── activity_history.xml │ │ ├── activity_home.xml │ │ ├── activity_live_play.xml │ │ ├── activity_play.xml │ │ ├── activity_push.xml │ │ ├── activity_search.xml │ │ ├── activity_setting.xml │ │ ├── dialog_about.xml │ │ ├── dialog_alistdrive.xml │ │ ├── dialog_api.xml │ │ ├── dialog_api_history.xml │ │ ├── dialog_backup.xml │ │ ├── dialog_checkbox_search.xml │ │ ├── dialog_confirm.xml │ │ ├── dialog_danmu_setting.xml │ │ ├── dialog_desc.xml │ │ ├── dialog_grid_filter.xml │ │ ├── dialog_homeoption.xml │ │ ├── dialog_live_password.xml │ │ ├── dialog_media_setting.xml │ │ ├── dialog_push.xml │ │ ├── dialog_quick_search.xml │ │ ├── dialog_remote.xml │ │ ├── dialog_reset.xml │ │ ├── dialog_search_subtitle.xml │ │ ├── dialog_select.xml │ │ ├── dialog_subtitle.xml │ │ ├── dialog_tip.xml │ │ ├── dialog_webdav.xml │ │ ├── dialog_xwalk.xml │ │ ├── fragment_grid.xml │ │ ├── fragment_model.xml │ │ ├── fragment_user.xml │ │ ├── item_apps.xml │ │ ├── item_button.xml │ │ ├── item_dialog_api_history.xml │ │ ├── item_dialog_backup.xml │ │ ├── item_dialog_checkbox_search.xml │ │ ├── item_dialog_select.xml │ │ ├── item_dialog_select2.xml │ │ ├── item_drive.xml │ │ ├── item_epglist.xml │ │ ├── item_fast_search_site.xml │ │ ├── item_grid.xml │ │ ├── item_grid_filter.xml │ │ ├── item_grid_filter_value.xml │ │ ├── item_home_sort.xml │ │ ├── item_keyboard.xml │ │ ├── item_list.xml │ │ ├── item_live_channel.xml │ │ ├── item_live_channel_group.xml │ │ ├── item_live_setting.xml │ │ ├── item_live_setting_group.xml │ │ ├── item_play_parse.xml │ │ ├── item_quick_search_lite.xml │ │ ├── item_search.xml │ │ ├── item_search_lite.xml │ │ ├── item_search_subtitle_result.xml │ │ ├── item_search_word_hot.xml │ │ ├── item_search_word_split.xml │ │ ├── item_series.xml │ │ ├── item_series_flag.xml │ │ ├── item_setting_menu.xml │ │ ├── item_user_hot_vod.xml │ │ ├── item_view_load_more.xml │ │ ├── layout_keyborad.xml │ │ ├── loadsir_empty_layout.xml │ │ ├── loadsir_loading_layout.xml │ │ ├── notification_player.xml │ │ ├── player_live_control_view.xml │ │ └── player_vod_control_view.xml │ │ ├── raw │ │ ├── index.html │ │ ├── jquery.js │ │ ├── script.js │ │ ├── style.css │ │ └── ui.css │ │ ├── values-zh │ │ └── strings.xml │ │ ├── values │ │ ├── attrs.xml │ │ ├── colors.xml │ │ ├── dimens.xml │ │ ├── strings.xml │ │ └── styles.xml │ │ └── xml │ │ ├── exo_play_view.xml │ │ ├── file_paths.xml │ │ └── network_security_config.xml │ ├── normal │ └── java │ │ └── com │ │ └── github │ │ └── catvod │ │ └── crawler │ │ └── pyLoader.java │ └── python │ └── java │ └── com │ ├── github │ └── catvod │ │ └── crawler │ │ └── pyLoader.java │ └── undcover │ └── freedom │ └── pyramid │ ├── PyLog.java │ ├── PyToast.java │ ├── PythonLoader.java │ └── PythonSpider.java ├── build.gradle ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── pyramid ├── build.gradle ├── consumer-rules.pro ├── proguard-rules.pro └── src │ ├── main │ └── AndroidManifest.xml │ └── python │ ├── app.py │ ├── base │ ├── htmlParser.py │ ├── localProxy.py │ └── spider.py │ ├── runner.py │ └── trigger.py ├── quickjs ├── build.gradle └── src │ └── main │ ├── AndroidManifest.xml │ ├── java │ └── com │ │ └── whl │ │ └── quickjs │ │ ├── android │ │ └── QuickJSLoader.java │ │ └── wrapper │ │ ├── BindingContext.java │ │ ├── ContextSetter.java │ │ ├── Function.java │ │ ├── JSArray.java │ │ ├── JSCallFunction.java │ │ ├── JSConsole.java │ │ ├── JSFunction.java │ │ ├── JSObject.java │ │ ├── JSUtils.java │ │ ├── ModuleLoader.java │ │ ├── NativeCleaner.java │ │ ├── QuickJSContext.java │ │ ├── QuickJSException.java │ │ └── UriUtil.java │ └── jniLibs │ ├── arm64-v8a │ └── libquickjs-android-wrapper.so │ └── armeabi-v7a │ └── libquickjs-android-wrapper.so ├── settings.gradle └── xwalk ├── crosswalk-apks-23.53.589.4-arm.zip ├── crosswalk-apks-23.53.589.4-arm64.zip ├── crosswalk-apks-23.53.589.4-x86.zip └── crosswalk-apks-23.53.589.4-x86_64.zip /.github/workflows/test.yml: -------------------------------------------------------------------------------- 1 | name: Test Build 2 | 3 | on: 4 | # push: 5 | # branches: 6 | # - main 7 | # pull_request: 8 | workflow_dispatch: 9 | 10 | jobs: 11 | build: 12 | runs-on: ubuntu-latest 13 | steps: 14 | - uses: actions/checkout@v3 15 | with: 16 | fetch-depth: 0 17 | - name: Build With Gradle 18 | run: | 19 | chmod +x gradlew 20 | ./gradlew assemblerelease --build-cache --parallel --daemon --warning-mode all 21 | - name: Prepare App 22 | run: | 23 | mkdir -p ${{ github.workspace }}/apk/ 24 | for file in `find ~ -name "*.apk" -print`; do 25 | mv "$file" ${{ github.workspace }}/apk/ 26 | done 27 | - name: Upload App To Artifact 28 | uses: actions/upload-artifact@v3 29 | with: 30 | name: com.github.tvbox.osc 31 | path: ${{ github.workspace }}/apk/* 32 | -------------------------------------------------------------------------------- /.idea/.name: -------------------------------------------------------------------------------- 1 | TVBox -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Box 2 | 3 | === Source Code - Editing the app default settings === 4 | /src/main/java/com/github/tvbox/osc/base/App.java 5 | 6 | private void initParams() { 7 | 8 | putDefault(HawkConfig.HOME_REC, 2); // Home Rec 0=豆瓣, 1=推荐, 2=历史 9 | putDefault(HawkConfig.PLAY_TYPE, 1); // Player 0=系统, 1=IJK, 2=Exo 10 | putDefault(HawkConfig.IJK_CODEC, "硬解码");// IJK Render 软解码, 硬解码 11 | putDefault(HawkConfig.HOME_SHOW_SOURCE, true); // true=Show, false=Not show 12 | putDefault(HawkConfig.HOME_NUM, 2); // History Number 13 | putDefault(HawkConfig.DOH_URL, 2); // DNS 14 | putDefault(HawkConfig.SEARCH_VIEW, 2); // Text or Picture 15 | 16 | } 17 | -------------------------------------------------------------------------------- /app/libs/dec-0.1.2.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/libs/dec-0.1.2.jar -------------------------------------------------------------------------------- /app/libs/lib-decoder-ffmpeg-release.aar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/libs/lib-decoder-ffmpeg-release.aar -------------------------------------------------------------------------------- /app/libs/thunder.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/libs/thunder.jar -------------------------------------------------------------------------------- /app/libs/xwalk_shared_library-23.53.589.4.aar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/libs/xwalk_shared_library-23.53.589.4.aar -------------------------------------------------------------------------------- /app/proguard-python.pro: -------------------------------------------------------------------------------- 1 | 2 | # Python支持 3 | -keep public class com.undcover.freedom.pyramid.** { *; } 4 | -dontwarn com.undcover.freedom.pyramid.** 5 | -keep public class com.chaquo.python.** { *; } 6 | -dontwarn com.chaquo.python.** 7 | -------------------------------------------------------------------------------- /app/schemas/com.github.tvbox.osc.data.AppDataBase/.gitignore: -------------------------------------------------------------------------------- 1 | *.json 2 | -------------------------------------------------------------------------------- /app/src/main/assets/js/lib/net.js: -------------------------------------------------------------------------------- 1 | let req = (url, options) => http(url, Object.assign({ 2 | async: false 3 | }, options)); 4 | 5 | function http(url, options = {}) { 6 | if (options?.async === false) return _http(url, options) 7 | return new Promise(resolve => _http(url, Object.assign({ 8 | complete: res => resolve(res) 9 | }, options))).catch(err => { 10 | console.error(err.name, err.message, err.stack) 11 | return { 12 | ok: false, 13 | status: 500, 14 | url 15 | } 16 | }) 17 | }; -------------------------------------------------------------------------------- /app/src/main/assets/ua.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/assets/ua.db -------------------------------------------------------------------------------- /app/src/main/java/com/acsbendi/requestinspectorwebview/RequestInspectorOptions.kt: -------------------------------------------------------------------------------- 1 | package com.acsbendi.requestinspectorwebview 2 | 3 | data class RequestInspectorOptions( 4 | val extraJavaScriptToInject: String = "" 5 | ) 6 | -------------------------------------------------------------------------------- /app/src/main/java/com/acsbendi/requestinspectorwebview/WebViewRequestType.kt: -------------------------------------------------------------------------------- 1 | package com.acsbendi.requestinspectorwebview 2 | 3 | enum class WebViewRequestType { 4 | FETCH, XML_HTTP, FORM, HTML 5 | } 6 | -------------------------------------------------------------------------------- /app/src/main/java/com/aminography/redirectglide/BaseApiCallGlideUrl.kt: -------------------------------------------------------------------------------- 1 | package com.aminography.redirectglide 2 | 3 | import com.aminography.redirectglide.OkHttpRedirectUrlFetcher.Companion.DEFAULT_MAX_REDIRECT 4 | import com.bumptech.glide.load.model.GlideUrl 5 | import com.bumptech.glide.load.model.Headers 6 | import java.net.URL 7 | 8 | /** 9 | * An extension of [GlideUrl] which parses the Api result to extract the image url. 10 | */ 11 | abstract class BaseApiCallGlideUrl : RedirectGlideUrl { 12 | 13 | constructor(url: URL?) : super(url, DEFAULT_MAX_REDIRECT) 14 | 15 | constructor(url: String?) : super(url, DEFAULT_MAX_REDIRECT) 16 | 17 | constructor(url: URL?, headers: Headers?) : super(url, headers, DEFAULT_MAX_REDIRECT) 18 | 19 | constructor(url: String?, headers: Headers?) : super(url, headers, DEFAULT_MAX_REDIRECT) 20 | 21 | /** 22 | * 23 | * @param apiResult the string result of calling Api 24 | * @return extracted image url from the apiResult 25 | */ 26 | abstract fun extractImageUrl(apiResult: String?): String? 27 | 28 | } -------------------------------------------------------------------------------- /app/src/main/java/com/aminography/redirectglide/OkHttpApiCallUrlFetcher.kt: -------------------------------------------------------------------------------- 1 | package com.aminography.redirectglide 2 | 3 | import com.bumptech.glide.load.HttpException 4 | import com.bumptech.glide.load.model.GlideUrl 5 | import okhttp3.Call 6 | import okhttp3.Callback 7 | import okhttp3.Response 8 | import java.io.IOException 9 | 10 | /** 11 | * Fetches an [GlideUrl] using the okhttp library. 12 | */ 13 | class OkHttpApiCallUrlFetcher( 14 | client: Call.Factory, 15 | url: BaseApiCallGlideUrl 16 | ) : OkHttpRedirectUrlFetcher(client, url), Callback { 17 | 18 | override fun consumeResponse(response: Response) { 19 | responseBody = response.body() 20 | if (response.isSuccessful && responseBody != null) { 21 | try { 22 | val sourceUrl = (url as BaseApiCallGlideUrl).extractImageUrl(responseBody?.string()) 23 | callback?.onDataReady(GlideUrl(sourceUrl)) 24 | } catch (e: IOException) { 25 | callback?.onLoadFailed(HttpException(response.message(), response.code())) 26 | e.printStackTrace() 27 | } 28 | } else { 29 | callback?.onLoadFailed(HttpException(response.message(), response.code())) 30 | } 31 | } 32 | 33 | } -------------------------------------------------------------------------------- /app/src/main/java/com/aminography/redirectglide/OkHttpAppGlideModule.kt: -------------------------------------------------------------------------------- 1 | package com.aminography.redirectglide 2 | 3 | import android.content.Context 4 | import com.bumptech.glide.Glide 5 | import com.bumptech.glide.Registry 6 | import com.bumptech.glide.annotation.GlideModule 7 | import com.bumptech.glide.load.model.GlideUrl 8 | import com.bumptech.glide.module.AppGlideModule 9 | import java.io.InputStream 10 | 11 | /** 12 | * Registers OkHttp related classes via Glide's annotation processor. 13 | * 14 | * 15 | * For Applications that depend on this library and include an 16 | * [AppGlideModule] and Glide's annotation processor, this class 17 | * will be automatically included. 18 | */ 19 | @GlideModule 20 | class OkHttpAppGlideModule : AppGlideModule() { 21 | 22 | override fun registerComponents(context: Context, glide: Glide, registry: Registry) { 23 | registry.replace(GlideUrl::class.java, InputStream::class.java, OkHttpUrlLoader.Factory()) 24 | } 25 | 26 | override fun isManifestParsingEnabled(): Boolean { 27 | return false 28 | } 29 | } -------------------------------------------------------------------------------- /app/src/main/java/com/aminography/redirectglide/RedirectException.kt: -------------------------------------------------------------------------------- 1 | package com.aminography.redirectglide 2 | 3 | import java.io.IOException 4 | 5 | /** 6 | * When an exception occurs during redirection, a [RedirectException] would be thrown. 7 | */ 8 | class RedirectException( 9 | val statusCode: Int, 10 | message: String? 11 | ) : IOException(message) -------------------------------------------------------------------------------- /app/src/main/java/com/aminography/redirectglide/RedirectGlideUrl.kt: -------------------------------------------------------------------------------- 1 | package com.aminography.redirectglide 2 | 3 | import com.bumptech.glide.load.model.GlideUrl 4 | import com.bumptech.glide.load.model.Headers 5 | import java.net.URL 6 | 7 | /** 8 | * An extension of [GlideUrl] which holds maximum number of possible redirection. 9 | */ 10 | open class RedirectGlideUrl : GlideUrl { 11 | 12 | var maxRedirectCount: Int 13 | private set 14 | 15 | constructor(url: URL?, maxRedirectCount: Int) : super(url) { 16 | this.maxRedirectCount = maxRedirectCount 17 | } 18 | 19 | constructor(url: String?, maxRedirectCount: Int) : super(url) { 20 | this.maxRedirectCount = maxRedirectCount 21 | } 22 | 23 | constructor(url: URL?, headers: Headers?, maxRedirectCount: Int) : super(url, headers) { 24 | this.maxRedirectCount = maxRedirectCount 25 | } 26 | 27 | constructor(url: String?, headers: Headers?, maxRedirectCount: Int) : super(url, headers) { 28 | this.maxRedirectCount = maxRedirectCount 29 | } 30 | 31 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/catvod/Init.java: -------------------------------------------------------------------------------- 1 | package com.github.catvod; 2 | 3 | import android.content.Context; 4 | 5 | import java.lang.ref.WeakReference; 6 | 7 | public class Init { 8 | 9 | private WeakReference context; 10 | 11 | private static class Loader { 12 | static volatile Init INSTANCE = new Init(); 13 | } 14 | 15 | private static Init get() { 16 | return Loader.INSTANCE; 17 | } 18 | 19 | public static void set(Context context) { 20 | get().context = new WeakReference<>(context); 21 | } 22 | 23 | public static Context context() { 24 | return get().context.get(); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/catvod/crawler/SpiderDebug.java: -------------------------------------------------------------------------------- 1 | package com.github.catvod.crawler; 2 | 3 | public class SpiderDebug { 4 | public static void log(Throwable th) { 5 | try { 6 | android.util.Log.d("SpiderLog", th.getMessage(), th); 7 | } catch (Throwable th1) { 8 | 9 | } 10 | } 11 | 12 | public static void log(String msg) { 13 | try { 14 | android.util.Log.d("SpiderLog", msg); 15 | } catch (Throwable th1) { 16 | 17 | } 18 | } 19 | 20 | public static String ec(int i) { 21 | return ""; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/catvod/crawler/SpiderNull.java: -------------------------------------------------------------------------------- 1 | package com.github.catvod.crawler; 2 | 3 | public class SpiderNull extends Spider { 4 | } 5 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/catvod/crawler/python/IPyLoader.java: -------------------------------------------------------------------------------- 1 | package com.github.catvod.crawler.python; 2 | 3 | import com.github.catvod.crawler.Spider; 4 | 5 | import java.util.Map; 6 | 7 | public interface IPyLoader { 8 | void clear(); 9 | void setConfig(String jsonStr); 10 | void setRecentPyKey(String pyApi); 11 | Spider getSpider(String key, String cls, String ext); 12 | Object[] proxyInvoke(Map params); 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/AbsSortXml.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import com.thoughtworks.xstream.annotations.XStreamAlias; 4 | 5 | import java.io.Serializable; 6 | import java.util.List; 7 | 8 | /** 9 | * @author pj567 10 | * @date :2020/12/18 11 | * @description: 12 | */ 13 | @XStreamAlias("rss") 14 | public class AbsSortXml implements Serializable { 15 | @XStreamAlias("class") 16 | public MovieSort classes; 17 | 18 | @XStreamAlias("list") 19 | public Movie list; 20 | 21 | public List videoList; 22 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/AbsXml.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import com.thoughtworks.xstream.annotations.XStreamAlias; 4 | 5 | import java.io.Serializable; 6 | 7 | /** 8 | * @author pj567 9 | * @date :2020/12/18 10 | * @description: 11 | */ 12 | @XStreamAlias("rss") 13 | public class AbsXml implements Serializable { 14 | @XStreamAlias("list") 15 | public Movie movie; 16 | 17 | @XStreamAlias("msg") 18 | public String msg; 19 | } 20 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/IJKCode.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import com.github.tvbox.osc.util.HawkConfig; 4 | import com.orhanobut.hawk.Hawk; 5 | 6 | import java.util.LinkedHashMap; 7 | 8 | /** 9 | * @author pj567 10 | * @date :2021/3/8 11 | * @description: 12 | */ 13 | public class IJKCode { 14 | private String name; 15 | private LinkedHashMap option; 16 | private boolean selected; 17 | 18 | public void selected(boolean selected) { 19 | this.selected = selected; 20 | if (selected) { 21 | Hawk.put(HawkConfig.IJK_CODEC, name); 22 | } 23 | } 24 | 25 | public boolean isSelected() { 26 | return selected; 27 | } 28 | 29 | public String getName() { 30 | return name; 31 | } 32 | 33 | public void setName(String name) { 34 | this.name = name; 35 | } 36 | 37 | public LinkedHashMap getOption() { 38 | return option; 39 | } 40 | 41 | public void setOption(LinkedHashMap option) { 42 | this.option = option; 43 | } 44 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/LiveEpgDate.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import java.util.Date; 4 | 5 | public class LiveEpgDate { 6 | 7 | private int index; 8 | private String datePresented; 9 | private Date dateParamVal; 10 | 11 | public int getIndex() { 12 | return index; 13 | } 14 | 15 | public void setIndex(int index) { 16 | this.index = index; 17 | } 18 | 19 | public String getDatePresented() { 20 | return datePresented; 21 | } 22 | 23 | public void setDatePresented(String datePresented) { 24 | this.datePresented = datePresented; 25 | } 26 | 27 | public Date getDateParamVal() { 28 | return dateParamVal; 29 | } 30 | 31 | public void setDateParamVal(Date dateParamVal) { 32 | this.dateParamVal = dateParamVal; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/LiveSettingGroup.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import java.util.ArrayList; 4 | 5 | public class LiveSettingGroup { 6 | private int groupIndex; 7 | private String groupName; 8 | private ArrayList liveSettingItems; 9 | 10 | public int getGroupIndex() { 11 | return groupIndex; 12 | } 13 | 14 | public void setGroupIndex(int groupIndex) { 15 | this.groupIndex = groupIndex; 16 | } 17 | 18 | public String getGroupName() { 19 | return groupName; 20 | } 21 | 22 | public void setGroupName(String groupName) { 23 | this.groupName = groupName; 24 | } 25 | 26 | public ArrayList getLiveSettingItems() { 27 | return liveSettingItems; 28 | } 29 | 30 | public void setLiveSettingItems(ArrayList liveSettingItems) { 31 | this.liveSettingItems = liveSettingItems; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/LiveSettingItem.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | /** 4 | * @author pj567 5 | * @date :2021/1/12 6 | * @description: 7 | */ 8 | public class LiveSettingItem { 9 | private int itemIndex; 10 | private String itemName; 11 | private boolean itemSelected = false; 12 | 13 | public int getItemIndex() { 14 | return itemIndex; 15 | } 16 | 17 | public void setItemIndex(int itemIndex) { 18 | this.itemIndex = itemIndex; 19 | } 20 | 21 | public String getItemName() { 22 | return itemName; 23 | } 24 | 25 | public void setItemName(String itemName) { 26 | this.itemName = itemName; 27 | } 28 | 29 | public boolean isItemSelected() { 30 | return itemSelected; 31 | } 32 | 33 | public void setItemSelected(boolean itemSelected) { 34 | this.itemSelected = itemSelected; 35 | } 36 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/SearchResultWrapper.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | public class SearchResultWrapper { 4 | private String wd; 5 | private AbsXml data; 6 | /** 7 | * @return the wd 8 | */ 9 | public String getWd() { 10 | return wd; 11 | } 12 | /** 13 | * @param wd the wd to set 14 | */ 15 | public void setWd(String wd) { 16 | this.wd = wd; 17 | } 18 | /** 19 | * @return the data 20 | */ 21 | public AbsXml getData() { 22 | return data; 23 | } 24 | /** 25 | * @param data the data to set 26 | */ 27 | public void setData(AbsXml data) { 28 | this.data = data; 29 | } 30 | 31 | 32 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/SubtitleBean.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | public class SubtitleBean { 4 | 5 | private String name; 6 | 7 | private String url; 8 | 9 | private boolean isZip; 10 | 11 | public boolean getIsZip() { 12 | return isZip; 13 | } 14 | 15 | public String getName() { 16 | return name; 17 | } 18 | 19 | public String getUrl() { 20 | return url; 21 | } 22 | 23 | public void setName(String name) { 24 | this.name = name; 25 | } 26 | 27 | public void setUrl(String url) { 28 | this.url = url; 29 | } 30 | 31 | public void setIsZip(boolean zip) { 32 | isZip = zip; 33 | } 34 | 35 | @Override 36 | public String toString() { 37 | return "SubtitleBean{" + 38 | "name='" + name + '\'' + 39 | ", url='" + url + '\'' + 40 | ", isZip=" + isZip + 41 | '}'; 42 | } 43 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/SubtitleData.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | import java.util.List; 4 | 5 | public class SubtitleData { 6 | 7 | private Boolean isNew; 8 | 9 | private List subtitleList; 10 | 11 | private Boolean isZip; 12 | 13 | public Boolean getIsNew() { 14 | return isNew; 15 | } 16 | 17 | public List getSubtitleList() { 18 | return subtitleList; 19 | } 20 | 21 | public Boolean getIsZip() { 22 | return isZip; 23 | } 24 | 25 | public void setIsNew(Boolean isNew) { 26 | this.isNew = isNew; 27 | } 28 | 29 | public void setSubtitleList(List subtitle) { 30 | this.subtitleList = subtitle; 31 | } 32 | 33 | public void setIsZip(Boolean zip) { 34 | isZip = zip; 35 | } 36 | 37 | @Override 38 | public String toString() { 39 | return "SubtitleData{" + 40 | "isNew='" + isNew + '\'' + 41 | '}'; 42 | } 43 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/bean/VodSeriesGroup.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.bean; 2 | 3 | public class VodSeriesGroup { 4 | public String name; 5 | public boolean selected = false; 6 | 7 | public VodSeriesGroup(String name) { 8 | this.name = name; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/Cache.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.annotation.NonNull; 4 | import androidx.room.Entity; 5 | import androidx.room.PrimaryKey; 6 | 7 | import java.io.Serializable; 8 | 9 | /** 10 | * 类描述: 11 | * 12 | * @author pj567 13 | * @since 2020/5/15 14 | */ 15 | @Entity(tableName = "cache") 16 | public class Cache implements Serializable { 17 | @PrimaryKey(autoGenerate = false) 18 | @NonNull 19 | public String key; 20 | public byte[] data; 21 | } 22 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/CacheDao.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.Dao; 4 | import androidx.room.Delete; 5 | import androidx.room.Insert; 6 | import androidx.room.OnConflictStrategy; 7 | import androidx.room.Query; 8 | import androidx.room.Update; 9 | 10 | /** 11 | * 类描述: 12 | * 13 | * @author pj567 14 | * @since 2020/5/15 15 | */ 16 | @Dao 17 | public interface CacheDao { 18 | @Insert(onConflict = OnConflictStrategy.REPLACE) 19 | long save(Cache cache); 20 | 21 | /** 22 | * 注意,冒号后面必须紧跟参数名,中间不能有空格。大于小于号和冒号中间是有空格的。 23 | * select *from cache where【表中列名】 =:【参数名】------>等于 24 | * where 【表中列名】 < :【参数名】 小于 25 | * where 【表中列名】 between :【参数名1】 and :【参数2】------->这个区间 26 | * where 【表中列名】like :参数名----->模糊查询 27 | * where 【表中列名】 in (:【参数名集合】)---->查询符合集合内指定字段值的记录 28 | * 29 | * @param key 30 | * @return 31 | */ 32 | 33 | //如果是一对多,这里可以写List 34 | @Query("select *from cache where `key`=:key") 35 | Cache getCache(String key); 36 | 37 | //只能传递对象昂,删除时根据Cache中的主键 来比对的 38 | @Delete 39 | int delete(Cache cache); 40 | 41 | //只能传递对象昂,删除时根据Cache中的主键 来比对的 42 | @Update(onConflict = OnConflictStrategy.REPLACE) 43 | int update(Cache cache); 44 | } 45 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/SearchDao.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.Dao; 4 | import androidx.room.Delete; 5 | import androidx.room.Insert; 6 | import androidx.room.Query; 7 | 8 | import java.util.List; 9 | 10 | @Dao 11 | public interface SearchDao { 12 | 13 | @Insert 14 | void insert(SearchHistory trackData); 15 | 16 | @Delete 17 | void delete(SearchHistory trackData); 18 | 19 | @Query("SELECT * FROM T_SEARCH") 20 | List getAll(); 21 | 22 | @Query("SELECT * FROM T_SEARCH WHERE searchKeyWords=:keyword") 23 | List getByKeywords(String keyword); 24 | 25 | } 26 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/SearchHistory.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.ColumnInfo; 4 | import androidx.room.Entity; 5 | import androidx.room.Index; 6 | import androidx.room.PrimaryKey; 7 | 8 | 9 | /** 10 | * 11 | */ 12 | 13 | @Entity(tableName = SearchHistory.TABLE_NAME, indices = {@Index("searchKeyWords")}) 14 | public class SearchHistory { 15 | 16 | public static final String TABLE_NAME = "t_search"; 17 | 18 | @PrimaryKey(autoGenerate = true) 19 | public int id; 20 | 21 | @ColumnInfo(name = "searchKeyWords") 22 | public String searchKeyWords; 23 | } 24 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/StorageDrive.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.ColumnInfo; 4 | import androidx.room.Entity; 5 | import androidx.room.PrimaryKey; 6 | 7 | @Entity(tableName = "storageDrive") 8 | public class StorageDrive { 9 | @PrimaryKey(autoGenerate = true) 10 | private int id; 11 | @ColumnInfo(name = "name") 12 | public String name; 13 | @ColumnInfo(name = "type") 14 | public int type; 15 | @ColumnInfo(name = "configJson") 16 | public String configJson; 17 | 18 | public int getId() { 19 | return id; 20 | } 21 | 22 | public void setId(int id) { 23 | this.id = id; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/StorageDriveDao.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.Dao; 4 | import androidx.room.Insert; 5 | import androidx.room.OnConflictStrategy; 6 | import androidx.room.Query; 7 | 8 | import java.util.List; 9 | 10 | /** 11 | * @author pj567 12 | * @date :2021/1/7 13 | * @description: 14 | */ 15 | @Dao 16 | public interface StorageDriveDao { 17 | @Insert(onConflict = OnConflictStrategy.REPLACE) 18 | long insert(StorageDrive drive); 19 | 20 | @Query("select * from storageDrive order by id") 21 | List getAll(); 22 | 23 | @Query("delete from storageDrive where `id`=:id") 24 | void delete(int id); 25 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/VodCollect.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.ColumnInfo; 4 | import androidx.room.Entity; 5 | import androidx.room.PrimaryKey; 6 | 7 | import java.io.Serializable; 8 | 9 | @Entity(tableName = "vodCollect") 10 | public class VodCollect implements Serializable { 11 | @PrimaryKey(autoGenerate = true) 12 | private int id; 13 | @ColumnInfo(name = "vodId") 14 | public String vodId; 15 | @ColumnInfo(name = "updateTime") 16 | public long updateTime; 17 | @ColumnInfo(name = "sourceKey") 18 | public String sourceKey; 19 | @ColumnInfo(name = "name") 20 | public String name; 21 | @ColumnInfo(name = "pic") 22 | public String pic; 23 | 24 | public int getId() { 25 | return id; 26 | } 27 | 28 | public void setId(int id) { 29 | this.id = id; 30 | } 31 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/VodCollectDao.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.Dao; 4 | import androidx.room.Delete; 5 | import androidx.room.Insert; 6 | import androidx.room.OnConflictStrategy; 7 | import androidx.room.Query; 8 | 9 | import java.util.List; 10 | 11 | /** 12 | * @author pj567 13 | * @date :2021/1/7 14 | * @description: 15 | */ 16 | @Dao 17 | public interface VodCollectDao { 18 | @Insert(onConflict = OnConflictStrategy.REPLACE) 19 | long insert(VodCollect record); 20 | 21 | @Query("select * from vodCollect order by updateTime desc") 22 | List getAll(); 23 | 24 | @Query("select * from vodCollect where `id`=:id") 25 | VodCollect getVodCollect(int id); 26 | 27 | @Query("delete from vodCollect where `id`=:id") 28 | void delete(int id); 29 | 30 | @Query("select * from vodCollect where `sourceKey`=:sourceKey and `vodId`=:vodId") 31 | VodCollect getVodCollect(String sourceKey, String vodId); 32 | 33 | @Delete 34 | int delete(VodCollect record); 35 | 36 | @Query("DELETE FROM vodCollect") 37 | void deleteAll(); 38 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/cache/VodRecord.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.cache; 2 | 3 | import androidx.room.ColumnInfo; 4 | import androidx.room.Entity; 5 | import androidx.room.PrimaryKey; 6 | 7 | import java.io.Serializable; 8 | 9 | /** 10 | * @author pj567 11 | * @date :2021/1/7 12 | * @description: 13 | */ 14 | @Entity(tableName = "vodRecord") 15 | public class VodRecord implements Serializable { 16 | @PrimaryKey(autoGenerate = true) 17 | private int id; 18 | @ColumnInfo(name = "vodId") 19 | public String vodId; 20 | @ColumnInfo(name = "updateTime") 21 | public long updateTime; 22 | @ColumnInfo(name = "sourceKey") 23 | public String sourceKey; 24 | public String dataJson; 25 | 26 | public int getId() { 27 | return id; 28 | } 29 | 30 | public void setId(int id) { 31 | this.id = id; 32 | } 33 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/callback/EmptyCallback.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.callback; 2 | 3 | import com.github.tvbox.osc.R; 4 | import com.kingja.loadsir.callback.Callback; 5 | 6 | /** 7 | * @author pj567 8 | * @date :2020/12/24 9 | * @description: 10 | */ 11 | public class EmptyCallback extends Callback { 12 | @Override 13 | protected int onCreateView() { 14 | return R.layout.loadsir_empty_layout; 15 | } 16 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/callback/LoadingCallback.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.callback; 2 | 3 | import com.github.tvbox.osc.R; 4 | import com.kingja.loadsir.callback.Callback; 5 | 6 | /** 7 | * @author pj567 8 | * @date :2020/12/24 9 | * @description: 10 | */ 11 | public class LoadingCallback extends Callback { 12 | @Override 13 | protected int onCreateView() { 14 | return R.layout.loadsir_loading_layout; 15 | } 16 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/data/AppDataBase.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.data; 2 | 3 | import androidx.room.Database; 4 | import androidx.room.RoomDatabase; 5 | 6 | import com.github.tvbox.osc.cache.Cache; 7 | import com.github.tvbox.osc.cache.CacheDao; 8 | import com.github.tvbox.osc.cache.SearchDao; 9 | import com.github.tvbox.osc.cache.SearchHistory; 10 | import com.github.tvbox.osc.cache.StorageDrive; 11 | import com.github.tvbox.osc.cache.StorageDriveDao; 12 | import com.github.tvbox.osc.cache.VodCollect; 13 | import com.github.tvbox.osc.cache.VodCollectDao; 14 | import com.github.tvbox.osc.cache.VodRecord; 15 | import com.github.tvbox.osc.cache.VodRecordDao; 16 | 17 | 18 | /** 19 | * 类描述: 20 | * 21 | * @author pj567 22 | * @since 2020/5/15 23 | */ 24 | @Database(entities = {Cache.class, VodRecord.class, VodCollect.class, StorageDrive.class, SearchHistory.class}, version = 3) 25 | public abstract class AppDataBase extends RoomDatabase { 26 | public abstract CacheDao getCacheDao(); 27 | 28 | public abstract VodRecordDao getVodRecordDao(); 29 | 30 | public abstract VodCollectDao getVodCollectDao(); 31 | 32 | public abstract StorageDriveDao getStorageDriveDao(); 33 | 34 | public abstract SearchDao getSearchDao(); 35 | } 36 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/data/SearchPresenter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.data; 2 | 3 | import com.github.tvbox.osc.cache.SearchHistory; 4 | 5 | import java.util.ArrayList; 6 | 7 | public class SearchPresenter { 8 | 9 | public boolean keywordsExist(String keyword) { 10 | return DbHelper.checkKeyWords(keyword); 11 | } 12 | 13 | public ArrayList getSearchHistory() { 14 | return DbHelper.getAllHistory(); 15 | } 16 | 17 | public void addKeyWordsTodb(String keyword) { 18 | DbHelper.addKeywords(keyword); 19 | } 20 | 21 | public void clearSearchHistory() { 22 | DbHelper.clearKeywords(); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/event/HistoryStateEvent.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.event; 2 | 3 | /** 4 | * @author pj567 5 | * @date :2020/12/21 6 | * @description: 7 | */ 8 | public class HistoryStateEvent { 9 | public final static int TYPE_TOP = 0; 10 | public int type; 11 | 12 | public HistoryStateEvent(int type) { 13 | this.type = type; 14 | } 15 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/event/InputMsgEvent.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.event; 2 | 3 | public class InputMsgEvent { 4 | private String text; 5 | 6 | public InputMsgEvent(String str) { 7 | this.text = str; 8 | } 9 | 10 | public String getText() { 11 | return this.text; 12 | } 13 | 14 | public void setText(String str) { 15 | this.text = str; 16 | } 17 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/event/LogEvent.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.event; 2 | 3 | public class LogEvent { 4 | private String text; 5 | 6 | public LogEvent(String str) { 7 | this.text = str; 8 | } 9 | 10 | public String getText() { 11 | return this.text; 12 | } 13 | 14 | public void setText(String str) { 15 | this.text = str; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/event/ServerEvent.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.event; 2 | 3 | /** 4 | * @author pj567 5 | * @date :2021/1/5 6 | * @description: 7 | */ 8 | public class ServerEvent { 9 | public static final int SERVER_SUCCESS = 0; 10 | public static final int SERVER_CONNECTION = 1; 11 | public static final int SERVER_SEARCH = 2; 12 | public int type; 13 | public Object obj; 14 | 15 | public ServerEvent(int type) { 16 | this.type = type; 17 | } 18 | 19 | public ServerEvent(int type, Object obj) { 20 | this.type = type; 21 | this.obj = obj; 22 | } 23 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/event/TopStateEvent.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.event; 2 | 3 | /** 4 | * @author pj567 5 | * @date :2020/12/21 6 | * @description: 7 | */ 8 | public class TopStateEvent { 9 | public final static int TYPE_TOP = 0; 10 | public int type; 11 | 12 | public TopStateEvent(int type) { 13 | this.type = type; 14 | } 15 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/player/TrackInfoBean.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.player; 2 | 3 | public class TrackInfoBean { 4 | public int trackId; 5 | //渲染器ID(exo) 6 | public int renderId; 7 | //分组ID(exo) 8 | public int trackGroupId; 9 | 10 | public String name; 11 | public String language; 12 | public boolean selected; 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/player/render/SurfaceRenderViewFactory.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.player.render; 2 | 3 | import android.content.Context; 4 | 5 | import xyz.doikki.videoplayer.render.IRenderView; 6 | import xyz.doikki.videoplayer.render.RenderViewFactory; 7 | 8 | public class SurfaceRenderViewFactory extends RenderViewFactory { 9 | 10 | public static SurfaceRenderViewFactory create() { 11 | return new SurfaceRenderViewFactory(); 12 | } 13 | 14 | @Override 15 | public IRenderView createRenderView(Context context) { 16 | return new SurfaceRenderView(context); 17 | } 18 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/server/DataReceiver.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.server; 2 | 3 | /** 4 | * @author pj567 5 | * @date :2021/1/5 6 | * @description: 7 | */ 8 | public interface DataReceiver { 9 | 10 | /** 11 | * @param text 12 | */ 13 | void onTextReceived(String text); 14 | 15 | void onApiReceived(String url); 16 | 17 | void onLiveReceived(String url); 18 | 19 | void onEpgReceived(String url); 20 | 21 | void onProxysReceived(String url); 22 | 23 | void onPushReceived(String url); 24 | 25 | void onMirrorReceived(String id, String sourceKey); 26 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/server/RequestProcess.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.server; 2 | 3 | import java.util.Map; 4 | 5 | import fi.iki.elonen.NanoHTTPD; 6 | 7 | /** 8 | * @author pj567 9 | * @date :2021/1/5 10 | * @description: 11 | */ 12 | public interface RequestProcess { 13 | public static final int KEY_ACTION_PRESSED = 0; 14 | public static final int KEY_ACTION_DOWN = 1; 15 | public static final int KEY_ACTION_UP = 2; 16 | 17 | /** 18 | * isRequest 19 | * 20 | * @param session 21 | * @param fileName 22 | * @return 23 | */ 24 | boolean isRequest(NanoHTTPD.IHTTPSession session, String fileName); 25 | 26 | /** 27 | * doResponse 28 | * 29 | * @param session 30 | * @param fileName 31 | * @param params 32 | * @param files 33 | * @return 34 | */ 35 | NanoHTTPD.Response doResponse(NanoHTTPD.IHTTPSession session, String fileName, Map params, Map files); 36 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/server/WebController.kt: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.server 2 | 3 | import com.github.tvbox.osc.event.RefreshEvent 4 | import com.yanzhenjie.andserver.annotation.GetMapping 5 | import com.yanzhenjie.andserver.annotation.QueryParam 6 | import com.yanzhenjie.andserver.annotation.ResponseBody 7 | import com.yanzhenjie.andserver.annotation.RestController 8 | import org.greenrobot.eventbus.EventBus 9 | 10 | @RestController 11 | class WebController { 12 | 13 | @GetMapping(path = ["/index.html", "/api/remote/version"]) 14 | @ResponseBody 15 | fun hello(): String { 16 | return "hello" 17 | } 18 | 19 | @GetMapping("/api/updateUrl") 20 | @ResponseBody 21 | fun play(@QueryParam("url") url: String): String { 22 | return try { 23 | EventBus.getDefault().post(RefreshEvent(RefreshEvent.TYPE_PUSH_URL, url)) 24 | "ok" 25 | } catch (e: Exception) { 26 | e.printStackTrace() 27 | "error:" + e.message 28 | } 29 | } 30 | 31 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/subtitle/SubtitleLoadSuccessResult.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.subtitle; 2 | 3 | import com.github.tvbox.osc.subtitle.model.TimedTextObject; 4 | 5 | public class SubtitleLoadSuccessResult { 6 | public String fileName; 7 | public String content; 8 | public TimedTextObject timedTextObject; 9 | public String subtitlePath; 10 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/subtitle/UIRenderTask.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.subtitle; 2 | 3 | import com.github.tvbox.osc.subtitle.model.Subtitle; 4 | import com.github.tvbox.osc.subtitle.runtime.AppTaskExecutor; 5 | 6 | /** 7 | * @author AveryZhong. 8 | */ 9 | 10 | public class UIRenderTask implements Runnable { 11 | 12 | private Subtitle mSubtitle; 13 | private SubtitleEngine.OnSubtitleChangeListener mOnSubtitleChangeListener; 14 | 15 | public UIRenderTask(final SubtitleEngine.OnSubtitleChangeListener l) { 16 | mOnSubtitleChangeListener = l; 17 | } 18 | 19 | @Override 20 | public void run() { 21 | if (mOnSubtitleChangeListener != null) { 22 | mOnSubtitleChangeListener.onSubtitleChanged(mSubtitle); 23 | } 24 | } 25 | 26 | public void execute(final Subtitle subtitle) { 27 | mSubtitle = subtitle; 28 | AppTaskExecutor.mainThread().execute(this); 29 | } 30 | 31 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/subtitle/runtime/DefaultTaskExecutor.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.subtitle.runtime; 2 | 3 | import android.os.Handler; 4 | import android.os.Looper; 5 | 6 | import androidx.annotation.Nullable; 7 | 8 | import java.util.concurrent.ExecutorService; 9 | import java.util.concurrent.Executors; 10 | 11 | /** 12 | * @author AveryZhong. 13 | */ 14 | 15 | public class DefaultTaskExecutor extends TaskExecutor { 16 | 17 | @Nullable 18 | private Handler mMainHandler; 19 | private final Object mLock = new Object(); 20 | private final ExecutorService mDeskIO = Executors.newFixedThreadPool(3); 21 | 22 | @Override 23 | public void executeOnDeskIO(final Runnable task) { 24 | mDeskIO.execute(task); 25 | } 26 | 27 | @Override 28 | public void postToMainThread(final Runnable task) { 29 | if (mMainHandler == null) { 30 | synchronized (mLock) { 31 | mMainHandler = new Handler(Looper.getMainLooper()); 32 | } 33 | } 34 | mMainHandler.post(task); 35 | } 36 | 37 | @Override 38 | public boolean isMainThread() { 39 | return Thread.currentThread() == Looper.getMainLooper().getThread(); 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/subtitle/runtime/TaskExecutor.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.subtitle.runtime; 2 | 3 | /** 4 | * @author AveryZhong. 5 | */ 6 | 7 | public abstract class TaskExecutor { 8 | 9 | public abstract void executeOnDeskIO(Runnable task); 10 | 11 | public void executeOnMainThread(Runnable task) { 12 | if (isMainThread()) { 13 | task.run(); 14 | } else { 15 | postToMainThread(task); 16 | } 17 | } 18 | 19 | public abstract void postToMainThread(Runnable task); 20 | 21 | public abstract boolean isMainThread(); 22 | 23 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/AppsAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import android.view.View; 4 | import android.widget.FrameLayout; 5 | import android.widget.ImageView; 6 | 7 | import com.chad.library.adapter.base.BaseQuickAdapter; 8 | import com.chad.library.adapter.base.BaseViewHolder; 9 | import com.github.tvbox.osc.R; 10 | import com.github.tvbox.osc.bean.AppInfo; 11 | import com.github.tvbox.osc.util.HawkConfig; 12 | 13 | import java.util.ArrayList; 14 | 15 | public class AppsAdapter extends BaseQuickAdapter { 16 | public AppsAdapter() { 17 | super(R.layout.item_apps, new ArrayList<>()); 18 | } 19 | 20 | @Override 21 | protected void convert(BaseViewHolder helper, AppInfo item) { 22 | // takagen99: Add Delete Mode 23 | FrameLayout tvDel = helper.getView(R.id.delFrameLayout); 24 | if (HawkConfig.hotVodDelete) { 25 | tvDel.setVisibility(View.VISIBLE); 26 | } else { 27 | tvDel.setVisibility(View.GONE); 28 | } 29 | 30 | helper.setText(R.id.appName, item.getName()); 31 | ImageView ivApps = helper.getView(R.id.ivApps); 32 | ivApps.setImageDrawable(item.getIcon()); 33 | } 34 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/BackupAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | 7 | import java.util.ArrayList; 8 | 9 | public class BackupAdapter extends BaseQuickAdapter { 10 | public BackupAdapter() { 11 | super(R.layout.item_dialog_backup, new ArrayList<>()); 12 | } 13 | 14 | @Override 15 | protected void convert(BaseViewHolder helper, String item) { 16 | helper.setText(R.id.tvName, item); 17 | helper.addOnClickListener(R.id.tvName); 18 | helper.addOnClickListener(R.id.tvDel); 19 | } 20 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/GridFilterKVAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | 7 | import java.util.ArrayList; 8 | 9 | public class GridFilterKVAdapter extends BaseQuickAdapter { 10 | public GridFilterKVAdapter() { 11 | super(R.layout.item_grid_filter_value, new ArrayList<>()); 12 | } 13 | 14 | @Override 15 | protected void convert(BaseViewHolder helper, String item) { 16 | helper.setText(R.id.filterValue, item); 17 | } 18 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/PinyinAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | 7 | import java.util.ArrayList; 8 | 9 | public class PinyinAdapter extends BaseQuickAdapter { 10 | public PinyinAdapter() { 11 | super(R.layout.item_search_word_hot, new ArrayList<>()); 12 | } 13 | 14 | @Override 15 | protected void convert(BaseViewHolder helper, String item) { 16 | helper.setText(R.id.tvSearchWord, item); 17 | } 18 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/QuickSearchAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | import com.github.tvbox.osc.api.ApiConfig; 7 | import com.github.tvbox.osc.bean.Movie; 8 | 9 | import java.util.ArrayList; 10 | 11 | /** 12 | * @author pj567 13 | * @date :2020/12/23 14 | * @description: 15 | */ 16 | public class QuickSearchAdapter extends BaseQuickAdapter { 17 | public QuickSearchAdapter() { 18 | super(R.layout.item_quick_search_lite, new ArrayList<>()); 19 | } 20 | 21 | @Override 22 | protected void convert(BaseViewHolder helper, Movie.Video item) { 23 | // lite 24 | helper.setText(R.id.tvName, String.format("%s %s %s %s", ApiConfig.get().getSource(item.sourceKey).getName(), item.name, item.type == null ? "" : item.type, item.note == null ? "" : item.note)); 25 | } 26 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SearchSubtitleAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | import com.github.tvbox.osc.bean.SubtitleBean; 7 | 8 | import java.util.ArrayList; 9 | 10 | public class SearchSubtitleAdapter extends BaseQuickAdapter { 11 | 12 | public SearchSubtitleAdapter() { 13 | super(R.layout.item_search_subtitle_result, new ArrayList<>()); 14 | } 15 | 16 | @Override 17 | protected void convert(BaseViewHolder helper, SubtitleBean item) { 18 | helper.setText(R.id.subtitleName, item.getName()); 19 | helper.setText(R.id.subtitleNameInfo, item.getIsZip() ? "压缩包" : "文件"); 20 | } 21 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SearchWordAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | 7 | import java.util.ArrayList; 8 | 9 | /** 10 | * @author pj567 11 | * @date :2020/12/23 12 | * @description: 13 | */ 14 | public class SearchWordAdapter extends BaseQuickAdapter { 15 | public SearchWordAdapter() { 16 | super(R.layout.item_search_word_split, new ArrayList<>()); 17 | } 18 | 19 | @Override 20 | protected void convert(BaseViewHolder helper, String item) { 21 | helper.setText(R.id.tvSearchWord, item); 22 | } 23 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SeriesFlagAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import android.view.View; 4 | import android.widget.TextView; 5 | 6 | import com.chad.library.adapter.base.BaseQuickAdapter; 7 | import com.chad.library.adapter.base.BaseViewHolder; 8 | import com.github.tvbox.osc.R; 9 | import com.github.tvbox.osc.bean.VodInfo; 10 | 11 | import java.util.ArrayList; 12 | 13 | /** 14 | * @author pj567 15 | * @date :2020/12/22 16 | * @description: 17 | */ 18 | public class SeriesFlagAdapter extends BaseQuickAdapter { 19 | public SeriesFlagAdapter() { 20 | super(R.layout.item_series_flag, new ArrayList<>()); 21 | } 22 | 23 | @Override 24 | protected void convert(BaseViewHolder helper, VodInfo.VodSeriesFlag item) { 25 | TextView tvSeries = helper.getView(R.id.tvSeriesFlag); 26 | View select = helper.getView(R.id.tvSeriesFlagSelect); 27 | if (item.selected) { 28 | select.setVisibility(View.VISIBLE); 29 | } else { 30 | select.setVisibility(View.GONE); 31 | } 32 | helper.setText(R.id.tvSeriesFlag, item.name); 33 | } 34 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SeriesGroupAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import android.view.View; 4 | import android.widget.TextView; 5 | 6 | import com.chad.library.adapter.base.BaseQuickAdapter; 7 | import com.chad.library.adapter.base.BaseViewHolder; 8 | import com.github.tvbox.osc.R; 9 | import com.github.tvbox.osc.bean.VodSeriesGroup; 10 | 11 | import java.util.ArrayList; 12 | 13 | public class SeriesGroupAdapter extends BaseQuickAdapter { 14 | public SeriesGroupAdapter() { 15 | super(R.layout.item_series_flag, new ArrayList<>()); 16 | } 17 | 18 | @Override 19 | protected void convert(BaseViewHolder helper, VodSeriesGroup item) { 20 | TextView tvSeries = helper.getView(R.id.tvSeriesFlag); 21 | View select = helper.getView(R.id.tvSeriesFlagSelect); 22 | if (item.selected) { 23 | select.setVisibility(View.VISIBLE); 24 | } else { 25 | select.setVisibility(View.GONE); 26 | } 27 | tvSeries.setText(item.name); 28 | } 29 | 30 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SettingMenuAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | 7 | import java.util.ArrayList; 8 | 9 | /** 10 | * @author pj567 11 | * @date :2020/12/23 12 | * @description: 13 | */ 14 | public class SettingMenuAdapter extends BaseQuickAdapter { 15 | public SettingMenuAdapter() { 16 | super(R.layout.item_setting_menu, new ArrayList<>()); 17 | } 18 | 19 | @Override 20 | protected void convert(BaseViewHolder helper, String item) { 21 | helper.setText(R.id.tvName, item); 22 | helper.addOnClickListener(R.id.tvName); 23 | } 24 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/adapter/SortAdapter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.adapter; 2 | 3 | import com.chad.library.adapter.base.BaseQuickAdapter; 4 | import com.chad.library.adapter.base.BaseViewHolder; 5 | import com.github.tvbox.osc.R; 6 | import com.github.tvbox.osc.bean.MovieSort; 7 | 8 | import java.util.ArrayList; 9 | 10 | /** 11 | * @author pj567 12 | * @date :2020/12/21 13 | * @description: 14 | */ 15 | public class SortAdapter extends BaseQuickAdapter { 16 | public SortAdapter() { 17 | super(R.layout.item_home_sort, new ArrayList<>()); 18 | } 19 | 20 | @Override 21 | protected void convert(BaseViewHolder helper, MovieSort.SortData item) { 22 | helper.setText(R.id.tvTitle, item.name); 23 | } 24 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/dialog/AboutDialog.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.dialog; 2 | 3 | import android.content.Context; 4 | 5 | import androidx.annotation.NonNull; 6 | 7 | import com.github.tvbox.osc.R; 8 | 9 | import org.jetbrains.annotations.NotNull; 10 | 11 | public class AboutDialog extends BaseDialog { 12 | 13 | public AboutDialog(@NonNull @NotNull Context context) { 14 | super(context); 15 | setContentView(R.layout.dialog_about); 16 | } 17 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/dialog/DescDialog.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.dialog; 2 | 3 | import android.content.Context; 4 | import android.content.DialogInterface; 5 | import android.widget.TextView; 6 | import androidx.annotation.NonNull; 7 | import com.github.tvbox.osc.R; 8 | import org.greenrobot.eventbus.EventBus; 9 | import org.jetbrains.annotations.NotNull; 10 | 11 | public class DescDialog extends BaseDialog { 12 | 13 | public DescDialog(@NonNull @NotNull Context context) { 14 | super(context); 15 | setContentView(R.layout.dialog_desc); 16 | } 17 | 18 | public void setDescribe(String describe) { 19 | TextView tvDescribe = findViewById(R.id.describe); 20 | tvDescribe.setText(describe); 21 | tvDescribe.requestFocus(); 22 | tvDescribe.requestFocusFromTouch(); 23 | } 24 | 25 | private void init(Context context) { 26 | EventBus.getDefault().register(this); 27 | setOnDismissListener(new DialogInterface.OnDismissListener() { 28 | @Override 29 | public void onDismiss(DialogInterface dialog) { 30 | EventBus.getDefault().unregister(this); 31 | } 32 | }); 33 | } 34 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/tv/widget/CustomEditText.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.tv.widget; 2 | 3 | import android.content.Context; 4 | import android.text.TextUtils; 5 | import android.util.AttributeSet; 6 | import androidx.appcompat.widget.AppCompatEditText; 7 | 8 | /** 9 | * 用于光标总是文本最后 10 | */ 11 | public class CustomEditText extends AppCompatEditText { 12 | 13 | public CustomEditText(Context context, AttributeSet attrs, int defStyle) { 14 | super(context, attrs, defStyle); 15 | } 16 | 17 | public CustomEditText(Context context, AttributeSet attrs) { 18 | super(context, attrs); 19 | } 20 | 21 | public CustomEditText(Context context) { 22 | super(context); 23 | } 24 | 25 | @Override 26 | protected void onSelectionChanged(int selStart, int selEnd) { 27 | super.onSelectionChanged(selStart, selEnd); 28 | //保证光标始终在最后面 29 | if(selStart==selEnd){//防止不能多选 30 | if(!TextUtils.isEmpty(getText())){ 31 | setSelection(getText().length()); 32 | } 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/tv/widget/DefaultTransformer.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.tv.widget; 2 | 3 | import android.view.View; 4 | 5 | import androidx.viewpager.widget.ViewPager; 6 | 7 | /** 8 | * @author acer 9 | * @date 2018/8/22 11:46 10 | */ 11 | public class DefaultTransformer implements ViewPager.PageTransformer{ 12 | @Override 13 | public void transformPage(View page, float position) { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/tv/widget/LoadMoreView.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.tv.widget; 2 | 3 | 4 | import com.github.tvbox.osc.R; 5 | 6 | public final class LoadMoreView extends com.chad.library.adapter.base.loadmore.LoadMoreView { 7 | 8 | @Override 9 | public int getLayoutId() { 10 | return R.layout.item_view_load_more; 11 | } 12 | 13 | @Override 14 | protected int getLoadingViewId() { 15 | return R.id.load_more_loading_view; 16 | } 17 | 18 | @Override 19 | protected int getLoadFailViewId() { 20 | return R.id.load_more_load_fail_view; 21 | } 22 | 23 | @Override 24 | protected int getLoadEndViewId() { 25 | return R.id.load_more_load_end_view; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/ui/tv/widget/MarqueeTextView.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.ui.tv.widget; 2 | 3 | import android.annotation.SuppressLint; 4 | import android.content.Context; 5 | import android.text.TextUtils; 6 | import android.util.AttributeSet; 7 | import android.widget.TextView; 8 | 9 | import androidx.annotation.Nullable; 10 | 11 | /** 12 | * Created by acer on 2018/7/13. 13 | */ 14 | 15 | @SuppressLint("AppCompatCustomView") 16 | public class MarqueeTextView extends TextView{ 17 | public MarqueeTextView(Context context) { 18 | this(context, null); 19 | } 20 | 21 | public MarqueeTextView(Context context, @Nullable AttributeSet attrs) { 22 | this(context, attrs, 0); 23 | } 24 | 25 | public MarqueeTextView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) { 26 | super(context, attrs, defStyleAttr); 27 | setSelected(true); 28 | setSingleLine(true); 29 | setMarqueeRepeatLimit(-1); 30 | setEllipsize(TextUtils.TruncateAt.MARQUEE); 31 | } 32 | 33 | @Override 34 | public boolean isFocused() { 35 | return true; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/AdBlocker.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import android.webkit.WebResourceResponse; 4 | 5 | import java.io.ByteArrayInputStream; 6 | import java.util.ArrayList; 7 | import java.util.List; 8 | 9 | public class AdBlocker { 10 | private static final List AD_HOSTS = new ArrayList<>(); 11 | 12 | public static void clear() { 13 | AD_HOSTS.clear(); 14 | } 15 | 16 | public static boolean isEmpty() { 17 | return AD_HOSTS.isEmpty(); 18 | } 19 | 20 | public static void addAdHost(String host) { 21 | AD_HOSTS.add(host); 22 | } 23 | public static boolean hasHost(String host) { 24 | return AD_HOSTS.contains(host); 25 | } 26 | public static boolean isAd(String url) { 27 | url = url.toLowerCase(); 28 | for (String adHost : AD_HOSTS) { 29 | if (url.contains(adHost)) { 30 | return true; 31 | } 32 | } 33 | return false; 34 | } 35 | 36 | public static WebResourceResponse createEmptyResource() { 37 | return new WebResourceResponse("text/plain", "utf-8", new ByteArrayInputStream("".getBytes())); 38 | } 39 | 40 | } 41 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/CollUtil.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import java.util.List; 4 | 5 | public class CollUtil { 6 | 7 | public static int findIndex(List list, Integer str) { 8 | int index = -1; 9 | if (list == null || list.isEmpty() || str == null) { 10 | return index; 11 | } 12 | 13 | for (int i = 0; i < list.size(); i++) { 14 | if (str.equals(list.get(i))) { 15 | index = i; 16 | break; 17 | } 18 | } 19 | return index; 20 | } 21 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/FastClickCheckUtil.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import android.os.Handler; 4 | import android.view.View; 5 | 6 | /** 7 | * @author pj567 8 | * @date :2020/12/22 9 | * @description: 10 | */ 11 | public class FastClickCheckUtil { 12 | /** 13 | * 相同视图点击必须间隔0.5s才能有效 14 | * 15 | * @param view 目标视图 16 | */ 17 | public static void check(View view) { 18 | check(view, 500); 19 | } 20 | 21 | /** 22 | * 设置间隔点击规则,配置间隔点击时长 23 | * 24 | * @param view 目标视图 25 | * @param mills 点击间隔时间(毫秒) 26 | */ 27 | public static void check(final View view, int mills) { 28 | view.setClickable(false); 29 | new Handler().postDelayed(new Runnable() { 30 | @Override 31 | public void run() { 32 | view.setClickable(true); 33 | } 34 | }, mills); 35 | } 36 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/HistoryHelper.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | public class HistoryHelper { 3 | 4 | private static Integer[] hisNumArray = {20, 40, 60, 80, 100}; 5 | 6 | public static final String getHomeRecName(int index){ 7 | Integer value = getHisNum(index); 8 | return value + "条"; 9 | } 10 | 11 | public static final int getHisNum(int index){ 12 | Integer value = null; 13 | if(index>=0 && index < hisNumArray.length){ 14 | value = hisNumArray[index]; 15 | }else{ 16 | value = hisNumArray[0]; 17 | } 18 | return value; 19 | } 20 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/Proxy.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import java.util.Map; 4 | import com.github.tvbox.osc.util.parser.SuperParse; 5 | public class Proxy { 6 | 7 | public static Object[] proxy(Map params) { 8 | try { 9 | String what = params.get("go"); 10 | assert what != null; 11 | if (what.equals("SuperParse")) { 12 | return SuperParse.loadHtml(params.get("flag"), params.get("url")); 13 | } 14 | 15 | } catch (Throwable ignored) { 16 | 17 | } 18 | return null; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/RegexUtils.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import java.util.HashMap; 4 | import java.util.Map; 5 | import java.util.regex.Pattern; 6 | 7 | public class RegexUtils { 8 | 9 | private static final Map patternCache = new HashMap<>(); 10 | public static Pattern getPattern(String regex) { 11 | Pattern pattern = patternCache.get(regex); 12 | if (pattern == null) { 13 | pattern = Pattern.compile(regex); 14 | patternCache.put(regex, pattern); 15 | } 16 | return pattern; 17 | } 18 | 19 | public static Pattern getPattern(String regex,int flag) { 20 | Pattern pattern = patternCache.get(regex); 21 | if (pattern == null) { 22 | pattern = Pattern.compile(regex,flag); 23 | patternCache.put(regex, pattern); 24 | } 25 | return pattern; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/SettingsUtil.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import com.orhanobut.hawk.Hawk; 4 | 5 | import java.io.Serializable; 6 | 7 | public class SettingsUtil { 8 | public static Object hkGet(String str, Serializable serializable) { 9 | try { 10 | return Hawk.get(str, serializable); 11 | } catch (Exception e) { 12 | Hawk.delete(str); 13 | return serializable; 14 | } 15 | } 16 | public static void hkPut(String str, Object obj) { 17 | try { 18 | Hawk.put(str, obj); 19 | } catch (Exception e) { 20 | e.printStackTrace(); 21 | } 22 | } 23 | public static void hkDel(String str) { 24 | try { 25 | Hawk.delete(str); 26 | } catch (Exception e) { 27 | e.printStackTrace(); 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/ToastHelper.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import android.content.Context; 4 | import android.widget.Toast; 5 | import android.os.Looper; 6 | 7 | public class ToastHelper { 8 | 9 | public static void showToast(Context context, String text) { 10 | new Thread(new Runnable() { 11 | public void run() { 12 | Looper.prepare(); 13 | Toast.makeText(context, text, Toast.LENGTH_SHORT).show(); 14 | Looper.loop(); 15 | } 16 | }).start(); 17 | } 18 | 19 | public static void debugToast(Context context, String text) { 20 | if (HawkConfig.isDebug()) { 21 | showToast(context, text); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/UA.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util; 2 | 3 | import com.github.tvbox.osc.base.App; 4 | 5 | import java.io.DataInputStream; 6 | import java.io.FileNotFoundException; 7 | import java.io.IOException; 8 | import java.io.InputStream; 9 | import java.util.Random; 10 | 11 | public class UA { 12 | 13 | public static String random() { 14 | try { 15 | InputStream fis = App.getInstance().getAssets().open("ua.db"); 16 | DataInputStream dis = new DataInputStream(fis); 17 | int len = dis.readInt(); 18 | int random = new Random().nextInt(len); 19 | dis.skipBytes(random * 4); 20 | int offset = dis.readInt(); 21 | dis.skipBytes((len - 1 - random) * 4 + offset); 22 | String s = dis.readUTF(); 23 | return s; 24 | } catch (FileNotFoundException e) { 25 | e.printStackTrace(); 26 | } catch (IOException e) { 27 | e.printStackTrace(); 28 | } 29 | return "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.114 Safari/537.36"; 30 | } 31 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/js/UTF8BOMFighter.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util.js; 2 | 3 | public class UTF8BOMFighter { 4 | private static final byte[] UTF8_BOM_BYTES = new byte[] { 5 | (byte) 0xEF, (byte) 0xBB, (byte) 0xBF 6 | }; 7 | 8 | private UTF8BOMFighter() {} 9 | 10 | static public String removeUTF8BOM(String xmlText) { 11 | byte[] bytes = xmlText.getBytes(); 12 | boolean containsBOM = bytes.length > 3 && bytes[0] == UTF8_BOM_BYTES[0] && bytes[1] == UTF8_BOM_BYTES[1] && bytes[2] == UTF8_BOM_BYTES[2]; 13 | if (containsBOM) { 14 | xmlText = new String(bytes, 3, bytes.length - 3); 15 | } 16 | return xmlText; 17 | } 18 | 19 | static byte[] removeUTF8BOM(byte[] bytes) { 20 | boolean containsBOM = bytes.length > 3 && bytes[0] == UTF8_BOM_BYTES[0] && bytes[1] == UTF8_BOM_BYTES[1] && bytes[2] == UTF8_BOM_BYTES[2]; 21 | if (containsBOM) { 22 | byte[] copy = new byte[bytes.length - 3]; 23 | System.arraycopy(bytes, 3, copy, 0, bytes.length - 3); 24 | return copy; 25 | } 26 | return bytes; 27 | } 28 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/js/local.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util.js; 2 | 3 | import androidx.annotation.Keep; 4 | import com.orhanobut.hawk.Hawk; 5 | import com.whl.quickjs.wrapper.Function; 6 | 7 | public class local {@Keep@Function 8 | public void delete(String str, String str2) { 9 | try { 10 | Hawk.delete("jsRuntime_" + str + "_" + str2); 11 | } catch (Exception e) { 12 | e.printStackTrace(); 13 | } 14 | }@Keep@Function 15 | public String get(String str, String str2) { 16 | try { 17 | return Hawk.get("jsRuntime_" + str + "_" + str2, ""); 18 | } catch (Exception e) { 19 | Hawk.delete(str); 20 | return str2; 21 | } 22 | }@Keep@Function 23 | public void set(String str, String str2, String str3) { 24 | try { 25 | Hawk.put("jsRuntime_" + str + "_" + str2, str3); 26 | } catch (Exception e) { 27 | e.printStackTrace(); 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/js/rsa/DataUtils.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util.js.rsa; 2 | 3 | import android.util.Base64; 4 | 5 | import java.nio.ByteBuffer; 6 | import java.nio.charset.StandardCharsets; 7 | 8 | /** 9 | * 数据工具类 10 | */ 11 | public class DataUtils { 12 | 13 | /** 14 | * 将 Base64 字符串 解码成 字节数组 15 | */ 16 | public static byte[] base64Decode(String data) { 17 | return Base64.decode(data.getBytes(), Base64.NO_WRAP); 18 | } 19 | 20 | /** 21 | * 将 字节数组 转换成 Base64 编码 22 | */ 23 | public static String base64Encode(byte[] data) { 24 | return Base64.encodeToString(data, Base64.NO_WRAP); 25 | } 26 | 27 | /** 28 | * 将字节数组转换成 int 类型 29 | */ 30 | public static int byte2Int(byte[] bytes) { 31 | ByteBuffer buffer = ByteBuffer.wrap(bytes); 32 | return buffer.getInt(); 33 | } 34 | 35 | /** 36 | * 将 int 转换成 byte 数组 37 | */ 38 | public static byte[] int2byte(int data) { 39 | ByteBuffer buffer = ByteBuffer.allocate(4); 40 | buffer.putInt(data); 41 | return buffer.array(); 42 | } 43 | } -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/urlhttp/RealResponse.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util.urlhttp; 2 | 3 | import java.io.InputStream; 4 | 5 | /** 6 | * Created by fighting on 2017/4/24. 7 | */ 8 | 9 | public class RealResponse { 10 | public InputStream inputStream; 11 | public InputStream errorStream; 12 | public int code; 13 | public long contentLength; 14 | public Exception exception; 15 | } 16 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/util/urlhttp/internal/BrotliSource.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.util.urlhttp.internal; 2 | 3 | import org.brotli.dec.BrotliInputStream; 4 | 5 | import java.io.IOException; 6 | 7 | import okio.BufferedSource; 8 | import okio.Okio; 9 | import okio.Source; 10 | 11 | public final class BrotliSource { 12 | public static Source create(BufferedSource source) throws IOException { 13 | BrotliInputStream brotliInputStream = new BrotliInputStream(source.inputStream()); 14 | return Okio.source(brotliInputStream); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/widget/OnItemClickListener.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.widget; 2 | 3 | import android.view.View; 4 | 5 | import com.owen.tvrecyclerview.widget.TvRecyclerView; 6 | 7 | public interface OnItemClickListener extends TvRecyclerView.OnItemListener { 8 | @Override 9 | void onItemClick(TvRecyclerView tvRecyclerView, View view, int i); 10 | 11 | @Override 12 | default void onItemPreSelected(TvRecyclerView tvRecyclerView, View view, int i) { 13 | } 14 | 15 | @Override 16 | default void onItemSelected(TvRecyclerView tvRecyclerView, View view, int i) { 17 | } 18 | 19 | ; 20 | } 21 | -------------------------------------------------------------------------------- /app/src/main/java/com/github/tvbox/osc/widget/OnItemSelectedListener.java: -------------------------------------------------------------------------------- 1 | package com.github.tvbox.osc.widget; 2 | 3 | import android.view.View; 4 | 5 | import com.owen.tvrecyclerview.widget.TvRecyclerView; 6 | 7 | public interface OnItemSelectedListener extends TvRecyclerView.OnItemListener { 8 | @Override 9 | default void onItemClick(TvRecyclerView tvRecyclerView, View view, int i) { 10 | } 11 | 12 | @Override 13 | default void onItemPreSelected(TvRecyclerView tvRecyclerView, View view, int i) { 14 | } 15 | 16 | @Override 17 | void onItemSelected(TvRecyclerView tvRecyclerView, View view, int i); 18 | } 19 | -------------------------------------------------------------------------------- /app/src/main/java/com/google/androidx/media3/exoplayer/extractor/ts/TsBinarySearchSeeker.java: -------------------------------------------------------------------------------- 1 | package com.google.androidx.media3.exoplayer.extractor.ts; 2 | 3 | import androidx.media3.extractor.ExtractorInput; 4 | import androidx.media3.extractor.PositionHolder; 5 | import androidx.media3.extractor.SeekMap; 6 | 7 | public class TsBinarySearchSeeker { 8 | public TsBinarySearchSeeker(Object pcrTimestampAdjuster, long durationUs, long inputLength, int pcrPid, int timestampSearchBytes) { 9 | } 10 | 11 | public void setSeekTargetUs(long timeUs) { 12 | } 13 | 14 | public boolean isSeeking() { 15 | return false; 16 | } 17 | 18 | public int handlePendingSeek(ExtractorInput input, PositionHolder seekPosition) { 19 | return 0; 20 | } 21 | 22 | public SeekMap getSeekMap() { 23 | return null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/src/main/java/com/google/androidx/media3/exoplayer/extractor/ts/TsDurationReader.java: -------------------------------------------------------------------------------- 1 | package com.google.androidx.media3.exoplayer.extractor.ts; 2 | 3 | import androidx.media3.extractor.ExtractorInput; 4 | import androidx.media3.extractor.PositionHolder; 5 | 6 | public class TsDurationReader { 7 | public TsDurationReader(int timestampSearchBytes) { 8 | } 9 | 10 | public int readDuration(ExtractorInput input, PositionHolder seekPosition, int pcrPid) { 11 | return pcrPid; 12 | } 13 | 14 | public boolean isDurationReadFinished() { 15 | return false; 16 | } 17 | 18 | public long getDurationUs() { 19 | return 0; 20 | } 21 | 22 | public Object getPcrTimestampAdjuster() { 23 | return null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/ISurfaceTextureHolder.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Bilibili 3 | * Copyright (C) 2015 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player; 19 | 20 | import android.graphics.SurfaceTexture; 21 | 22 | public interface ISurfaceTextureHolder { 23 | void setSurfaceTexture(SurfaceTexture surfaceTexture); 24 | 25 | SurfaceTexture getSurfaceTexture(); 26 | 27 | void setSurfaceTextureHost(ISurfaceTextureHost surfaceTextureHost); 28 | } 29 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/ISurfaceTextureHost.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Bilibili 3 | * Copyright (C) 2015 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player; 19 | 20 | import android.graphics.SurfaceTexture; 21 | 22 | public interface ISurfaceTextureHost { 23 | void releaseSurfaceTexture(SurfaceTexture surfaceTexture); 24 | } 25 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/IjkLibLoader.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2013-2014 Bilibili 3 | * Copyright (C) 2013-2014 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player; 19 | 20 | public interface IjkLibLoader { 21 | void loadLibrary(String libName) throws UnsatisfiedLinkError, 22 | SecurityException; 23 | } 24 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/IjkTimedText.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2016 Zheng Yuan 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | package tv.danmaku.ijk.media.player; 18 | 19 | import android.graphics.Rect; 20 | 21 | public final class IjkTimedText { 22 | 23 | private Rect mTextBounds = null; 24 | private String mTextChars = null; 25 | 26 | public IjkTimedText(Rect bounds, String text) { 27 | mTextBounds = bounds; 28 | mTextChars = text; 29 | } 30 | 31 | public Rect getBounds() { 32 | return mTextBounds; 33 | } 34 | 35 | public String getText() { 36 | return mTextChars; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/MediaInfo.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2013-2014 Bilibili 3 | * Copyright (C) 2013-2014 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player; 19 | 20 | public class MediaInfo { 21 | public String mMediaPlayerName; 22 | 23 | public String mVideoDecoder; 24 | public String mVideoDecoderImpl; 25 | 26 | public String mAudioDecoder; 27 | public String mAudioDecoderImpl; 28 | 29 | public IjkMediaMeta mMeta; 30 | } 31 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/exceptions/IjkMediaException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2013-2014 Bilibili 3 | * Copyright (C) 2013-2014 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player.exceptions; 19 | 20 | public class IjkMediaException extends Exception { 21 | private static final long serialVersionUID = 7234796519009099506L; 22 | } 23 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/ffmpeg/FFmpegApi.java: -------------------------------------------------------------------------------- 1 | package tv.danmaku.ijk.media.player.ffmpeg; 2 | 3 | public class FFmpegApi { 4 | public static native String av_base64_encode(byte in[]); 5 | } 6 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/misc/IAndroidIO.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2016 Bilibili 3 | * Copyright (C) 2016 Raymond Zheng 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player.misc; 19 | 20 | import java.io.IOException; 21 | 22 | @SuppressWarnings("RedundantThrows") 23 | public interface IAndroidIO { 24 | int open(String url) throws IOException; 25 | int read(byte[] buffer, int size) throws IOException; 26 | long seek(long offset, int whence) throws IOException; 27 | int close() throws IOException; 28 | } 29 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/misc/IMediaDataSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Bilibili 3 | * Copyright (C) 2015 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player.misc; 19 | 20 | import java.io.IOException; 21 | 22 | @SuppressWarnings("RedundantThrows") 23 | public interface IMediaDataSource { 24 | int readAt(long position, byte[] buffer, int offset, int size) throws IOException; 25 | 26 | long getSize() throws IOException; 27 | 28 | void close() throws IOException; 29 | } 30 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/misc/IMediaFormat.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Bilibili 3 | * Copyright (C) 2015 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player.misc; 19 | 20 | public interface IMediaFormat { 21 | // Common keys 22 | String KEY_MIME = "mime"; 23 | 24 | // Video Keys 25 | String KEY_WIDTH = "width"; 26 | String KEY_HEIGHT = "height"; 27 | 28 | String getString(String name); 29 | 30 | int getInteger(String name); 31 | } 32 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/misc/ITrackInfo.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 Bilibili 3 | * Copyright (C) 2015 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | 18 | package tv.danmaku.ijk.media.player.misc; 19 | 20 | public interface ITrackInfo { 21 | int MEDIA_TRACK_TYPE_AUDIO = 2; 22 | int MEDIA_TRACK_TYPE_METADATA = 5; 23 | int MEDIA_TRACK_TYPE_SUBTITLE = 4; 24 | int MEDIA_TRACK_TYPE_TIMEDTEXT = 3; 25 | int MEDIA_TRACK_TYPE_UNKNOWN = 0; 26 | int MEDIA_TRACK_TYPE_VIDEO = 1; 27 | 28 | IMediaFormat getFormat(); 29 | 30 | String getLanguage(); 31 | 32 | int getTrackType(); 33 | 34 | String getInfoInline(); 35 | } 36 | -------------------------------------------------------------------------------- /app/src/main/java/tv/danmaku/ijk/media/player/pragma/Pragma.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2013 Bilibili 3 | * Copyright (C) 2013 Zhang Rui 4 | * 5 | * Licensed under the Apache License, Version 2.0 (the "License"); 6 | * you may not use this file except in compliance with the License. 7 | * You may obtain a copy of the License at 8 | * 9 | * http://www.apache.org/licenses/LICENSE-2.0 10 | * 11 | * Unless required by applicable law or agreed to in writing, software 12 | * distributed under the License is distributed on an "AS IS" BASIS, 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | * See the License for the specific language governing permissions and 15 | * limitations under the License. 16 | */ 17 | package tv.danmaku.ijk.media.player.pragma; 18 | 19 | /*- 20 | * configurated by app project 21 | */ 22 | public class Pragma { 23 | public static final boolean ENABLE_VERBOSE = true; 24 | } 25 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/aliplayer/AliyunMediaPlayerFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.aliplayer; 2 | 3 | import android.content.Context; 4 | 5 | import xyz.doikki.videoplayer.player.PlayerFactory; 6 | 7 | public class AliyunMediaPlayerFactory extends PlayerFactory { 8 | 9 | public static AliyunMediaPlayerFactory create() { 10 | return new AliyunMediaPlayerFactory(); 11 | } 12 | 13 | @Override 14 | public AliMediaPlayer createPlayer(Context context) { 15 | return new AliMediaPlayer(context); 16 | } 17 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/controller/IGestureComponent.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.controller; 2 | 3 | public interface IGestureComponent extends IControlComponent { 4 | /** 5 | * 开始滑动 6 | */ 7 | void onStartSlide(); 8 | 9 | /** 10 | * 结束滑动 11 | */ 12 | void onStopSlide(); 13 | 14 | /** 15 | * 滑动调整进度 16 | * @param slidePosition 滑动进度 17 | * @param currentPosition 当前播放进度 18 | * @param duration 视频总长度 19 | */ 20 | void onPositionChange(int slidePosition, int currentPosition, int duration); 21 | 22 | /** 23 | * 滑动调整亮度 24 | * @param percent 亮度百分比 25 | */ 26 | void onBrightnessChange(int percent); 27 | 28 | /** 29 | * 滑动调整音量 30 | * @param percent 音量百分比 31 | */ 32 | void onVolumeChange(int percent); 33 | } 34 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/controller/IVideoController.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.controller; 2 | 3 | public interface IVideoController { 4 | 5 | /** 6 | * 开始控制视图自动隐藏倒计时 7 | */ 8 | void startFadeOut(); 9 | 10 | /** 11 | * 取消控制视图自动隐藏倒计时 12 | */ 13 | void stopFadeOut(); 14 | 15 | /** 16 | * 控制视图是否处于显示状态 17 | */ 18 | boolean isShowing(); 19 | 20 | /** 21 | * 设置锁定状态 22 | * @param locked 是否锁定 23 | */ 24 | void setLocked(boolean locked); 25 | 26 | /** 27 | * 是否处于锁定状态 28 | */ 29 | boolean isLocked(); 30 | 31 | /** 32 | * 开始刷新进度 33 | */ 34 | void startProgress(); 35 | 36 | /** 37 | * 停止刷新进度 38 | */ 39 | void stopProgress(); 40 | 41 | /** 42 | * 显示控制视图 43 | */ 44 | void hide(); 45 | 46 | /** 47 | * 隐藏控制视图 48 | */ 49 | void show(); 50 | 51 | /** 52 | * 是否需要适配刘海 53 | */ 54 | boolean hasCutout(); 55 | 56 | /** 57 | * 获取刘海的高度 58 | */ 59 | int getCutoutHeight(); 60 | } 61 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/controller/MediaPlayerControl.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.controller; 2 | 3 | import android.graphics.Bitmap; 4 | 5 | public interface MediaPlayerControl { 6 | 7 | void start(); 8 | 9 | void pause(); 10 | 11 | long getDuration(); 12 | 13 | long getCurrentPosition(); 14 | 15 | void seekTo(long pos); 16 | 17 | boolean isPlaying(); 18 | 19 | int getBufferedPercentage(); 20 | 21 | void startFullScreen(); 22 | 23 | void stopFullScreen(); 24 | 25 | boolean isFullScreen(); 26 | 27 | void setMute(boolean isMute); 28 | 29 | boolean isMute(); 30 | 31 | void setScreenScaleType(int screenScaleType); 32 | 33 | void setSpeed(float speed); 34 | 35 | float getSpeed(); 36 | 37 | long getTcpSpeed(); 38 | 39 | void replay(boolean resetPosition); 40 | 41 | void setMirrorRotation(boolean enable); 42 | 43 | Bitmap doScreenShot(); 44 | 45 | int[] getVideoSize(); 46 | 47 | void setRotation(float rotation); 48 | 49 | void startTinyScreen(); 50 | 51 | void stopTinyScreen(); 52 | 53 | boolean isTinyScreen(); 54 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/controller/OrientationHelper.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.controller; 2 | 3 | import android.content.Context; 4 | import android.view.OrientationEventListener; 5 | 6 | /** 7 | * 设备方向监听 8 | */ 9 | public class OrientationHelper extends OrientationEventListener { 10 | 11 | private long mLastTime; 12 | 13 | private OnOrientationChangeListener mOnOrientationChangeListener; 14 | 15 | public OrientationHelper(Context context) { 16 | super(context); 17 | } 18 | 19 | @Override 20 | public void onOrientationChanged(int orientation) { 21 | long currentTime = System.currentTimeMillis(); 22 | if (currentTime - mLastTime < 300) return;//300毫秒检测一次 23 | if (mOnOrientationChangeListener != null) { 24 | mOnOrientationChangeListener.onOrientationChanged(orientation); 25 | } 26 | mLastTime = currentTime; 27 | } 28 | 29 | 30 | public interface OnOrientationChangeListener { 31 | void onOrientationChanged(int orientation); 32 | } 33 | 34 | public void setOnOrientationChangeListener(OnOrientationChangeListener onOrientationChangeListener) { 35 | mOnOrientationChangeListener = onOrientationChangeListener; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/exo/ExoMediaPlayerFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.exo; 2 | 3 | import android.content.Context; 4 | 5 | import xyz.doikki.videoplayer.player.PlayerFactory; 6 | 7 | public class ExoMediaPlayerFactory extends PlayerFactory { 8 | 9 | public static ExoMediaPlayerFactory create() { 10 | return new ExoMediaPlayerFactory(); 11 | } 12 | 13 | @Override 14 | public ExoMediaPlayer createPlayer(Context context) { 15 | return new ExoMediaPlayer(context); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/ijk/IjkPlayerFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.ijk; 2 | 3 | import android.content.Context; 4 | 5 | import xyz.doikki.videoplayer.player.PlayerFactory; 6 | 7 | public class IjkPlayerFactory extends PlayerFactory { 8 | 9 | public static IjkPlayerFactory create() { 10 | return new IjkPlayerFactory(); 11 | } 12 | 13 | @Override 14 | public IjkPlayer createPlayer(Context context) { 15 | return new IjkPlayer(context); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/player/AndroidMediaPlayerFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.player; 2 | 3 | import android.content.Context; 4 | 5 | /** 6 | * 创建{@link AndroidMediaPlayer}的工厂类,不推荐,系统的MediaPlayer兼容性较差,建议使用IjkPlayer或者ExoPlayer 7 | */ 8 | public class AndroidMediaPlayerFactory extends PlayerFactory { 9 | 10 | public static AndroidMediaPlayerFactory create() { 11 | return new AndroidMediaPlayerFactory(); 12 | } 13 | 14 | @Override 15 | public AndroidMediaPlayer createPlayer(Context context) { 16 | return new AndroidMediaPlayer(context); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/player/PlayerFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.player; 2 | 3 | import android.content.Context; 4 | 5 | /** 6 | * 此接口使用方法: 7 | * 1.继承{@link AbstractPlayer}扩展自己的播放器。 8 | * 2.继承此接口并实现{@link #createPlayer(Context)},返回步骤1中的播放器。 9 | * 可参照{@link AndroidMediaPlayer}和{@link AndroidMediaPlayerFactory}的实现。 10 | */ 11 | public abstract class PlayerFactory

{ 12 | 13 | public abstract P createPlayer(Context context); 14 | } 15 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/player/ProgressManager.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.player; 2 | 3 | /** 4 | * 播放进度管理器,继承此接口实现自己的进度管理器。 5 | */ 6 | public abstract class ProgressManager { 7 | 8 | /** 9 | * 此方法用于实现保存进度的逻辑 10 | * @param url 播放地址 11 | * @param progress 播放进度 12 | */ 13 | public abstract void saveProgress(String url, long progress); 14 | 15 | /** 16 | * 此方法用于实现获取保存的进度的逻辑 17 | * @param url 播放地址 18 | * @return 保存的播放进度 19 | */ 20 | public abstract long getSavedProgress(String url); 21 | 22 | } 23 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/player/VideoView.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.player; 2 | 3 | import android.content.Context; 4 | import android.util.AttributeSet; 5 | 6 | import androidx.annotation.NonNull; 7 | import androidx.annotation.Nullable; 8 | 9 | 10 | /** 11 | * 可播放在线和本地url 12 | * Created by Doikki on 2022/7/18. 13 | */ 14 | public class VideoView extends BaseVideoView { 15 | public VideoView(@NonNull Context context) { 16 | super(context); 17 | } 18 | 19 | public VideoView(@NonNull Context context, @Nullable AttributeSet attrs) { 20 | super(context, attrs); 21 | } 22 | 23 | public VideoView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) { 24 | super(context, attrs, defStyleAttr); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/render/IRenderView.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.render; 2 | 3 | import android.graphics.Bitmap; 4 | import android.view.View; 5 | 6 | import androidx.annotation.NonNull; 7 | 8 | import xyz.doikki.videoplayer.player.AbstractPlayer; 9 | 10 | public interface IRenderView { 11 | 12 | /** 13 | * 关联AbstractPlayer 14 | */ 15 | void attachToPlayer(@NonNull AbstractPlayer player); 16 | 17 | /** 18 | * 设置视频宽高 19 | * @param videoWidth 宽 20 | * @param videoHeight 高 21 | */ 22 | void setVideoSize(int videoWidth, int videoHeight); 23 | 24 | /** 25 | * 设置视频旋转角度 26 | * @param degree 角度值 27 | */ 28 | void setVideoRotation(int degree); 29 | 30 | /** 31 | * 设置screen scale type 32 | * @param scaleType 类型 33 | */ 34 | void setScaleType(int scaleType); 35 | 36 | /** 37 | * 获取真实的RenderView 38 | */ 39 | View getView(); 40 | 41 | /** 42 | * 截图 43 | */ 44 | Bitmap doScreenShot(); 45 | 46 | /** 47 | * 释放资源 48 | */ 49 | void release(); 50 | 51 | } -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/render/RenderViewFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.render; 2 | 3 | import android.content.Context; 4 | 5 | /** 6 | * 此接口用于扩展自己的渲染View。使用方法如下: 7 | * 1.继承IRenderView实现自己的渲染View。 8 | * 2.重写createRenderView返回步骤1的渲染View。 9 | * 可参考{@link TextureRenderView}和{@link TextureRenderViewFactory}的实现。 10 | */ 11 | public abstract class RenderViewFactory { 12 | 13 | public abstract IRenderView createRenderView(Context context); 14 | 15 | } 16 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/render/TextureRenderViewFactory.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.render; 2 | 3 | import android.content.Context; 4 | 5 | public class TextureRenderViewFactory extends RenderViewFactory { 6 | 7 | public static TextureRenderViewFactory create() { 8 | return new TextureRenderViewFactory(); 9 | } 10 | 11 | @Override 12 | public IRenderView createRenderView(Context context) { 13 | return new TextureRenderView(context); 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /app/src/main/java/xyz/doikki/videoplayer/util/L.java: -------------------------------------------------------------------------------- 1 | package xyz.doikki.videoplayer.util; 2 | 3 | import android.util.Log; 4 | 5 | import xyz.doikki.videoplayer.player.VideoViewManager; 6 | 7 | /** 8 | * 日志类 9 | * Created by Doikki on 2017/6/5. 10 | */ 11 | 12 | public final class L { 13 | 14 | private L() { 15 | } 16 | 17 | private static final String TAG = "DKPlayer"; 18 | 19 | private static boolean isDebug = VideoViewManager.getConfig().mIsEnableLog; 20 | 21 | 22 | public static void d(String msg) { 23 | if (isDebug) { 24 | Log.d(TAG, msg); 25 | } 26 | } 27 | 28 | public static void e(String msg) { 29 | if (isDebug) { 30 | Log.e(TAG, msg); 31 | } 32 | } 33 | 34 | public static void i(String msg) { 35 | if (isDebug) { 36 | Log.i(TAG, msg); 37 | } 38 | } 39 | 40 | public static void w(String msg) { 41 | if (isDebug) { 42 | Log.w(TAG, msg); 43 | } 44 | } 45 | 46 | public static void setDebug(boolean isDebug) { 47 | L.isDebug = isDebug; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libijkffmpeg.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libijkffmpeg.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libijkplayer.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libijkplayer.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libijksdl.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libijksdl.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libp2p.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libp2p.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libxl_stat.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libxl_stat.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/arm64-v8a/libxl_thunder_sdk.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/arm64-v8a/libxl_thunder_sdk.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libijkffmpeg.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libijkffmpeg.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libijkplayer.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libijkplayer.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libijksdl.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libijksdl.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libp2p.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libp2p.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libxl_stat.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libxl_stat.so -------------------------------------------------------------------------------- /app/src/main/jniLibs/armeabi-v7a/libxl_thunder_sdk.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/jniLibs/armeabi-v7a/libxl_thunder_sdk.so -------------------------------------------------------------------------------- /app/src/main/res/color/font_home_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/anim_loading.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/app_banner.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/app_bg.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/app_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/app_icon.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/bg_live.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/box_controller_bottom_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/box_controller_top_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_detail_all.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_detail_collect.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_detail_link.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_detail_preview.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_dialog_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_dialog_vod.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_home_select.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/button_home_sort_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/channel_num_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/flow_tag_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/hm_fav.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/hm_push.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/hm_search.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/htov.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/htov.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_clock.xml: -------------------------------------------------------------------------------- 1 | 4 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_notify_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_notify_next.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_notify_pause.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_notify_pause.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_notify_play.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_notify_play.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_notify_pre.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_notify_pre.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_pause.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_pause.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_play_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_play_next.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/ic_play_pre.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/ic_play_pre.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_circle_node.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_circle_plus.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_clear.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_delete.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_drive.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_error.xml: -------------------------------------------------------------------------------- 1 | 6 | 9 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_file.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_film.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_filter.xml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_folder.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_home.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/icon_loading.png -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_lock.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_sdcard.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_sort.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_trash_solid.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/icon_unlock.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/img_loading_placeholder.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/input_dialog_api_input.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/input_search.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/item_bg_selector_left.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 9 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/item_bg_selector_right.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 9 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/item_right_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_ffwd.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_pause.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_play.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_progress_horizontal.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_progress_vertical.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_rewind.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/play_skip.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/scrollviewleft.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/scrollviewright.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/selector_checkbox.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/set_hm.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/set_play.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_dialog_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_dialog_bg_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_dialog_filter_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_live_bg_bottom.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_live_channel_num.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_live_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_live_select.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_player_control_vod_seek.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_player_control_vod_seek_thumb.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_player_control_vod_seek_thumb_normal.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_player_control_vod_seek_thumb_press.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_player_tap.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_search_checkall.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_search_clearall.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_setting_model_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_setting_sort_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_source_flag_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_source_flag_line.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_source_series_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_speed_hint.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_thumb_bottom_name.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_thumb_lang.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_thumb_note.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_thumb_year.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_delete.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_focus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_home.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_pause.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_pause_r.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 10 | 11 | 14 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/shape_user_search.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/subtitle_circle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_aspect.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_audio.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_back.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_ffwd.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_next.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_pause.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_play.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_prev.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_replay.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_subtitle.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/v_type.xml: -------------------------------------------------------------------------------- 1 | 7 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/vod_ffwd.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/vod_play.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/vod_skip.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/vtoh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/drawable/vtoh.png -------------------------------------------------------------------------------- /app/src/main/res/font/advent_pro_extralight.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/app/src/main/res/font/advent_pro_extralight.ttf -------------------------------------------------------------------------------- /app/src/main/res/layout-v21/loadsir_loading_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_setting.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 17 | 18 | 23 | 24 | 25 | 29 | -------------------------------------------------------------------------------- /app/src/main/res/layout/dialog_about.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 22 | 23 | -------------------------------------------------------------------------------- /app/src/main/res/layout/dialog_desc.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 13 | 14 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /app/src/main/res/layout/dialog_grid_filter.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/layout/fragment_grid.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 23 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_button.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_dialog_checkbox_search.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 11 | 12 | 26 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_dialog_select.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_fast_search_site.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_grid_filter_value.xml: -------------------------------------------------------------------------------- 1 | 2 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_keyboard.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_live_channel_group.xml: -------------------------------------------------------------------------------- 1 | 2 | 11 | 12 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_live_setting.xml: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 27 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_live_setting_group.xml: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 28 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_play_parse.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_quick_search_lite.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 18 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_search_lite.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 18 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_search_word_hot.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_search_word_split.xml: -------------------------------------------------------------------------------- 1 | 2 | 15 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_series.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/layout/item_setting_menu.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 19 | -------------------------------------------------------------------------------- /app/src/main/res/layout/layout_keyborad.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/layout/loadsir_empty_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 12 | 13 | 17 | 18 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/res/layout/loadsir_loading_layout.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 13 | -------------------------------------------------------------------------------- /app/src/main/res/raw/ui.css: -------------------------------------------------------------------------------- 1 | body, 2 | html { 3 | height: 100%; 4 | -webkit-tap-highlight-color: transparent; 5 | } 6 | body { 7 | font-family: system-ui, -apple-system, Helvetica Neue, sans-serif; 8 | } 9 | .page, 10 | body { 11 | background-color: var(--weui-BG-0); 12 | } 13 | .page { 14 | position: absolute; 15 | top: 0; 16 | right: 0; 17 | bottom: 0; 18 | left: 0; 19 | overflow-y: auto; 20 | -webkit-overflow-scrolling: touch; 21 | box-sizing: border-box; 22 | z-index: 1; 23 | } -------------------------------------------------------------------------------- /app/src/main/res/xml/exo_play_view.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/xml/file_paths.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 9 | 12 | 13 | 14 | 17 | 18 | 21 | -------------------------------------------------------------------------------- /app/src/main/res/xml/network_security_config.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /app/src/normal/java/com/github/catvod/crawler/pyLoader.java: -------------------------------------------------------------------------------- 1 | package com.github.catvod.crawler; 2 | 3 | import android.util.Log; 4 | import com.github.catvod.crawler.python.IPyLoader; 5 | 6 | import java.util.Map; 7 | 8 | public class pyLoader implements IPyLoader { 9 | 10 | @Override 11 | public void clear() { 12 | Log.i("PyLoader", "normal flavor: clear() 调用,但不支持 Python 功能。"); 13 | } 14 | 15 | @Override 16 | public void setConfig(String jsonStr) { 17 | Log.i("PyLoader", "normal flavor: setConfig() 调用,但不支持 Python 功能。"); 18 | } 19 | 20 | @Override 21 | public void setRecentPyKey(String pyApi) { 22 | Log.i("PyLoader", "normal flavor: setRecentPyKey() 调用,但不支持 Python 功能。"); 23 | } 24 | 25 | @Override 26 | public Spider getSpider(String key, String cls, String ext) { 27 | Log.i("PyLoader", "normal flavor: getSpider() 调用,但不支持 Python 功能。"); 28 | return new SpiderNull(); 29 | } 30 | 31 | @Override 32 | public Object[] proxyInvoke(Map params) { 33 | Log.i("PyLoader", "normal flavor: proxyInvoke(params) 调用,但不支持 Python 功能。"); 34 | return null; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx2048m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app"s APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true 20 | IsDebug=true -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Tue Sep 21 09:53:05 CST 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /pyramid/consumer-rules.pro: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /pyramid/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 22 | -------------------------------------------------------------------------------- /pyramid/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | -------------------------------------------------------------------------------- /pyramid/src/python/base/localProxy.py: -------------------------------------------------------------------------------- 1 | class Proxy: 2 | def getUrl(self, local): 3 | return 'http://127.0.0.1:9978' 4 | 5 | def getPort(self): 6 | return 9978 7 | -------------------------------------------------------------------------------- /pyramid/src/python/trigger.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | #!/usr/bin/python 3 | class Trigger(): # 元类 默认的元类 type 4 | @staticmethod 5 | def init(sp_obj,extend=""): 6 | sp_obj.init(extend) 7 | @staticmethod 8 | def homeContent(sp_obj,filter): 9 | return sp_obj.homeContent(filter) 10 | @staticmethod 11 | def homeVideoContent(sp_obj): 12 | return sp_obj.homeVideoContent() 13 | @staticmethod 14 | def categoryContent(sp_obj,tid,pg,filter,extend): 15 | return sp_obj.categoryContent(tid,pg,filter,extend) 16 | @staticmethod 17 | def detailContent(sp_obj,ids): 18 | return sp_obj.detailContent(ids) 19 | @staticmethod 20 | def searchContent(sp_obj,key,quick): 21 | return sp_obj.searchContent(key,quick) 22 | @staticmethod 23 | def playerContent(sp_obj,flag,id,vipFlags): 24 | return sp_obj.playerContent(flag,id,vipFlags) 25 | @staticmethod 26 | def liveContent(sp_obj,url): 27 | return sp_obj.liveContent(url) 28 | @staticmethod 29 | def isVideoFormat(sp_obj,url): 30 | return sp_obj.isVideoFormat(url) 31 | @staticmethod 32 | def manualVideoCheck(sp_obj): 33 | return sp_obj.manualVideoCheck() -------------------------------------------------------------------------------- /quickjs/build.gradle: -------------------------------------------------------------------------------- 1 | plugins { 2 | id 'com.android.library' 3 | } 4 | 5 | android { 6 | compileSdk 34 7 | 8 | defaultConfig { 9 | minSdk 21 10 | targetSdk 28 11 | } 12 | } 13 | 14 | dependencies { 15 | 16 | } 17 | -------------------------------------------------------------------------------- /quickjs/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/android/QuickJSLoader.java: -------------------------------------------------------------------------------- 1 | package com.whl.quickjs.android; 2 | 3 | public final class QuickJSLoader { 4 | public static void init() { 5 | init(Boolean.FALSE); 6 | } 7 | 8 | public static void init(Boolean bool) { 9 | try { 10 | System.loadLibrary("quickjs-android-wrapper"); 11 | if (bool.booleanValue()) { 12 | startRedirectingStdoutStderr("QuJs ==> "); 13 | } 14 | } catch (Throwable throwable) { 15 | 16 | } 17 | } 18 | 19 | public static native void startRedirectingStdoutStderr(String str); 20 | } 21 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/wrapper/BindingContext.java: -------------------------------------------------------------------------------- 1 | package com.whl.quickjs.wrapper; 2 | 3 | import java.lang.reflect.Method; 4 | import java.util.HashMap; 5 | import java.util.Map; 6 | 7 | public class BindingContext { 8 | 9 | protected Map functionMap; 10 | 11 | protected Method contextSetter; 12 | 13 | public BindingContext() { 14 | functionMap = new HashMap<>(); 15 | contextSetter = null; 16 | } 17 | 18 | public Map getFunctionMap() { 19 | return functionMap; 20 | } 21 | 22 | 23 | public Method getContextSetter() { 24 | return contextSetter; 25 | } 26 | 27 | public void setContextSetter(Method contextSetter) { 28 | this.contextSetter = contextSetter; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/wrapper/ContextSetter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2021-2023. caoccao.com Sam Cao 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | package com.whl.quickjs.wrapper; 18 | 19 | import java.lang.annotation.Documented; 20 | import java.lang.annotation.ElementType; 21 | import java.lang.annotation.Retention; 22 | import java.lang.annotation.RetentionPolicy; 23 | import java.lang.annotation.Target; 24 | 25 | /** 26 | * The interface QuickJSContext setter. 27 | * 28 | * @since 0.8.1 29 | */ 30 | @Documented 31 | @Target(ElementType.METHOD) 32 | @Retention(RetentionPolicy.RUNTIME) 33 | public @interface ContextSetter { 34 | } 35 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/wrapper/JSCallFunction.java: -------------------------------------------------------------------------------- 1 | package com.whl.quickjs.wrapper; 2 | 3 | public interface JSCallFunction { 4 | 5 | Object call(Object... args); 6 | 7 | } 8 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/wrapper/JSFunction.java: -------------------------------------------------------------------------------- 1 | package com.whl.quickjs.wrapper; 2 | 3 | public class JSFunction extends JSObject { 4 | 5 | private final long objPointer; 6 | 7 | public JSFunction(QuickJSContext context, long objPointer, long pointer) { 8 | super(context, pointer); 9 | this.objPointer = objPointer; 10 | } 11 | 12 | public Object call(Object... args) { 13 | return getContext().call(this, objPointer, args); 14 | } 15 | 16 | } 17 | -------------------------------------------------------------------------------- /quickjs/src/main/java/com/whl/quickjs/wrapper/QuickJSException.java: -------------------------------------------------------------------------------- 1 | package com.whl.quickjs.wrapper; 2 | 3 | /** 4 | * Created by Harlon Wang on 2022/2/8. 5 | */ 6 | public class QuickJSException extends RuntimeException { 7 | 8 | private final boolean jsError; 9 | 10 | public QuickJSException(String message) { 11 | this(message, false); 12 | } 13 | 14 | public QuickJSException(String message, boolean jsError) { 15 | super(message); 16 | this.jsError = jsError; 17 | } 18 | 19 | public boolean isJSError() { 20 | return jsError; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /quickjs/src/main/jniLibs/arm64-v8a/libquickjs-android-wrapper.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/quickjs/src/main/jniLibs/arm64-v8a/libquickjs-android-wrapper.so -------------------------------------------------------------------------------- /quickjs/src/main/jniLibs/armeabi-v7a/libquickjs-android-wrapper.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/quickjs/src/main/jniLibs/armeabi-v7a/libquickjs-android-wrapper.so -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = "TVBox" 2 | include ':app' 3 | include ':quickjs' 4 | include ':pyramid' 5 | -------------------------------------------------------------------------------- /xwalk/crosswalk-apks-23.53.589.4-arm.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/xwalk/crosswalk-apks-23.53.589.4-arm.zip -------------------------------------------------------------------------------- /xwalk/crosswalk-apks-23.53.589.4-arm64.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/xwalk/crosswalk-apks-23.53.589.4-arm64.zip -------------------------------------------------------------------------------- /xwalk/crosswalk-apks-23.53.589.4-x86.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/xwalk/crosswalk-apks-23.53.589.4-x86.zip -------------------------------------------------------------------------------- /xwalk/crosswalk-apks-23.53.589.4-x86_64.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/takagen99/Box/117fa9593ba22b2e81c21b87303ec1981f830d89/xwalk/crosswalk-apks-23.53.589.4-x86_64.zip --------------------------------------------------------------------------------