@quicktvui/ai 1.0.6 → 1.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/rules/.clinerules +28 -4
- package/rules/.cursorrules +28 -4
- package/rules/.github/copilot-instructions.md +28 -4
- package/rules/.source/ESADPlayer/package.json +24 -0
- package/rules/.source/ESADPlayer/rollup.config.js +33 -0
- package/rules/.source/ESADPlayer/src/component/ESADPlayerViewComponent.ts +466 -0
- package/rules/.source/ESADPlayer/src/core/ESADType.ts +6 -0
- package/rules/.source/ESADPlayer/src/index.ts +18 -0
- package/rules/.source/ESADPlayer/src/index.vue +963 -0
- package/rules/.source/ESADPlayer/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESADPlayer/tsconfig.json +34 -0
- package/rules/.source/ESAudioPlayer/package.json +23 -0
- package/rules/.source/ESAudioPlayer/rollup.config.js +33 -0
- package/rules/.source/ESAudioPlayer/src/index.ts +10 -0
- package/rules/.source/ESAudioPlayer/src/index.vue +1441 -0
- package/rules/.source/ESAudioPlayer/src/module/ESAudioPlayer.ts +169 -0
- package/rules/.source/ESAudioPlayer/src/module/ESAudioPlayerModule.android.ts +134 -0
- package/rules/.source/ESAudioPlayer/src/module/ESAudioPlayerModule.harmony.ts +139 -0
- package/rules/.source/ESAudioPlayer/src/module/ESAudioPlayerModule.ts +44 -0
- package/rules/.source/ESAudioPlayer/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESAudioPlayer/src/utils/ESAudioPlayerDefinitionUtils.ts +36 -0
- package/rules/.source/ESAudioPlayer/tsconfig.json +34 -0
- package/rules/.source/ESAudioServicePlayer/package.json +23 -0
- package/rules/.source/ESAudioServicePlayer/rollup.config.js +33 -0
- package/rules/.source/ESAudioServicePlayer/src/index.ts +10 -0
- package/rules/.source/ESAudioServicePlayer/src/index.vue +1400 -0
- package/rules/.source/ESAudioServicePlayer/src/module/ESAudioServicePlayer.ts +189 -0
- package/rules/.source/ESAudioServicePlayer/src/module/ESAudioServicePlayerModule.android.ts +155 -0
- package/rules/.source/ESAudioServicePlayer/src/module/ESAudioServicePlayerModule.harmony.ts +163 -0
- package/rules/.source/ESAudioServicePlayer/src/module/ESAudioServicePlayerModule.ts +50 -0
- package/rules/.source/ESAudioServicePlayer/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESAudioServicePlayer/src/utils/ESAudioServicePlayerDefinitionUtils.ts +36 -0
- package/rules/.source/ESAudioServicePlayer/tsconfig.json +34 -0
- package/rules/.source/ESAxios/CHANGELOG.md +1072 -0
- package/rules/.source/ESAxios/LICENSE +7 -0
- package/rules/.source/ESAxios/MIGRATION_GUIDE.md +3 -0
- package/rules/.source/ESAxios/README.md +1673 -0
- package/rules/.source/ESAxios/index.d.cts +549 -0
- package/rules/.source/ESAxios/index.d.ts +766 -0
- package/rules/.source/ESAxios/index.js +43 -0
- package/rules/.source/ESAxios/lib/adapters/README.md +37 -0
- package/rules/.source/ESAxios/lib/adapters/adapters.js +80 -0
- package/rules/.source/ESAxios/lib/adapters/fetch.js +295 -0
- package/rules/.source/ESAxios/lib/axios.js +90 -0
- package/rules/.source/ESAxios/lib/cancel/CancelToken.js +135 -0
- package/rules/.source/ESAxios/lib/cancel/CanceledError.js +31 -0
- package/rules/.source/ESAxios/lib/cancel/isCancel.js +5 -0
- package/rules/.source/ESAxios/lib/core/Axios.js +292 -0
- package/rules/.source/ESAxios/lib/core/AxiosError.js +108 -0
- package/rules/.source/ESAxios/lib/core/AxiosHeaders.js +340 -0
- package/rules/.source/ESAxios/lib/core/InterceptorManager.js +71 -0
- package/rules/.source/ESAxios/lib/core/README.md +8 -0
- package/rules/.source/ESAxios/lib/core/buildFullPath.js +26 -0
- package/rules/.source/ESAxios/lib/core/dispatchRequest.js +81 -0
- package/rules/.source/ESAxios/lib/core/mergeConfig.js +112 -0
- package/rules/.source/ESAxios/lib/core/settle.js +31 -0
- package/rules/.source/ESAxios/lib/core/transformData.js +33 -0
- package/rules/.source/ESAxios/lib/defaults/index.js +182 -0
- package/rules/.source/ESAxios/lib/defaults/transitional.js +7 -0
- package/rules/.source/ESAxios/lib/env/README.md +3 -0
- package/rules/.source/ESAxios/lib/env/classes/FormData.js +2 -0
- package/rules/.source/ESAxios/lib/env/data.js +1 -0
- package/rules/.source/ESAxios/lib/helpers/AxiosTransformStream.js +160 -0
- package/rules/.source/ESAxios/lib/helpers/AxiosURLSearchParams.js +65 -0
- package/rules/.source/ESAxios/lib/helpers/HttpStatusCode.js +71 -0
- package/rules/.source/ESAxios/lib/helpers/README.md +7 -0
- package/rules/.source/ESAxios/lib/helpers/ZlibHeaderTransformStream.js +29 -0
- package/rules/.source/ESAxios/lib/helpers/bind.js +7 -0
- package/rules/.source/ESAxios/lib/helpers/buildURL.js +69 -0
- package/rules/.source/ESAxios/lib/helpers/callbackify.js +18 -0
- package/rules/.source/ESAxios/lib/helpers/combineURLs.js +15 -0
- package/rules/.source/ESAxios/lib/helpers/composeSignals.js +61 -0
- package/rules/.source/ESAxios/lib/helpers/cookies.js +40 -0
- package/rules/.source/ESAxios/lib/helpers/deprecatedMethod.js +31 -0
- package/rules/.source/ESAxios/lib/helpers/formDataToJSON.js +95 -0
- package/rules/.source/ESAxios/lib/helpers/formDataToStream.js +122 -0
- package/rules/.source/ESAxios/lib/helpers/fromDataURI.js +62 -0
- package/rules/.source/ESAxios/lib/helpers/isAbsoluteURL.js +15 -0
- package/rules/.source/ESAxios/lib/helpers/isAxiosError.js +14 -0
- package/rules/.source/ESAxios/lib/helpers/isURLSameOrigin.js +17 -0
- package/rules/.source/ESAxios/lib/helpers/null.js +2 -0
- package/rules/.source/ESAxios/lib/helpers/parseHeaders.js +69 -0
- package/rules/.source/ESAxios/lib/helpers/parseProtocol.js +6 -0
- package/rules/.source/ESAxios/lib/helpers/progressEventReducer.js +51 -0
- package/rules/.source/ESAxios/lib/helpers/readBlob.js +15 -0
- package/rules/.source/ESAxios/lib/helpers/resolveConfig.js +83 -0
- package/rules/.source/ESAxios/lib/helpers/speedometer.js +55 -0
- package/rules/.source/ESAxios/lib/helpers/spread.js +28 -0
- package/rules/.source/ESAxios/lib/helpers/throttle.js +44 -0
- package/rules/.source/ESAxios/lib/helpers/toFormData.js +241 -0
- package/rules/.source/ESAxios/lib/helpers/toURLEncodedForm.js +25 -0
- package/rules/.source/ESAxios/lib/helpers/trackStream.js +89 -0
- package/rules/.source/ESAxios/lib/helpers/validator.js +120 -0
- package/rules/.source/ESAxios/lib/platform/browser/classes/Blob.js +3 -0
- package/rules/.source/ESAxios/lib/platform/browser/classes/FormData.js +3 -0
- package/rules/.source/ESAxios/lib/platform/browser/classes/URLSearchParams.js +6 -0
- package/rules/.source/ESAxios/lib/platform/browser/index.js +13 -0
- package/rules/.source/ESAxios/lib/platform/common/classes/FormData.js +142 -0
- package/rules/.source/ESAxios/lib/platform/common/index.js +7 -0
- package/rules/.source/ESAxios/lib/platform/common/utils.js +54 -0
- package/rules/.source/ESAxios/lib/platform/index.js +7 -0
- package/rules/.source/ESAxios/lib/platform/node/classes/FormData.js +3 -0
- package/rules/.source/ESAxios/lib/platform/node/classes/URLSearchParams.js +4 -0
- package/rules/.source/ESAxios/lib/platform/node/index.js +12 -0
- package/rules/.source/ESAxios/lib/utils.js +820 -0
- package/rules/.source/ESCore/CHANGELOG.md +7 -0
- package/rules/.source/ESCore/package.json +24 -0
- package/rules/.source/ESCore/rollup.config.js +28 -0
- package/rules/.source/ESCore/src/actionbar/ESActionBar.ts +48 -0
- package/rules/.source/ESCore/src/actionbar/ESActionBarModule.android.ts +29 -0
- package/rules/.source/ESCore/src/actionbar/ESActionBarModule.harmony.ts +31 -0
- package/rules/.source/ESCore/src/actionbar/ESActionBarModule.ts +9 -0
- package/rules/.source/ESCore/src/actionbar/index.ts +2 -0
- package/rules/.source/ESCore/src/app/ESAppInfo.ts +12 -0
- package/rules/.source/ESCore/src/app/ESAppInfoList.ts +9 -0
- package/rules/.source/ESCore/src/app/ESAppList.ts +64 -0
- package/rules/.source/ESCore/src/app/ESAppListModule.android.ts +55 -0
- package/rules/.source/ESCore/src/app/ESAppListModule.harmony.ts +57 -0
- package/rules/.source/ESCore/src/app/ESAppListModule.ts +15 -0
- package/rules/.source/ESCore/src/app/index.ts +4 -0
- package/rules/.source/ESCore/src/application/ESAppContext.ts +99 -0
- package/rules/.source/ESCore/src/application/ESAppKeyManager.android.ts +86 -0
- package/rules/.source/ESCore/src/application/ESAppKeyManager.harmony.ts +91 -0
- package/rules/.source/ESCore/src/application/ESAppKeyManager.ts +23 -0
- package/rules/.source/ESCore/src/application/ESAppLifecycleManager.android.ts +199 -0
- package/rules/.source/ESCore/src/application/ESAppLifecycleManager.harmony.ts +197 -0
- package/rules/.source/ESCore/src/application/ESAppLifecycleManager.ts +36 -0
- package/rules/.source/ESCore/src/application/ESAppModuleManager.ts +294 -0
- package/rules/.source/ESCore/src/application/ESAppParams.ts +14 -0
- package/rules/.source/ESCore/src/application/ESApplication.ts +169 -0
- package/rules/.source/ESCore/src/application/index.ts +38 -0
- package/rules/.source/ESCore/src/audio/ESAudio.ts +190 -0
- package/rules/.source/ESCore/src/audio/ESAudioContentType.ts +7 -0
- package/rules/.source/ESCore/src/audio/ESAudioDirection.ts +5 -0
- package/rules/.source/ESCore/src/audio/ESAudioDurationHint.ts +7 -0
- package/rules/.source/ESCore/src/audio/ESAudioManagerFlag.ts +14 -0
- package/rules/.source/ESCore/src/audio/ESAudioModule.android.ts +173 -0
- package/rules/.source/ESCore/src/audio/ESAudioModule.harmony.ts +152 -0
- package/rules/.source/ESCore/src/audio/ESAudioModule.ts +63 -0
- package/rules/.source/ESCore/src/audio/ESAudioStreamType.ts +15 -0
- package/rules/.source/ESCore/src/audio/ESAudioUsage.ts +20 -0
- package/rules/.source/ESCore/src/audio/index.ts +9 -0
- package/rules/.source/ESCore/src/brightness/ESBrightness.ts +69 -0
- package/rules/.source/ESCore/src/brightness/ESBrightnessModule.android.ts +73 -0
- package/rules/.source/ESCore/src/brightness/ESBrightnessModule.harmony.ts +59 -0
- package/rules/.source/ESCore/src/brightness/ESBrightnessModule.ts +15 -0
- package/rules/.source/ESCore/src/brightness/index.ts +2 -0
- package/rules/.source/ESCore/src/broadcast/ESBroadcast.ts +107 -0
- package/rules/.source/ESCore/src/broadcast/ESBroadcastModule.android.ts +42 -0
- package/rules/.source/ESCore/src/broadcast/ESBroadcastModule.harmony.ts +45 -0
- package/rules/.source/ESCore/src/broadcast/ESBroadcastModule.ts +10 -0
- package/rules/.source/ESCore/src/broadcast/ESBroadcastReceiver.ts +5 -0
- package/rules/.source/ESCore/src/broadcast/ESIntent.ts +6 -0
- package/rules/.source/ESCore/src/broadcast/ESIntentDataAuthority.ts +4 -0
- package/rules/.source/ESCore/src/broadcast/ESIntentDataPath.ts +4 -0
- package/rules/.source/ESCore/src/broadcast/ESIntentDataSchemeSpecificPart.ts +4 -0
- package/rules/.source/ESCore/src/broadcast/ESIntentFilter.ts +13 -0
- package/rules/.source/ESCore/src/broadcast/index.ts +8 -0
- package/rules/.source/ESCore/src/core/IESComponent.ts +1 -0
- package/rules/.source/ESCore/src/core/IESManager.ts +7 -0
- package/rules/.source/ESCore/src/core/IESModule.ts +13 -0
- package/rules/.source/ESCore/src/core/NeedToTyped.ts +1 -0
- package/rules/.source/ESCore/src/core/index.ts +4 -0
- package/rules/.source/ESCore/src/database/ESDatabase.ts +63 -0
- package/rules/.source/ESCore/src/database/ESDatabaseModule.android.ts +49 -0
- package/rules/.source/ESCore/src/database/ESDatabaseModule.harmony.ts +46 -0
- package/rules/.source/ESCore/src/database/ESDatabaseModule.ts +23 -0
- package/rules/.source/ESCore/src/database/index.ts +2 -0
- package/rules/.source/ESCore/src/develop/ESDevelop.ts +75 -0
- package/rules/.source/ESCore/src/develop/ESDevelopInfo.ts +9 -0
- package/rules/.source/ESCore/src/develop/ESDevelopModule.android.ts +50 -0
- package/rules/.source/ESCore/src/develop/ESDevelopModule.harmony.ts +52 -0
- package/rules/.source/ESCore/src/develop/ESDevelopModule.ts +14 -0
- package/rules/.source/ESCore/src/develop/index.ts +3 -0
- package/rules/.source/ESCore/src/device/ESDevice.ts +289 -0
- package/rules/.source/ESCore/src/device/ESDeviceInfo.ts +51 -0
- package/rules/.source/ESCore/src/device/ESDeviceModule.android.ts +143 -0
- package/rules/.source/ESCore/src/device/ESDeviceModule.harmony.ts +116 -0
- package/rules/.source/ESCore/src/device/ESDeviceModule.ts +42 -0
- package/rules/.source/ESCore/src/device/index.ts +3 -0
- package/rules/.source/ESCore/src/display/ESDisplay.ts +61 -0
- package/rules/.source/ESCore/src/display/index.ts +2 -0
- package/rules/.source/ESCore/src/download/ESDownload.ts +181 -0
- package/rules/.source/ESCore/src/download/ESDownloadInfo.ts +14 -0
- package/rules/.source/ESCore/src/download/ESDownloadListener.ts +21 -0
- package/rules/.source/ESCore/src/download/ESDownloadModule.android.ts +57 -0
- package/rules/.source/ESCore/src/download/ESDownloadModule.harmony.ts +66 -0
- package/rules/.source/ESCore/src/download/ESDownloadModule.ts +21 -0
- package/rules/.source/ESCore/src/download/ESDownloadParams.ts +4 -0
- package/rules/.source/ESCore/src/download/ESDownloadState.ts +9 -0
- package/rules/.source/ESCore/src/download/ESDownloadStatus.ts +11 -0
- package/rules/.source/ESCore/src/download/index.ts +7 -0
- package/rules/.source/ESCore/src/error/ESError.ts +88 -0
- package/rules/.source/ESCore/src/error/ESErrorListener.ts +9 -0
- package/rules/.source/ESCore/src/error/ErrorOptions.ts +16 -0
- package/rules/.source/ESCore/src/error/index.ts +2 -0
- package/rules/.source/ESCore/src/es/ES.ts +140 -0
- package/rules/.source/ESCore/src/es/ESModule.android.ts +166 -0
- package/rules/.source/ESCore/src/es/ESModule.harmony.ts +167 -0
- package/rules/.source/ESCore/src/es/ESModule.ts +41 -0
- package/rules/.source/ESCore/src/es/ESSDKInfo.ts +17 -0
- package/rules/.source/ESCore/src/es/ESVersion.ts +14 -0
- package/rules/.source/ESCore/src/es/index.ts +4 -0
- package/rules/.source/ESCore/src/eventbus/ESEventBus.ts +135 -0
- package/rules/.source/ESCore/src/eventbus/ESEventBusArg.ts +2 -0
- package/rules/.source/ESCore/src/eventbus/ESEventBusCallback.ts +4 -0
- package/rules/.source/ESCore/src/eventbus/ESEventBusContext.ts +2 -0
- package/rules/.source/ESCore/src/eventbus/ESEventBusEvent.ts +7 -0
- package/rules/.source/ESCore/src/eventbus/index.ts +6 -0
- package/rules/.source/ESCore/src/file/ESFile.ts +381 -0
- package/rules/.source/ESCore/src/file/ESFileModule.android.ts +334 -0
- package/rules/.source/ESCore/src/file/ESFileModule.harmony.ts +343 -0
- package/rules/.source/ESCore/src/file/ESFileModule.ts +101 -0
- package/rules/.source/ESCore/src/file/ESFileStat.ts +19 -0
- package/rules/.source/ESCore/src/file/index.ts +1 -0
- package/rules/.source/ESCore/src/focus/ESFocus.ts +56 -0
- package/rules/.source/ESCore/src/focus/ESFocusModule.android.ts +35 -0
- package/rules/.source/ESCore/src/focus/ESFocusModule.harmony.ts +35 -0
- package/rules/.source/ESCore/src/focus/ESFocusModule.ts +12 -0
- package/rules/.source/ESCore/src/focus/ESFocusable.ts +1 -0
- package/rules/.source/ESCore/src/focus/index.ts +3 -0
- package/rules/.source/ESCore/src/global.d.ts +37 -0
- package/rules/.source/ESCore/src/hlog/ESHLog.ts +276 -0
- package/rules/.source/ESCore/src/hlog/ESHLogModule.ts +130 -0
- package/rules/.source/ESCore/src/hlog/ESLogListener.ts +959 -0
- package/rules/.source/ESCore/src/hlog/LogPluginHelper.ts +44 -0
- package/rules/.source/ESCore/src/hlog/index.ts +6 -0
- package/rules/.source/ESCore/src/hlog/listener/OnInitListenerBase.ts +24 -0
- package/rules/.source/ESCore/src/hlog/listener/OnUploadListenerBase.ts +39 -0
- package/rules/.source/ESCore/src/hlog/listener/RemoveInitListenerBase.ts +17 -0
- package/rules/.source/ESCore/src/hlog/listener/RemoveOldUploadListenerBase.ts +21 -0
- package/rules/.source/ESCore/src/hlog/listener/RemoveUploadListenerBase.ts +29 -0
- package/rules/.source/ESCore/src/hlog/listener/SetInitListenerBase.ts +25 -0
- package/rules/.source/ESCore/src/hlog/listener/SetOldUploadListenerBase.ts +33 -0
- package/rules/.source/ESCore/src/hlog/listener/SetUploadListenerBase.ts +47 -0
- package/rules/.source/ESCore/src/iac/ESIAC.ts +150 -0
- package/rules/.source/ESCore/src/iac/ESIACMessage.ts +5 -0
- package/rules/.source/ESCore/src/iac/ESIACMessageFilter.ts +3 -0
- package/rules/.source/ESCore/src/iac/ESIACModule.android.ts +40 -0
- package/rules/.source/ESCore/src/iac/ESIACModule.harmony.ts +63 -0
- package/rules/.source/ESCore/src/iac/ESIACModule.ts +15 -0
- package/rules/.source/ESCore/src/iac/ESIACReceiver.ts +5 -0
- package/rules/.source/ESCore/src/iac/index.ts +5 -0
- package/rules/.source/ESCore/src/index.ts +92 -0
- package/rules/.source/ESCore/src/key/ESKeyAction.ts +5 -0
- package/rules/.source/ESCore/src/key/ESKeyCode.ts +15 -0
- package/rules/.source/ESCore/src/key/ESKeyEvent.ts +8 -0
- package/rules/.source/ESCore/src/key/index.ts +3 -0
- package/rules/.source/ESCore/src/kv/ESKV.ts +104 -0
- package/rules/.source/ESCore/src/kv/ESKVModule.android.ts +60 -0
- package/rules/.source/ESCore/src/kv/ESKVModule.harmony.ts +80 -0
- package/rules/.source/ESCore/src/kv/ESKVModule.ts +28 -0
- package/rules/.source/ESCore/src/kv/index.ts +2 -0
- package/rules/.source/ESCore/src/local/ESLocalStorage.ts +114 -0
- package/rules/.source/ESCore/src/local/ESLocalStorageModule.android.ts +150 -0
- package/rules/.source/ESCore/src/local/ESLocalStorageModule.harmony.ts +119 -0
- package/rules/.source/ESCore/src/local/ESLocalStorageModule.ts +23 -0
- package/rules/.source/ESCore/src/local/index.ts +2 -0
- package/rules/.source/ESCore/src/location/ESLocation.ts +89 -0
- package/rules/.source/ESCore/src/location/ESLocationInfo.ts +9 -0
- package/rules/.source/ESCore/src/location/ESLocationListener.ts +5 -0
- package/rules/.source/ESCore/src/location/ESLocationModule.android.ts +53 -0
- package/rules/.source/ESCore/src/location/ESLocationModule.harmony.ts +23 -0
- package/rules/.source/ESCore/src/location/ESLocationModule.ts +8 -0
- package/rules/.source/ESCore/src/location/index.ts +4 -0
- package/rules/.source/ESCore/src/log/ESLog.ts +163 -0
- package/rules/.source/ESCore/src/log/ESLogModule.android.ts +51 -0
- package/rules/.source/ESCore/src/log/ESLogModule.harmony.ts +52 -0
- package/rules/.source/ESCore/src/log/ESLogModule.ts +18 -0
- package/rules/.source/ESCore/src/log/index.ts +3 -0
- package/rules/.source/ESCore/src/network/ESNetwork.ts +102 -0
- package/rules/.source/ESCore/src/network/ESNetworkInfo.ts +20 -0
- package/rules/.source/ESCore/src/network/ESNetworkInfoState.ts +8 -0
- package/rules/.source/ESCore/src/network/ESNetworkInfoType.ts +6 -0
- package/rules/.source/ESCore/src/network/ESNetworkListener.ts +5 -0
- package/rules/.source/ESCore/src/network/ESNetworkModule.android.ts +38 -0
- package/rules/.source/ESCore/src/network/ESNetworkModule.harmony.ts +122 -0
- package/rules/.source/ESCore/src/network/ESNetworkModule.ts +13 -0
- package/rules/.source/ESCore/src/network/ESWifiInfo.ts +6 -0
- package/rules/.source/ESCore/src/network/index.ts +9 -0
- package/rules/.source/ESCore/src/page/ESPageParams.ts +14 -0
- package/rules/.source/ESCore/src/page/index.ts +1 -0
- package/rules/.source/ESCore/src/permission/ESPermission.ts +46 -0
- package/rules/.source/ESCore/src/permission/ESPermissionModule.android.ts +33 -0
- package/rules/.source/ESCore/src/permission/ESPermissionModule.harmony.ts +33 -0
- package/rules/.source/ESCore/src/permission/ESPermissionModule.ts +12 -0
- package/rules/.source/ESCore/src/permission/ESRequestPermissionsResult.ts +6 -0
- package/rules/.source/ESCore/src/permission/index.ts +3 -0
- package/rules/.source/ESCore/src/platform/ESPlatform.ts +63 -0
- package/rules/.source/ESCore/src/platform/index.ts +1 -0
- package/rules/.source/ESCore/src/plugin/ESPlugin.ts +152 -0
- package/rules/.source/ESCore/src/plugin/ESPluginModule.android.ts +20 -0
- package/rules/.source/ESCore/src/plugin/ESPluginModule.harmony.ts +24 -0
- package/rules/.source/ESCore/src/plugin/ESPluginModule.ts +9 -0
- package/rules/.source/ESCore/src/plugin/index.ts +3 -0
- package/rules/.source/ESCore/src/power/ESPower.ts +41 -0
- package/rules/.source/ESCore/src/power/ESPowerModule.android.ts +31 -0
- package/rules/.source/ESCore/src/power/ESPowerModule.harmony.ts +33 -0
- package/rules/.source/ESCore/src/power/ESPowerModule.ts +7 -0
- package/rules/.source/ESCore/src/power/index.ts +2 -0
- package/rules/.source/ESCore/src/provider/ESContentProvider.ts +82 -0
- package/rules/.source/ESCore/src/provider/ESContentProviderInfo.ts +8 -0
- package/rules/.source/ESCore/src/provider/ESContentProviderModule.android.ts +62 -0
- package/rules/.source/ESCore/src/provider/ESContentProviderModule.harmony.ts +62 -0
- package/rules/.source/ESCore/src/provider/ESContentProviderModule.ts +29 -0
- package/rules/.source/ESCore/src/provider/ESContentProviderResult.ts +4 -0
- package/rules/.source/ESCore/src/provider/ESContentValues.ts +3 -0
- package/rules/.source/ESCore/src/provider/index.ts +5 -0
- package/rules/.source/ESCore/src/router/ESData.ts +3 -0
- package/rules/.source/ESCore/src/router/ESParams.ts +3 -0
- package/rules/.source/ESCore/src/router/ESRouter.ts +364 -0
- package/rules/.source/ESCore/src/router/ESRouterKeyManager.android.ts +107 -0
- package/rules/.source/ESCore/src/router/ESRouterKeyManager.harmony.ts +205 -0
- package/rules/.source/ESCore/src/router/ESRouterKeyManager.ts +11 -0
- package/rules/.source/ESCore/src/router/ESRouterLifecycleManager.ts +301 -0
- package/rules/.source/ESCore/src/router/ESRouterManager.ts +221 -0
- package/rules/.source/ESCore/src/router/index.ts +9 -0
- package/rules/.source/ESCore/src/runtime/ESRuntime.ts +164 -0
- package/rules/.source/ESCore/src/runtime/ESRuntimeDeviceModule.android.ts +76 -0
- package/rules/.source/ESCore/src/runtime/ESRuntimeDeviceModule.harmony.ts +39 -0
- package/rules/.source/ESCore/src/runtime/ESRuntimeDeviceModule.ts +14 -0
- package/rules/.source/ESCore/src/runtime/ESRuntimeDeviceType.ts +53 -0
- package/rules/.source/ESCore/src/runtime/index.ts +4 -0
- package/rules/.source/ESCore/src/service/ESService.ts +34 -0
- package/rules/.source/ESCore/src/service/ESServiceModule.android.ts +20 -0
- package/rules/.source/ESCore/src/service/ESServiceModule.harmony.ts +19 -0
- package/rules/.source/ESCore/src/service/ESServiceModule.ts +5 -0
- package/rules/.source/ESCore/src/service/index.ts +2 -0
- package/rules/.source/ESCore/src/share/ESShareData.ts +177 -0
- package/rules/.source/ESCore/src/share/ESShareDataModule.android.ts +370 -0
- package/rules/.source/ESCore/src/share/ESShareDataModule.harmony.ts +201 -0
- package/rules/.source/ESCore/src/share/ESShareDataModule.ts +83 -0
- package/rules/.source/ESCore/src/share/ESSharedData.ts +9 -0
- package/rules/.source/ESCore/src/share/ESSharedDataMode.ts +5 -0
- package/rules/.source/ESCore/src/share/ESSharedDataParams.ts +4 -0
- package/rules/.source/ESCore/src/share/ESSharedDataType.ts +9 -0
- package/rules/.source/ESCore/src/share/index.ts +7 -0
- package/rules/.source/ESCore/src/slot/ESSlot.ts +75 -0
- package/rules/.source/ESCore/src/slot/ESSlotEvent.ts +4 -0
- package/rules/.source/ESCore/src/slot/ESSlotEventName.ts +3 -0
- package/rules/.source/ESCore/src/slot/ESSlotParams.ts +14 -0
- package/rules/.source/ESCore/src/slot/index.ts +3 -0
- package/rules/.source/ESCore/src/theme/ESTheme.ts +88 -0
- package/rules/.source/ESCore/src/theme/ESThemeListener.ts +3 -0
- package/rules/.source/ESCore/src/theme/index.ts +3 -0
- package/rules/.source/ESCore/src/toast/ESToast.ts +47 -0
- package/rules/.source/ESCore/src/toast/ESToastModule.android.ts +30 -0
- package/rules/.source/ESCore/src/toast/ESToastModule.harmony.ts +30 -0
- package/rules/.source/ESCore/src/toast/ESToastModule.ts +9 -0
- package/rules/.source/ESCore/src/toast/index.ts +2 -0
- package/rules/.source/ESCore/src/upload/ESUpload.ts +226 -0
- package/rules/.source/ESCore/src/upload/ESUploadInfo.ts +13 -0
- package/rules/.source/ESCore/src/upload/ESUploadListener.ts +21 -0
- package/rules/.source/ESCore/src/upload/ESUploadModule.android.ts +60 -0
- package/rules/.source/ESCore/src/upload/ESUploadModule.harmony.ts +51 -0
- package/rules/.source/ESCore/src/upload/ESUploadModule.ts +19 -0
- package/rules/.source/ESCore/src/upload/ESUploadState.ts +9 -0
- package/rules/.source/ESCore/src/upload/ESUploadStatus.ts +11 -0
- package/rules/.source/ESCore/src/upload/index.ts +6 -0
- package/rules/.source/ESCore/src/usb/ESUsbDevice.ts +112 -0
- package/rules/.source/ESCore/src/usb/ESUsbDeviceInfo.ts +11 -0
- package/rules/.source/ESCore/src/usb/ESUsbDeviceListener.ts +7 -0
- package/rules/.source/ESCore/src/usb/ESUsbDeviceModule.android.ts +62 -0
- package/rules/.source/ESCore/src/usb/ESUsbDeviceModule.harmony.ts +58 -0
- package/rules/.source/ESCore/src/usb/ESUsbDeviceModule.ts +23 -0
- package/rules/.source/ESCore/src/usb/index.ts +4 -0
- package/rules/.source/ESCore/src/useApi.ts +257 -0
- package/rules/.source/ESCore/src/xlog/ESLogUpload.ts +92 -0
- package/rules/.source/ESCore/src/xlog/ESLogUploadInfo.ts +12 -0
- package/rules/.source/ESCore/src/xlog/ESLogUploadListener.ts +7 -0
- package/rules/.source/ESCore/src/xlog/ESXLog.ts +130 -0
- package/rules/.source/ESCore/src/xlog/ESXLogModule.android.ts +74 -0
- package/rules/.source/ESCore/src/xlog/ESXLogModule.harmony.ts +47 -0
- package/rules/.source/ESCore/src/xlog/ESXLogModule.ts +24 -0
- package/rules/.source/ESCore/src/xlog/index.ts +6 -0
- package/rules/.source/ESCore/tsconfig.json +34 -0
- package/rules/.source/ESPlayer/package.json +24 -0
- package/rules/.source/ESPlayer/rollup.config.js +28 -0
- package/rules/.source/ESPlayer/src/cache/ESPlayerCache.ts +14 -0
- package/rules/.source/ESPlayer/src/cache/ESPlayerCacheManager.ts +39 -0
- package/rules/.source/ESPlayer/src/core/ESIPlayer.ts +179 -0
- package/rules/.source/ESPlayer/src/core/ESIPlayerManager.ts +7 -0
- package/rules/.source/ESPlayer/src/core/ESMediaMetadata.ts +8 -0
- package/rules/.source/ESPlayer/src/core/ESMediaSource.ts +13 -0
- package/rules/.source/ESPlayer/src/core/ESMediaSourceList.ts +15 -0
- package/rules/.source/ESPlayer/src/core/ESPlayer.ts +100 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerBufferPercentCallback.ts +3 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerCDNInfo.ts +5 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerCommand.ts +1 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerComponentInfo.ts +7 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerConfiguration.ts +13 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerControlOptions.ts +8 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerDurationCallback.ts +3 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerMediaMeta.ts +48 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerPosition.ts +5 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerProgressCallback.ts +3 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerState.ts +44 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerStatus.ts +10 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerTrackInfo.ts +36 -0
- package/rules/.source/ESPlayer/src/core/ESPlayerTrackType.ts +5 -0
- package/rules/.source/ESPlayer/src/core/M3U8DefinitionInfo.ts +38 -0
- package/rules/.source/ESPlayer/src/decode/ESPlayerDecode.ts +12 -0
- package/rules/.source/ESPlayer/src/decode/ESPlayerDecodeManager.ts +81 -0
- package/rules/.source/ESPlayer/src/definition/ESPlayerDefinition.ts +21 -0
- package/rules/.source/ESPlayer/src/definition/ESPlayerDefinitionManager.ts +93 -0
- package/rules/.source/ESPlayer/src/definition/ESPlayerDefinitionStrategy.ts +12 -0
- package/rules/.source/ESPlayer/src/device/ESPlayerDevice.ts +4 -0
- package/rules/.source/ESPlayer/src/device/ESPlayerDeviceManager.ts +41 -0
- package/rules/.source/ESPlayer/src/device/ESPlayerDeviceType.ts +53 -0
- package/rules/.source/ESPlayer/src/display/ESPlayerDisplay.ts +4 -0
- package/rules/.source/ESPlayer/src/display/ESPlayerDisplayManager.ts +63 -0
- package/rules/.source/ESPlayer/src/error/ESPlayerError.ts +5 -0
- package/rules/.source/ESPlayer/src/error/ESPlayerErrors.ts +8 -0
- package/rules/.source/ESPlayer/src/event/ESPlayerEventDefaultListener.ts +127 -0
- package/rules/.source/ESPlayer/src/event/ESPlayerEventListener.ts +120 -0
- package/rules/.source/ESPlayer/src/event/ESPlayerEventManager.ts +451 -0
- package/rules/.source/ESPlayer/src/index.ts +166 -0
- package/rules/.source/ESPlayer/src/info/ESPlayerInfo.ts +16 -0
- package/rules/.source/ESPlayer/src/injectionSymbols.ts +84 -0
- package/rules/.source/ESPlayer/src/interceptor/ESIPlayerInterceptor.ts +11 -0
- package/rules/.source/ESPlayer/src/interceptor/ESPlayerInterceptError.ts +8 -0
- package/rules/.source/ESPlayer/src/interceptor/ESPlayerInterceptResult.ts +8 -0
- package/rules/.source/ESPlayer/src/interceptor/ESPlayerInterceptorManager.ts +95 -0
- package/rules/.source/ESPlayer/src/interceptor/ESPlayerInterceptorType.ts +17 -0
- package/rules/.source/ESPlayer/src/log/ESPlayerLog.ts +143 -0
- package/rules/.source/ESPlayer/src/log/ESPlayerLogModule.ts +43 -0
- package/rules/.source/ESPlayer/src/mode/ESPlayerPlayMode.ts +8 -0
- package/rules/.source/ESPlayer/src/mode/ESPlayerPlayModeManager.ts +39 -0
- package/rules/.source/ESPlayer/src/option/ESPlayerOption.ts +11 -0
- package/rules/.source/ESPlayer/src/option/ESPlayerOptionType.ts +14 -0
- package/rules/.source/ESPlayer/src/rate/ESPlayerRate.ts +11 -0
- package/rules/.source/ESPlayer/src/rate/ESPlayerRateManager.ts +39 -0
- package/rules/.source/ESPlayer/src/ratio/ESPlayerAspectRatio.ts +9 -0
- package/rules/.source/ESPlayer/src/ratio/ESPlayerAspectRatioManager.ts +39 -0
- package/rules/.source/ESPlayer/src/render/ESPlayerRender.ts +5 -0
- package/rules/.source/ESPlayer/src/render/ESPlayerRenderManager.ts +36 -0
- package/rules/.source/ESPlayer/src/storage/ESPlayerLocalStorageManager.ts +97 -0
- package/rules/.source/ESPlayer/src/storage/ESPlayerLocalStorageModule.android.ts +111 -0
- package/rules/.source/ESPlayer/src/storage/ESPlayerLocalStorageModule.harmony.ts +111 -0
- package/rules/.source/ESPlayer/src/storage/ESPlayerLocalStorageModule.ts +21 -0
- package/rules/.source/ESPlayer/src/type/ESPlayerType.ts +18 -0
- package/rules/.source/ESPlayer/src/type/ESPlayerTypeManager.ts +81 -0
- package/rules/.source/ESPlayer/src/useApi.ts +108 -0
- package/rules/.source/ESPlayer/src/view/ESIPlayerView.ts +120 -0
- package/rules/.source/ESPlayer/src/view/ESPlayerDefaultView.ts +127 -0
- package/rules/.source/ESPlayer/src/view/ESPlayerViewManager.ts +453 -0
- package/rules/.source/ESPlayer/src/volume/ESPlayerVolume.ts +4 -0
- package/rules/.source/ESPlayer/src/volume/ESPlayerVolumeManager.ts +51 -0
- package/rules/.source/ESPlayer/src/window/ESPlayerWindowType.ts +5 -0
- package/rules/.source/ESPlayer/tsconfig.json +34 -0
- package/rules/.source/ESPlayer/yarn.lock +4 -0
- package/rules/.source/ESPlayerManager/package.json +24 -0
- package/rules/.source/ESPlayerManager/rollup.config.js +33 -0
- package/rules/.source/ESPlayerManager/src/core/ESBuiltinADPlayerType.ts +9 -0
- package/rules/.source/ESPlayerManager/src/core/ESBuiltinPlayerType.ts +8 -0
- package/rules/.source/ESPlayerManager/src/core/ESIPlayerManager.ts +71 -0
- package/rules/.source/ESPlayerManager/src/core/ESMediaItem.ts +47 -0
- package/rules/.source/ESPlayerManager/src/core/ESMediaItemList.ts +11 -0
- package/rules/.source/ESPlayerManager/src/core/ESPlayerManager.ts +41 -0
- package/rules/.source/ESPlayerManager/src/core/ESPlayerManagerConfiguration.ts +6 -0
- package/rules/.source/ESPlayerManager/src/core/ESPlayerManagerErrors.ts +6 -0
- package/rules/.source/ESPlayerManager/src/event/ESPlayerManagerEventDefaultListener.ts +154 -0
- package/rules/.source/ESPlayerManager/src/event/ESPlayerManagerEventListener.ts +37 -0
- package/rules/.source/ESPlayerManager/src/event/ESPlayerManagerEventManager.ts +521 -0
- package/rules/.source/ESPlayerManager/src/index.ts +37 -0
- package/rules/.source/ESPlayerManager/src/index.vue +2676 -0
- package/rules/.source/ESPlayerManager/src/injectionSymbols.ts +16 -0
- package/rules/.source/ESPlayerManager/src/mode/ESPlayerManagerPlayModeManager.ts +27 -0
- package/rules/.source/ESPlayerManager/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESPlayerManager/src/useApi.ts +22 -0
- package/rules/.source/ESPlayerManager/src/utils/SparseArray.ts +103 -0
- package/rules/.source/ESPlayerManager/src/view/ESIPlayerManagerDefaultView.ts +167 -0
- package/rules/.source/ESPlayerManager/src/view/ESIPlayerManagerView.ts +44 -0
- package/rules/.source/ESPlayerManager/src/view/ESPlayerManagerViewManager.ts +517 -0
- package/rules/.source/ESPlayerManager/tsconfig.json +34 -0
- package/rules/.source/ESRouter/CHANGELOGG.md +899 -0
- package/rules/.source/ESRouter/SECURITY.md +20 -0
- package/rules/.source/ESRouter/api-extractor.json +49 -0
- package/rules/.source/ESRouter/index.js +7 -0
- package/rules/.source/ESRouter/nightwatch.conf.js +240 -0
- package/rules/.source/ESRouter/package.json +19 -0
- package/rules/.source/ESRouter/rollup.config.mjs +195 -0
- package/rules/.source/ESRouter/src/RouterLink.ts +358 -0
- package/rules/.source/ESRouter/src/RouterView.ts +794 -0
- package/rules/.source/ESRouter/src/SlotView.ts +477 -0
- package/rules/.source/ESRouter/src/config.ts +6 -0
- package/rules/.source/ESRouter/src/devtools.ts +576 -0
- package/rules/.source/ESRouter/src/encoding.ts +147 -0
- package/rules/.source/ESRouter/src/errors.ts +200 -0
- package/rules/.source/ESRouter/src/es/ESNativeRouter.android.ts +100 -0
- package/rules/.source/ESRouter/src/es/ESNativeRouter.harmony.ts +155 -0
- package/rules/.source/ESRouter/src/es/ESNativeRouter.ts +24 -0
- package/rules/.source/ESRouter/src/es/ESNativeRouterLaunchMode.ts +7 -0
- package/rules/.source/ESRouter/src/es/ESNativeRouterSplash.ts +6 -0
- package/rules/.source/ESRouter/src/global.d.ts +15 -0
- package/rules/.source/ESRouter/src/globalExtensions.ts +83 -0
- package/rules/.source/ESRouter/src/history/common.ts +237 -0
- package/rules/.source/ESRouter/src/history/es.ts +278 -0
- package/rules/.source/ESRouter/src/history/hash.ts +46 -0
- package/rules/.source/ESRouter/src/history/html5.ts +354 -0
- package/rules/.source/ESRouter/src/history/index.ts +40 -0
- package/rules/.source/ESRouter/src/history/memory.ts +127 -0
- package/rules/.source/ESRouter/src/index.ts +131 -0
- package/rules/.source/ESRouter/src/injectionSymbols.ts +91 -0
- package/rules/.source/ESRouter/src/location.ts +251 -0
- package/rules/.source/ESRouter/src/log/RouterLog.ts +90 -0
- package/rules/.source/ESRouter/src/log/info.ts +9 -0
- package/rules/.source/ESRouter/src/matcher/index.ts +533 -0
- package/rules/.source/ESRouter/src/matcher/pathMatcher.ts +55 -0
- package/rules/.source/ESRouter/src/matcher/pathParserRanker.ts +369 -0
- package/rules/.source/ESRouter/src/matcher/pathTokenizer.ts +200 -0
- package/rules/.source/ESRouter/src/matcher/types.ts +131 -0
- package/rules/.source/ESRouter/src/navigationGuards.ts +409 -0
- package/rules/.source/ESRouter/src/page/PageRouteView.ts +11 -0
- package/rules/.source/ESRouter/src/page/PageView.ts +12 -0
- package/rules/.source/ESRouter/src/query.ts +149 -0
- package/rules/.source/ESRouter/src/result/RouteResult.ts +11 -0
- package/rules/.source/ESRouter/src/result/RouteResultCallback.ts +5 -0
- package/rules/.source/ESRouter/src/router.ts +1930 -0
- package/rules/.source/ESRouter/src/scrollBehavior.ts +194 -0
- package/rules/.source/ESRouter/src/slot/SlotRootView.ts +11 -0
- package/rules/.source/ESRouter/src/slot/SlotView.ts +11 -0
- package/rules/.source/ESRouter/src/types/index.ts +605 -0
- package/rules/.source/ESRouter/src/types/typeGuards.ts +9 -0
- package/rules/.source/ESRouter/src/types/utils.ts +77 -0
- package/rules/.source/ESRouter/src/useApi.ts +29 -0
- package/rules/.source/ESRouter/src/utils/callbacks.ts +24 -0
- package/rules/.source/ESRouter/src/utils/env.ts +1 -0
- package/rules/.source/ESRouter/src/utils/index.ts +60 -0
- package/rules/.source/ESRouter/src/warning.ts +9 -0
- package/rules/.source/ESRouter/tsconfig.json +37 -0
- package/rules/.source/ESSoundPoolPlayer/package.json +23 -0
- package/rules/.source/ESSoundPoolPlayer/rollup.config.js +33 -0
- package/rules/.source/ESSoundPoolPlayer/src/core/ESSoundPoolContentType.ts +7 -0
- package/rules/.source/ESSoundPoolPlayer/src/core/ESSoundPoolStreamType.ts +15 -0
- package/rules/.source/ESSoundPoolPlayer/src/core/ESSoundPoolUsage.ts +19 -0
- package/rules/.source/ESSoundPoolPlayer/src/index.ts +19 -0
- package/rules/.source/ESSoundPoolPlayer/src/index.vue +1564 -0
- package/rules/.source/ESSoundPoolPlayer/src/module/ESSoundPoolPlayerModul.android.ts +133 -0
- package/rules/.source/ESSoundPoolPlayer/src/module/ESSoundPoolPlayerModul.harmony.ts +119 -0
- package/rules/.source/ESSoundPoolPlayer/src/module/ESSoundPoolPlayerModule.ts +48 -0
- package/rules/.source/ESSoundPoolPlayer/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESSoundPoolPlayer/tsconfig.json +34 -0
- package/rules/.source/ESVideoPlayer/package.json +26 -0
- package/rules/.source/ESVideoPlayer/rollup.config.js +33 -0
- package/rules/.source/ESVideoPlayer/src/component/ESVideoPlayerViewComponent.android.ts +948 -0
- package/rules/.source/ESVideoPlayer/src/component/ESVideoPlayerViewComponent.harmony.ts +763 -0
- package/rules/.source/ESVideoPlayer/src/index.ts +18 -0
- package/rules/.source/ESVideoPlayer/src/index.vue +2003 -0
- package/rules/.source/ESVideoPlayer/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/ESVideoPlayer/src/utils/ESVideoPlayerDefinitionUtils.ts +36 -0
- package/rules/.source/ESVideoPlayer/tsconfig.json +34 -0
- package/rules/.source/ESVideoPlayer/tsconfig.json.vite +0 -0
- package/rules/.source/ESVideoPlayer/tsconfig.node.json +0 -0
- package/rules/.source/ESVideoPlayer/vite.config.ts +29 -0
- package/rules/.source/ESVue/CHANGELOG.MD +201 -0
- package/rules/.source/ESVue/api-extractor.json +41 -0
- package/rules/.source/ESVue/package.json +42 -0
- package/rules/.source/ESVue/rollup.config.js +40 -0
- package/rules/.source/ESVue/src/built-in-component.ts +650 -0
- package/rules/.source/ESVue/src/config/index.ts +109 -0
- package/rules/.source/ESVue/src/global.d.ts +636 -0
- package/rules/.source/ESVue/src/hooks/lifecycle.ts +248 -0
- package/rules/.source/ESVue/src/index.ts +365 -0
- package/rules/.source/ESVue/src/modules/attrs.ts +24 -0
- package/rules/.source/ESVue/src/modules/class.ts +31 -0
- package/rules/.source/ESVue/src/modules/events.ts +119 -0
- package/rules/.source/ESVue/src/modules/patch-log.ts +39 -0
- package/rules/.source/ESVue/src/modules/style.ts +68 -0
- package/rules/.source/ESVue/src/node-ops.ts +153 -0
- package/rules/.source/ESVue/src/patch-prop.ts +93 -0
- package/rules/.source/ESVue/src/runtime/component/index.ts +83 -0
- package/rules/.source/ESVue/src/runtime/document/hippy-document.ts +56 -0
- package/rules/.source/ESVue/src/runtime/element/hippy-comment-element.ts +21 -0
- package/rules/.source/ESVue/src/runtime/element/hippy-element.ts +1623 -0
- package/rules/.source/ESVue/src/runtime/element/hippy-input-element.ts +75 -0
- package/rules/.source/ESVue/src/runtime/element/hippy-list-element.ts +306 -0
- package/rules/.source/ESVue/src/runtime/event/event-bus.ts +148 -0
- package/rules/.source/ESVue/src/runtime/event/hippy-event-dispatcher.ts +391 -0
- package/rules/.source/ESVue/src/runtime/event/hippy-event-target.ts +191 -0
- package/rules/.source/ESVue/src/runtime/event/hippy-event.ts +317 -0
- package/rules/.source/ESVue/src/runtime/native/index.ts +924 -0
- package/rules/.source/ESVue/src/runtime/node/hippy-node.ts +722 -0
- package/rules/.source/ESVue/src/runtime/node/node-log.ts +39 -0
- package/rules/.source/ESVue/src/runtime/render/index.ts +550 -0
- package/rules/.source/ESVue/src/runtime/style/css-map.ts +100 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-auto-style.ts +119 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-percent-style.ts +111 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-rem-style.ts +45 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-scale-style.ts +103 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-style.ts +24 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-variables.ts +209 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-vwvh-style.ts +65 -0
- package/rules/.source/ESVue/src/runtime/style/css-resolve-width-height-style.ts +18 -0
- package/rules/.source/ESVue/src/runtime/style/css-selectors-match.ts +295 -0
- package/rules/.source/ESVue/src/runtime/style/css-selectors.ts +1173 -0
- package/rules/.source/ESVue/src/runtime/style/index.ts +154 -0
- package/rules/.source/ESVue/src/runtime/style/log.ts +39 -0
- package/rules/.source/ESVue/src/runtime/style/parser.ts +291 -0
- package/rules/.source/ESVue/src/runtime/text/hippy-text.ts +41 -0
- package/rules/.source/ESVue/src/runtime/websocket/websocket.ts +282 -0
- package/rules/.source/ESVue/src/types/index.ts +25 -0
- package/rules/.source/ESVue/src/types/native-modules/clip-board-module.ts +24 -0
- package/rules/.source/ESVue/src/types/native-modules/device-event-module.ts +24 -0
- package/rules/.source/ESVue/src/types/native-modules/http.ts +57 -0
- package/rules/.source/ESVue/src/types/native-modules/image-loader-module.ts +27 -0
- package/rules/.source/ESVue/src/types/native-modules/net-info.ts +29 -0
- package/rules/.source/ESVue/src/types/native-modules/network.ts +24 -0
- package/rules/.source/ESVue/src/types/native-modules/test-module.ts +23 -0
- package/rules/.source/ESVue/src/types/native-modules/ui-manager-module.ts +44 -0
- package/rules/.source/ESVue/src/types/native-modules/websocket.ts +49 -0
- package/rules/.source/ESVue/src/types/native-modules.ts +41 -0
- package/rules/.source/ESVue/src/types/native-node.ts +48 -0
- package/rules/.source/ESVue/src/util/event.ts +74 -0
- package/rules/.source/ESVue/src/util/i18n.ts +32 -0
- package/rules/.source/ESVue/src/util/index.ts +418 -0
- package/rules/.source/ESVue/src/util/instance.ts +77 -0
- package/rules/.source/ESVue/src/util/log.ts +39 -0
- package/rules/.source/ESVue/src/util/node.ts +152 -0
- package/rules/.source/ESVue/src/util/rem.ts +54 -0
- package/rules/.source/ESVue/src/util/screen.ts +42 -0
- package/rules/.source/ESVue/tsconfig.json +34 -0
- package/rules/.source/ESVue/tsdoc.json +6 -0
- package/rules/.source/ESVue/yarn.lock +4 -0
- package/rules/.source/ESVueCssLoader/package.json +27 -0
- package/rules/.source/ESVueCssLoader/rollup.config.js +20 -0
- package/rules/.source/ESVueCssLoader/src/index.ts +2 -0
- package/rules/.source/ESVueCssLoader/src/log/log.ts +38 -0
- package/rules/.source/ESVueCssLoader/src/style-parser/color-parser.ts +357 -0
- package/rules/.source/ESVueCssLoader/src/style-parser/css-loader.ts +93 -0
- package/rules/.source/ESVueCssLoader/src/style-parser/css-parser.ts +1123 -0
- package/rules/.source/ESVueCssLoader/src/types.ts +5 -0
- package/rules/.source/ESVueCssLoader/src/utils/utils.ts +59 -0
- package/rules/.source/ESVueCssLoader/tsconfig.json +34 -0
- package/rules/.source/ESVueStyleParser/api-extractor.json +38 -0
- package/rules/.source/ESVueStyleParser/package.json +24 -0
- package/rules/.source/ESVueStyleParser/rollup.config.js +28 -0
- package/rules/.source/ESVueStyleParser/src/index.ts +24 -0
- package/rules/.source/ESVueStyleParser/src/style-parser/android-color-parser.ts +143 -0
- package/rules/.source/ESVueStyleParser/src/style-parser/color-parser.ts +256 -0
- package/rules/.source/ESVueStyleParser/src/style-parser/css-parser.ts +1371 -0
- package/rules/.source/ESVueStyleParser/src/style-parser/named-colors.ts +154 -0
- package/rules/.source/ESVueStyleParser/src/style-parser/utils.ts +55 -0
- package/rules/.source/ESVueStyleParser/src/types.ts +5 -0
- package/rules/.source/ESVueStyleParser/tsconfig.json +34 -0
- package/rules/.source/component/package.json +24 -0
- package/rules/.source/component/rollup.config.js +28 -0
- package/rules/.source/component/src/ESAnimationView/ESAnimationViewComponent.ts +51 -0
- package/rules/.source/component/src/ESAppIconView/ESAppIconViewComponent.ts +46 -0
- package/rules/.source/component/src/ESAppIconView/ESIAppIcon.ts +5 -0
- package/rules/.source/component/src/ESCardView/ESCardContainerViewComponent.ts +127 -0
- package/rules/.source/component/src/ESCardView/ESCardEvent.ts +3 -0
- package/rules/.source/component/src/ESCardView/ESCardViewComponent.ts +54 -0
- package/rules/.source/component/src/ESCardView/ESICard.ts +9 -0
- package/rules/.source/component/src/ESCardView/ESICardContainer.ts +25 -0
- package/rules/.source/component/src/ESChartView/ESBarChartViewComponent.ts +35 -0
- package/rules/.source/component/src/ESChartView/ESIChart.ts +3 -0
- package/rules/.source/component/src/ESChartView/ESLineChartViewComponent.ts +35 -0
- package/rules/.source/component/src/ESDialog/ESDialogComponent.ts +15 -0
- package/rules/.source/component/src/ESFastSwiperSlideView/ESFastSwiperSlideViewComponent.ts +46 -0
- package/rules/.source/component/src/ESFlexView/ESFlexViewComponent.ts +22 -0
- package/rules/.source/component/src/ESGradient/ESGradient.ts +14 -0
- package/rules/.source/component/src/ESGradient/ESGradientOrientation.ts +10 -0
- package/rules/.source/component/src/ESGradient/ESGradientShape.ts +6 -0
- package/rules/.source/component/src/ESGradient/ESGradientType.ts +5 -0
- package/rules/.source/component/src/ESItem/ESItemComponent.ts +40 -0
- package/rules/.source/component/src/ESItemStoreView/ESItemStoreViewComponent.ts +23 -0
- package/rules/.source/component/src/ESLargeListView/ESLargeListViewComponent.ts +136 -0
- package/rules/.source/component/src/ESLoading/ESLoadingViewComponent.ts +16 -0
- package/rules/.source/component/src/ESLoading/ESLoadingViewElement.android.ts +11 -0
- package/rules/.source/component/src/ESLoading/ESLoadingViewElement.harmony.ts +11 -0
- package/rules/.source/component/src/ESLottieView/ESLottieViewComponent.android.ts +29 -0
- package/rules/.source/component/src/ESLottieView/ESLottieViewComponent.harmony.ts +29 -0
- package/rules/.source/component/src/ESMediaSeries/ESIMediaSeries.ts +24 -0
- package/rules/.source/component/src/ESMediaSeries/ESMediaSeries.ts +6 -0
- package/rules/.source/component/src/ESMediaSeries/ESMediaSeriesComponent.ts +142 -0
- package/rules/.source/component/src/ESOrientationSeekBar/ESHorizontalSeekBarViewComponent.ts +1305 -0
- package/rules/.source/component/src/ESOrientationSeekBar/ESIHorizontalSeekBar.ts +255 -0
- package/rules/.source/component/src/ESOrientationSeekBar/ESIVerticalSeekBar.ts +13 -0
- package/rules/.source/component/src/ESOrientationSeekBar/ESVerticalSeekBarViewComponent.ts +1356 -0
- package/rules/.source/component/src/ESPlayMarkView/ESPlayMarkViewComponent.ts +21 -0
- package/rules/.source/component/src/ESPluginView/ESPluginViewComponent.ts +34 -0
- package/rules/.source/component/src/ESProgressBarView/ESProgressBarViewComponent.ts +38 -0
- package/rules/.source/component/src/ESQRCodeView/ESQRCodeViewComponent.ts +11 -0
- package/rules/.source/component/src/ESReplaceChildView/ESReplaceChildViewComponent.ts +151 -0
- package/rules/.source/component/src/ESRippleView/ESRippleViewComponent.ts +45 -0
- package/rules/.source/component/src/ESScrollView/ESIScrollView.ts +7 -0
- package/rules/.source/component/src/ESScrollView/ESScrollViewComponent.ts +49 -0
- package/rules/.source/component/src/ESSeekBarView/ESSeekBarViewElement.android.ts +38 -0
- package/rules/.source/component/src/ESSeekBarView/ESSeekBarViewElement.harmony.ts +38 -0
- package/rules/.source/component/src/ESSurfaceView/ESSurfaceViewComponent.ts +21 -0
- package/rules/.source/component/src/ESSwiftListView/ESSwiftListViewComponent.ts +117 -0
- package/rules/.source/component/src/ESSwiperSlideView/ESSwiperSlideViewComponent.ts +31 -0
- package/rules/.source/component/src/ESSwiperView/ESSwiperViewComponent.ts +82 -0
- package/rules/.source/component/src/ESTVItemView/ESTVItemViewComponent.ts +185 -0
- package/rules/.source/component/src/ESTVListView/ESIListView.ts +184 -0
- package/rules/.source/component/src/ESTVListView/ESListInitPosition.ts +15 -0
- package/rules/.source/component/src/ESTVListView/ESListViewItem.ts +10 -0
- package/rules/.source/component/src/ESTVListView/ESListViewItemDecoration.ts +7 -0
- package/rules/.source/component/src/ESTVListView/ESListViewItemFunctionParams.ts +7 -0
- package/rules/.source/component/src/ESTVListView/ESTVListViewComponent.ts +697 -0
- package/rules/.source/component/src/ESTabsView/ESITab.ts +90 -0
- package/rules/.source/component/src/ESTabsView/ESTab.ts +7 -0
- package/rules/.source/component/src/ESTabsView/ESTabItem.ts +8 -0
- package/rules/.source/component/src/ESTabsView/ESTabsViewComponent.ts +383 -0
- package/rules/.source/component/src/ESTestView/ESITestAView.ts +1 -0
- package/rules/.source/component/src/ESTestView/ESITestGroup.ts +3 -0
- package/rules/.source/component/src/ESTestView/ESITestView.ts +3 -0
- package/rules/.source/component/src/ESTestView/ESTestAViewComponent.ts +34 -0
- package/rules/.source/component/src/ESTestView/ESTestGroupComponent.ts +39 -0
- package/rules/.source/component/src/ESTestView/ESTestViewComponent.ts +51 -0
- package/rules/.source/component/src/ESTextView/ESTextViewComponent.ts +22 -0
- package/rules/.source/component/src/ESTransitionImageView/ESITransitionImage.ts +7 -0
- package/rules/.source/component/src/ESTransitionImageView/ESTransitionImageViewComponent.ts +58 -0
- package/rules/.source/component/src/ESView/ESDirections.ts +7 -0
- package/rules/.source/component/src/ESView/ESIView.ts +6 -0
- package/rules/.source/component/src/ESView/ESViewComponent.ts +24 -0
- package/rules/.source/component/src/ESView/ESViewCoordinate.ts +4 -0
- package/rules/.source/component/src/ESView/ESViewScrollState.ts +5 -0
- package/rules/.source/component/src/ESView/ESViewState.ts +16 -0
- package/rules/.source/component/src/ESView/ESViewStateCallback.ts +5 -0
- package/rules/.source/component/src/ESViewPager/ESIViewPager.ts +8 -0
- package/rules/.source/component/src/ESViewPager/ESPageData.ts +7 -0
- package/rules/.source/component/src/ESViewPager/ESViewPagerComponent.ts +58 -0
- package/rules/.source/component/src/ESWebView/ESWebViewComponent.ts +48 -0
- package/rules/.source/component/src/ESX5WebView/ESX5WebViewElement.android.ts +70 -0
- package/rules/.source/component/src/ESX5WebView/ESX5WebViewElement.harmony.ts +70 -0
- package/rules/.source/component/src/index.ts +180 -0
- package/rules/.source/component/src/tv-div/TVDivComponent.ts +131 -0
- package/rules/.source/component/src/tv-image/TVImageComponent.ts +126 -0
- package/rules/.source/component/src/tv-li/TVLiComponent.ts +10 -0
- package/rules/.source/component/src/tv-swiper/TVSwiperComponent.ts +110 -0
- package/rules/.source/component/src/tv-ul/TVULComponent.ts +82 -0
- package/rules/.source/component/src/typings/index.ts +7 -0
- package/rules/.source/component/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/component/tsconfig.json +34 -0
- package/rules/.source/hippy/extend_views/CoverFlowHorizontalView.java +203 -0
- package/rules/.source/hippy/extend_views/CoverFlowVerticalView.java +203 -0
- package/rules/.source/hippy/extend_views/CoverFlowViewController.java +195 -0
- package/rules/.source/hippy/extend_views/EngineRootView.java +125 -0
- package/rules/.source/hippy/extend_views/ExtendTag.java +83 -0
- package/rules/.source/hippy/extend_views/FocusSearchHelper.java +124 -0
- package/rules/.source/hippy/extend_views/IRecyclerItemView.java +12 -0
- package/rules/.source/hippy/extend_views/JSEventHandleView.java +5 -0
- package/rules/.source/hippy/extend_views/MarqueeRelayManager.java +133 -0
- package/rules/.source/hippy/extend_views/MarqueeRelayTextView.java +211 -0
- package/rules/.source/hippy/extend_views/ProgressBarView.java +83 -0
- package/rules/.source/hippy/extend_views/ProgressBarViewController.java +145 -0
- package/rules/.source/hippy/extend_views/SeekBarView.java +104 -0
- package/rules/.source/hippy/extend_views/SeekBarViewController.java +218 -0
- package/rules/.source/hippy/extend_views/StateImageView.java +149 -0
- package/rules/.source/hippy/extend_views/StateImageViewController.java +34 -0
- package/rules/.source/hippy/extend_views/TVButtonView.java +314 -0
- package/rules/.source/hippy/extend_views/TVButtonViewController.java +89 -0
- package/rules/.source/hippy/extend_views/TVTextView.java +684 -0
- package/rules/.source/hippy/extend_views/TVViewActor.java +811 -0
- package/rules/.source/hippy/extend_views/TVViewActorHost.java +6 -0
- package/rules/.source/hippy/extend_views/TVViewActor/346/216/245/345/205/245.md +66 -0
- package/rules/.source/hippy/extend_views/TemplateUtil.java +336 -0
- package/rules/.source/hippy/extend_views/TextButtonNode.java +47 -0
- package/rules/.source/hippy/extend_views/TextViewController.java +377 -0
- package/rules/.source/hippy/extend_views/fastlist/CenterFlyInAnimator.java +96 -0
- package/rules/.source/hippy/extend_views/fastlist/ChildOnScreenScroller.java +548 -0
- package/rules/.source/hippy/extend_views/fastlist/ClonedViewTag.java +17 -0
- package/rules/.source/hippy/extend_views/fastlist/EventDeliverer.java +55 -0
- package/rules/.source/hippy/extend_views/fastlist/FastAdapter.java +4683 -0
- package/rules/.source/hippy/extend_views/fastlist/FastAdapterUtil.java +982 -0
- package/rules/.source/hippy/extend_views/fastlist/FastFlexNode.java +48 -0
- package/rules/.source/hippy/extend_views/fastlist/FastFlexView.java +873 -0
- package/rules/.source/hippy/extend_views/fastlist/FastFlexViewController.java +130 -0
- package/rules/.source/hippy/extend_views/fastlist/FastItemNode.java +67 -0
- package/rules/.source/hippy/extend_views/fastlist/FastItemView.java +306 -0
- package/rules/.source/hippy/extend_views/fastlist/FastItemViewController.java +106 -0
- package/rules/.source/hippy/extend_views/fastlist/FastListModule.java +95 -0
- package/rules/.source/hippy/extend_views/fastlist/FastListNode.java +90 -0
- package/rules/.source/hippy/extend_views/fastlist/FastListView.java +2466 -0
- package/rules/.source/hippy/extend_views/fastlist/FastListViewController.java +1038 -0
- package/rules/.source/hippy/extend_views/fastlist/FastListView/346/270/262/346/237/223/346/265/201/347/250/213/345/233/276.graffle +0 -0
- package/rules/.source/hippy/extend_views/fastlist/FastPendingView.java +47 -0
- package/rules/.source/hippy/extend_views/fastlist/ItemDecorations.java +71 -0
- package/rules/.source/hippy/extend_views/fastlist/ItemStoreNode.java +64 -0
- package/rules/.source/hippy/extend_views/fastlist/ItemStoreView.java +13 -0
- package/rules/.source/hippy/extend_views/fastlist/ItemStoreViewController.java +45 -0
- package/rules/.source/hippy/extend_views/fastlist/ListItemHolder.java +7 -0
- package/rules/.source/hippy/extend_views/fastlist/ListViewControlProp.java +41 -0
- package/rules/.source/hippy/extend_views/fastlist/MouseRecycleView.java +509 -0
- package/rules/.source/hippy/extend_views/fastlist/OnFastItemClickListener.java +12 -0
- package/rules/.source/hippy/extend_views/fastlist/OnFastItemFocusChangeListener.java +9 -0
- package/rules/.source/hippy/extend_views/fastlist/OnFastScrollStateChangedListener.java +7 -0
- package/rules/.source/hippy/extend_views/fastlist/PendingListNode.java +18 -0
- package/rules/.source/hippy/extend_views/fastlist/PendingViewController.java +13 -0
- package/rules/.source/hippy/extend_views/fastlist/PostHandlerView.java +6 -0
- package/rules/.source/hippy/extend_views/fastlist/PostTaskHolder.java +20 -0
- package/rules/.source/hippy/extend_views/fastlist/ReplaceChildController.java +105 -0
- package/rules/.source/hippy/extend_views/fastlist/ReplaceChildView.java +312 -0
- package/rules/.source/hippy/extend_views/fastlist/TVListView.java +3692 -0
- package/rules/.source/hippy/extend_views/fastlist/TemplateCodeParser.java +247 -0
- package/rules/.source/hippy/extend_views/fastlist/Utils.java +572 -0
- package/rules/.source/hippy/extend_views/fastlist/ViewTag.java +317 -0
- package/rules/.source/hippy/extend_views/fastlist/VirtualListView.java +8 -0
- package/rules/.source/hippy/extend_views/fastlist/diff/FastListDataBindingHelper.java +320 -0
- package/rules/.source/hippy/extend_views/fastlist/diff/KeyDiffHelper.java +289 -0
- package/rules/.source/hippy/extend_views/fastlist/diff/NoKeyDiffHelper.java +278 -0
- package/rules/.source/hippy/extend_views/tag/FontTag.java +53 -0
- package/rules/.source/hippy/extend_views/tag/HtmlTag.java +191 -0
- package/rules/.source/hippy/extend_views/tag/HtmlTagHandler.java +185 -0
- package/rules/.source/hippy/extend_views/tag/SpanTag.java +160 -0
- package/rules/.source/hippy/extend_views/tag/TextFontSpan.java +102 -0
- package/rules/.source/hippy/extend_views/waterfall/Chunk.java +10 -0
- package/rules/.source/hippy/extend_views/waterfall/ChunkGroup.java +5 -0
- package/rules/.source/hippy/extend_views/waterfall/Section.java +4 -0
- package/rules/.source/hippy/extend_views/waterfall/Tabs.java +5 -0
- package/rules/.source/hippy/extend_views/waterfall/WaterfallUtils.java +26 -0
- package/rules/.source/hippy/hippy_uimanager/ControllerHolder.java +30 -0
- package/rules/.source/hippy/hippy_uimanager/ControllerManager.java +651 -0
- package/rules/.source/hippy/hippy_uimanager/ControllerRegistry.java +102 -0
- package/rules/.source/hippy/hippy_uimanager/ControllerUpdateManger.java +252 -0
- package/rules/.source/hippy/hippy_uimanager/CustomControllerHelper.java +425 -0
- package/rules/.source/hippy/hippy_uimanager/DiffUtils.java +526 -0
- package/rules/.source/hippy/hippy_uimanager/ExtendViewGroup.java +36 -0
- package/rules/.source/hippy/hippy_uimanager/HippyCustomViewCreator.java +29 -0
- package/rules/.source/hippy/hippy_uimanager/HippyGroupController.java +83 -0
- package/rules/.source/hippy/hippy_uimanager/HippyViewBase.java +27 -0
- package/rules/.source/hippy/hippy_uimanager/HippyViewController.java +2189 -0
- package/rules/.source/hippy/hippy_uimanager/HippyViewEvent.java +52 -0
- package/rules/.source/hippy/hippy_uimanager/IHippyZIndexViewGroup.java +24 -0
- package/rules/.source/hippy/hippy_uimanager/InternalExtendViewUtil.java +395 -0
- package/rules/.source/hippy/hippy_uimanager/ListItemRenderNode.java +143 -0
- package/rules/.source/hippy/hippy_uimanager/ListViewRenderNode.java +44 -0
- package/rules/.source/hippy/hippy_uimanager/MatrixUtil.java +470 -0
- package/rules/.source/hippy/hippy_uimanager/NativeGestureDispatcher.java +349 -0
- package/rules/.source/hippy/hippy_uimanager/NativeGestureProcessor.java +188 -0
- package/rules/.source/hippy/hippy_uimanager/PullFooterRenderNode.java +43 -0
- package/rules/.source/hippy/hippy_uimanager/PullHeaderRenderNode.java +43 -0
- package/rules/.source/hippy/hippy_uimanager/RenderManager.java +304 -0
- package/rules/.source/hippy/hippy_uimanager/RenderNode.java +533 -0
- package/rules/.source/hippy/hippy_uimanager/StateView.java +17 -0
- package/rules/.source/hippy/hippy_uimanager/TransformUtil.java +125 -0
- package/rules/.source/hippy/hippy_uimanager/ViewGroupDrawingOrderHelper.java +108 -0
- package/rules/.source/hippy/hippy_uimanager/ViewStateProvider.java +10 -0
- package/rules/.source/hippy/hippy_views/audioview/AudioPlayManager.java +457 -0
- package/rules/.source/hippy/hippy_views/audioview/AudioView.java +225 -0
- package/rules/.source/hippy/hippy_views/audioview/AudioViewController.java +135 -0
- package/rules/.source/hippy/hippy_views/common/CommonBackgroundDrawable.java +58 -0
- package/rules/.source/hippy/hippy_views/common/CommonBorder.java +37 -0
- package/rules/.source/hippy/hippy_views/custom/HippyCustomPropsController.java +61 -0
- package/rules/.source/hippy/hippy_views/hippylist/HippyRecyclerListAdapter.java +399 -0
- package/rules/.source/hippy/hippy_views/hippylist/HippyRecyclerView.java +378 -0
- package/rules/.source/hippy/hippy_views/hippylist/HippyRecyclerViewController.java +187 -0
- package/rules/.source/hippy/hippy_views/hippylist/HippyRecyclerViewHolder.java +39 -0
- package/rules/.source/hippy/hippy_views/hippylist/HippyRecyclerViewWrapper.java +134 -0
- package/rules/.source/hippy/hippy_views/hippylist/NodePositionHelper.java +55 -0
- package/rules/.source/hippy/hippy_views/hippylist/PreloadHelper.java +54 -0
- package/rules/.source/hippy/hippy_views/hippylist/PullFooterEventHelper.java +61 -0
- package/rules/.source/hippy/hippy_views/hippylist/PullHeaderEventHelper.java +127 -0
- package/rules/.source/hippy/hippy_views/hippylist/RecyclerViewEventHelper.java +394 -0
- package/rules/.source/hippy/hippy_views/image/HippyContentDrawable.java +113 -0
- package/rules/.source/hippy/hippy_views/image/HippyImageView.java +1608 -0
- package/rules/.source/hippy/hippy_views/image/HippyImageViewController.java +382 -0
- package/rules/.source/hippy/hippy_views/image/IImageStateListener.java +7 -0
- package/rules/.source/hippy/hippy_views/list/ChildOnScreenScroller.java +255 -0
- package/rules/.source/hippy/hippy_views/list/HippyListAdapter.java +647 -0
- package/rules/.source/hippy/hippy_views/list/HippyListItemView.java +162 -0
- package/rules/.source/hippy/hippy_views/list/HippyListItemViewController.java +45 -0
- package/rules/.source/hippy/hippy_views/list/HippyListView.java +915 -0
- package/rules/.source/hippy/hippy_views/list/HippyListViewController.java +622 -0
- package/rules/.source/hippy/hippy_views/list/HippyRecycler.java +31 -0
- package/rules/.source/hippy/hippy_views/list/IRecycleItemTypeChange.java +23 -0
- package/rules/.source/hippy/hippy_views/list/ItemDecorations.java +70 -0
- package/rules/.source/hippy/hippy_views/list/NegativeLongKeyFlinger.java +156 -0
- package/rules/.source/hippy/hippy_views/list/NodeHolder.java +34 -0
- package/rules/.source/hippy/hippy_views/list/RecycleViewFlinger.java +126 -0
- package/rules/.source/hippy/hippy_views/list/TVRecyclerView.java +2070 -0
- package/rules/.source/hippy/hippy_views/list/TVSingleLineListView.java +15 -0
- package/rules/.source/hippy/hippy_views/modal/HippyModalHostManager.java +102 -0
- package/rules/.source/hippy/hippy_views/modal/HippyModalHostView.java +597 -0
- package/rules/.source/hippy/hippy_views/modal/ModalHostHelper.java +46 -0
- package/rules/.source/hippy/hippy_views/modal/ModalStyleNode.java +34 -0
- package/rules/.source/hippy/hippy_views/modal/RequestCloseEvent.java +32 -0
- package/rules/.source/hippy/hippy_views/modal/ShowEvent.java +31 -0
- package/rules/.source/hippy/hippy_views/navigator/Navigator.java +126 -0
- package/rules/.source/hippy/hippy_views/navigator/NavigatorController.java +120 -0
- package/rules/.source/hippy/hippy_views/refresh/HippyPullFooterView.java +47 -0
- package/rules/.source/hippy/hippy_views/refresh/HippyPullFooterViewController.java +65 -0
- package/rules/.source/hippy/hippy_views/refresh/HippyPullHeaderView.java +39 -0
- package/rules/.source/hippy/hippy_views/refresh/HippyPullHeaderViewController.java +104 -0
- package/rules/.source/hippy/hippy_views/refresh/RefreshWrapper.java +237 -0
- package/rules/.source/hippy/hippy_views/refresh/RefreshWrapperController.java +62 -0
- package/rules/.source/hippy/hippy_views/refresh/RefreshWrapperItemController.java +39 -0
- package/rules/.source/hippy/hippy_views/refresh/RefreshWrapperItemView.java +26 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyHorizontalScrollView.java +500 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyOnScrollHelper.java +39 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyScrollView.java +46 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyScrollViewController.java +178 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyScrollViewEventHelper.java +92 -0
- package/rules/.source/hippy/hippy_views/scroll/HippyVerticalScrollView.java +522 -0
- package/rules/.source/hippy/hippy_views/text/HippyTextView.java +512 -0
- package/rules/.source/hippy/hippy_views/text/HippyTextViewController.java +77 -0
- package/rules/.source/hippy/hippy_views/textinput/HippyTextInput.java +668 -0
- package/rules/.source/hippy/hippy_views/textinput/HippyTextInputController.java +528 -0
- package/rules/.source/hippy/hippy_views/textinput/TextInputNode.java +115 -0
- package/rules/.source/hippy/hippy_views/videoview/APEZProvider.java +287 -0
- package/rules/.source/hippy/hippy_views/videoview/APKExpansionSupport.java +82 -0
- package/rules/.source/hippy/hippy_views/videoview/PivotPoint.java +13 -0
- package/rules/.source/hippy/hippy_views/videoview/ScalableType.java +34 -0
- package/rules/.source/hippy/hippy_views/videoview/ScalableVideoView.java +265 -0
- package/rules/.source/hippy/hippy_views/videoview/ScaleManager.java +191 -0
- package/rules/.source/hippy/hippy_views/videoview/Size.java +19 -0
- package/rules/.source/hippy/hippy_views/videoview/VideoHippyView.java +917 -0
- package/rules/.source/hippy/hippy_views/videoview/VideoHippyViewController.java +236 -0
- package/rules/.source/hippy/hippy_views/videoview/ZipResourceFile.java +427 -0
- package/rules/.source/hippy/hippy_views/view/CardRootView.java +28 -0
- package/rules/.source/hippy/hippy_views/view/CustomLayoutView.java +10 -0
- package/rules/.source/hippy/hippy_views/view/CustomNodeView.java +5 -0
- package/rules/.source/hippy/hippy_views/view/DialogViewGroup.java +113 -0
- package/rules/.source/hippy/hippy_views/view/HippyViewGroup.java +2042 -0
- package/rules/.source/hippy/hippy_views/view/HippyViewGroupController.java +583 -0
- package/rules/.source/hippy/hippy_views/view/WindowRoot.java +5 -0
- package/rules/.source/hippy/hippy_views/viewpager/HippyViewPager.java +308 -0
- package/rules/.source/hippy/hippy_views/viewpager/HippyViewPagerAdapter.java +148 -0
- package/rules/.source/hippy/hippy_views/viewpager/HippyViewPagerController.java +246 -0
- package/rules/.source/hippy/hippy_views/viewpager/HippyViewPagerItem.java +27 -0
- package/rules/.source/hippy/hippy_views/viewpager/HippyViewPagerItemController.java +42 -0
- package/rules/.source/hippy/hippy_views/viewpager/ViewPagerPageChangeListener.java +114 -0
- package/rules/.source/hippy/hippy_views/viewpager/event/HippyPageItemExposureEvent.java +40 -0
- package/rules/.source/hippy/hippy_views/viewpager/event/HippyPageScrollEvent.java +43 -0
- package/rules/.source/hippy/hippy_views/viewpager/event/HippyPageScrollStateChangedEvent.java +42 -0
- package/rules/.source/hippy/hippy_views/viewpager/event/HippyPageSelectedEvent.java +42 -0
- package/rules/.source/hippy/hippy_views/webview/HippyWebView.java +160 -0
- package/rules/.source/hippy/hippy_views/webview/HippyWebViewBridge.java +20 -0
- package/rules/.source/hippy/hippy_views/webview/HippyWebViewController.java +103 -0
- package/rules/.source/hippy/hippy_views/webview/HippyWebViewInner.java +77 -0
- package/rules/.source/quicktvui/assets/ic_media_sereis_vip.png +0 -0
- package/rules/.source/quicktvui/package.json +38 -0
- package/rules/.source/quicktvui/rollup.config.js +33 -0
- package/rules/.source/quicktvui/src/animation/QTAnimation.android.ts +1139 -0
- package/rules/.source/quicktvui/src/animation/QTAnimation.harmony.ts +1088 -0
- package/rules/.source/quicktvui/src/animation/QTIAnimation.ts +336 -0
- package/rules/.source/quicktvui/src/animation/QtAnimationAPI.ts +467 -0
- package/rules/.source/quicktvui/src/animation/types.ts +97 -0
- package/rules/.source/quicktvui/src/app/QTAppIcon.ts +41 -0
- package/rules/.source/quicktvui/src/app/QTIAppIcon.ts +5 -0
- package/rules/.source/quicktvui/src/app/QtAppIconAPI.ts +56 -0
- package/rules/.source/quicktvui/src/assets/vip.png +0 -0
- package/rules/.source/quicktvui/src/base/QTIBaseView.ts +95 -0
- package/rules/.source/quicktvui/src/base/QtBaseNativeViewAPI.ts +604 -0
- package/rules/.source/quicktvui/src/base/QtBaseViewAPI.ts +750 -0
- package/rules/.source/quicktvui/src/base/useBaseView.ts +374 -0
- package/rules/.source/quicktvui/src/button/QTIButton.ts +3 -0
- package/rules/.source/quicktvui/src/button/QtButtonAPI.ts +9 -0
- package/rules/.source/quicktvui/src/button/index.vue +223 -0
- package/rules/.source/quicktvui/src/canvas/CanvasGradient.ts +84 -0
- package/rules/.source/quicktvui/src/canvas/QTCanvasView.ts +468 -0
- package/rules/.source/quicktvui/src/canvas/QTICanvasView.ts +141 -0
- package/rules/.source/quicktvui/src/canvas/QtCanvasViewAPI.ts +1140 -0
- package/rules/.source/quicktvui/src/classified-list-view/QtClassifiedListViewAPI.ts +115 -0
- package/rules/.source/quicktvui/src/classified-list-view/core/QTClassifiedListViewItem.ts +11 -0
- package/rules/.source/quicktvui/src/classified-list-view/core/QTClassifiedListViewItemDecoration.ts +7 -0
- package/rules/.source/quicktvui/src/classified-list-view/core/QTIClassifiedListView.ts +18 -0
- package/rules/.source/quicktvui/src/classified-list-view/index.vue +520 -0
- package/rules/.source/quicktvui/src/collapse/QtCollapseAPI.ts +60 -0
- package/rules/.source/quicktvui/src/collapse/core/QTCollapse.ts +13 -0
- package/rules/.source/quicktvui/src/collapse/core/QTCollapseItem.ts +7 -0
- package/rules/.source/quicktvui/src/collapse/core/QTICollapse.ts +15 -0
- package/rules/.source/quicktvui/src/collapse/core/QTICollapseItem.ts +5 -0
- package/rules/.source/quicktvui/src/collapse/index.vue +337 -0
- package/rules/.source/quicktvui/src/column/QTIColumn.ts +3 -0
- package/rules/.source/quicktvui/src/column/QtColumnAPI.ts +9 -0
- package/rules/.source/quicktvui/src/column/index.vue +29 -0
- package/rules/.source/quicktvui/src/core/QTEventData.ts +4 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleBackground.ts +4 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleCoordinate.ts +5 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleDecoration.ts +7 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleGradientBackground.ts +6 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleMargin.ts +8 -0
- package/rules/.source/quicktvui/src/core/QTFlexStylePadding.ts +8 -0
- package/rules/.source/quicktvui/src/core/QTFlexStylePosition.ts +7 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleSize.ts +6 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleSpacing.ts +4 -0
- package/rules/.source/quicktvui/src/core/QTFlexStyleText.ts +5 -0
- package/rules/.source/quicktvui/src/core/QTFocusable.ts +5 -0
- package/rules/.source/quicktvui/src/core/QTLocation.ts +4 -0
- package/rules/.source/quicktvui/src/core/QTNativeParams.ts +22 -0
- package/rules/.source/quicktvui/src/core/QTPosition.ts +4 -0
- package/rules/.source/quicktvui/src/core/QTVisibility.ts +5 -0
- package/rules/.source/quicktvui/src/dialog/QTDialog.ts +28 -0
- package/rules/.source/quicktvui/src/dialog/QTIDialog.ts +3 -0
- package/rules/.source/quicktvui/src/file-browse/QTFileBrowse.ts +76 -0
- package/rules/.source/quicktvui/src/file-browse/QTIFileBrowse.ts +13 -0
- package/rules/.source/quicktvui/src/focus/QTDescendantFocusability.ts +5 -0
- package/rules/.source/quicktvui/src/focus/QTFocusDescendant.ts +5 -0
- package/rules/.source/quicktvui/src/focus/QTFocusDirection.ts +8 -0
- package/rules/.source/quicktvui/src/focus/QTFocusDirectionName.ts +7 -0
- package/rules/.source/quicktvui/src/gradient/QTGradient.ts +14 -0
- package/rules/.source/quicktvui/src/gradient/QTGradientOrientation.ts +10 -0
- package/rules/.source/quicktvui/src/gradient/QTGradientShape.ts +6 -0
- package/rules/.source/quicktvui/src/gradient/QTGradientType.ts +5 -0
- package/rules/.source/quicktvui/src/grid-view/QtGridViewAPI.ts +121 -0
- package/rules/.source/quicktvui/src/grid-view/README.md +93 -0
- package/rules/.source/quicktvui/src/grid-view/core/QTGridViewItem.ts +4 -0
- package/rules/.source/quicktvui/src/grid-view/core/QTGridViewItemDecoration.ts +7 -0
- package/rules/.source/quicktvui/src/grid-view/core/QTGridViewItemFunctionParams.ts +7 -0
- package/rules/.source/quicktvui/src/grid-view/core/QTIGridView.ts +23 -0
- package/rules/.source/quicktvui/src/grid-view/index.vue +390 -0
- package/rules/.source/quicktvui/src/image/QTIImage.ts +8 -0
- package/rules/.source/quicktvui/src/image/QTImageResizeMode.ts +7 -0
- package/rules/.source/quicktvui/src/image/QtImageAPI.ts +54 -0
- package/rules/.source/quicktvui/src/image/index.vue +33 -0
- package/rules/.source/quicktvui/src/index.ts +404 -0
- package/rules/.source/quicktvui/src/list/QTIBaseListView.ts +144 -0
- package/rules/.source/quicktvui/src/list/QTListInitPosition.ts +15 -0
- package/rules/.source/quicktvui/src/list/QtBaseListViewAPI.ts +930 -0
- package/rules/.source/quicktvui/src/list/useBaseListView.ts +454 -0
- package/rules/.source/quicktvui/src/list/useListView.ts +294 -0
- package/rules/.source/quicktvui/src/list-indicator/QTIndicatorListViewComponent.ts +553 -0
- package/rules/.source/quicktvui/src/list-indicator/QtIndicatorViewAPI.ts +114 -0
- package/rules/.source/quicktvui/src/list-indicator/core/QTIIndicatorView.ts +21 -0
- package/rules/.source/quicktvui/src/list-item/ESListItemComponent.ts +86 -0
- package/rules/.source/quicktvui/src/list-item/QTIListItem.ts +14 -0
- package/rules/.source/quicktvui/src/list-item/QtListItemAPI.ts +107 -0
- package/rules/.source/quicktvui/src/list-view/QTListViewComponent.ts +389 -0
- package/rules/.source/quicktvui/src/list-view/QtListViewAPI.ts +101 -0
- package/rules/.source/quicktvui/src/list-view/core/QTIListView.ts +19 -0
- package/rules/.source/quicktvui/src/list-view/core/QTListViewItem.ts +12 -0
- package/rules/.source/quicktvui/src/list-view/core/QTListViewItemDecoration.ts +7 -0
- package/rules/.source/quicktvui/src/list-view/core/QTListViewItemFunctionParams.ts +7 -0
- package/rules/.source/quicktvui/src/list-view/core/QTListViewItemState.ts +8 -0
- package/rules/.source/quicktvui/src/loading/QTILoadingView.ts +3 -0
- package/rules/.source/quicktvui/src/loading/QTLoadingView.ts +25 -0
- package/rules/.source/quicktvui/src/loading/QtLoadingAPI.ts +9 -0
- package/rules/.source/quicktvui/src/long-image/QTILongImage.ts +68 -0
- package/rules/.source/quicktvui/src/long-image/QTLongImage.ts +442 -0
- package/rules/.source/quicktvui/src/long-image/QTLongImageEventBean.ts +62 -0
- package/rules/.source/quicktvui/src/long-image/QTLongImageOrientation.ts +19 -0
- package/rules/.source/quicktvui/src/long-image/QTLongImagePositionType.ts +5 -0
- package/rules/.source/quicktvui/src/long-image/QTLongImageScaleType.ts +9 -0
- package/rules/.source/quicktvui/src/long-image/QtLongImageAPI.ts +9 -0
- package/rules/.source/quicktvui/src/long-image/index.vue +397 -0
- package/rules/.source/quicktvui/src/lottie/QTILottieView.ts +62 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieAsyncUpdates.ts +5 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieEvent.ts +5 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieRenderMode.ts +5 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieRepeatMode.ts +5 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieView.android.ts +207 -0
- package/rules/.source/quicktvui/src/lottie/QTLottieView.harmony.ts +207 -0
- package/rules/.source/quicktvui/src/lottie/QtLottieViewAPI.ts +586 -0
- package/rules/.source/quicktvui/src/nav-bar/QTINavBar.ts +11 -0
- package/rules/.source/quicktvui/src/nav-bar/QTNavBar.ts +9 -0
- package/rules/.source/quicktvui/src/nav-bar/QTNavBarItem.ts +9 -0
- package/rules/.source/quicktvui/src/nav-bar/QTNavBarItemType.ts +3 -0
- package/rules/.source/quicktvui/src/nav-bar/QtNavBarAPI.ts +36 -0
- package/rules/.source/quicktvui/src/nav-bar/index.vue +220 -0
- package/rules/.source/quicktvui/src/plugin/QTIPluginView.ts +11 -0
- package/rules/.source/quicktvui/src/plugin/QTPluginView.ts +49 -0
- package/rules/.source/quicktvui/src/plugin/QtPluginViewAPI.ts +44 -0
- package/rules/.source/quicktvui/src/poster/QtPosterAPI.ts +9 -0
- package/rules/.source/quicktvui/src/poster/core/QTIPoster.ts +3 -0
- package/rules/.source/quicktvui/src/poster/core/QTPoster.ts +32 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterCorner.ts +9 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterElement.ts +8 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterImage.ts +7 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterPlaceholderImg.ts +4 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterRipple.ts +10 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterScore.ts +14 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterShadow.ts +4 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterShimmer.ts +4 -0
- package/rules/.source/quicktvui/src/poster/core/QTPosterTitle.ts +17 -0
- package/rules/.source/quicktvui/src/poster/index.vue +279 -0
- package/rules/.source/quicktvui/src/poster/qt-poster-corner-title.vue +69 -0
- package/rules/.source/quicktvui/src/poster/qt-poster-focus-title.vue +113 -0
- package/rules/.source/quicktvui/src/progressbar/QTIProgressBar.ts +264 -0
- package/rules/.source/quicktvui/src/progressbar/QTProgressBar.ts +1284 -0
- package/rules/.source/quicktvui/src/progressbar/QtProgressBarAPI.ts +2637 -0
- package/rules/.source/quicktvui/src/qrcode/QTIQRCode.ts +3 -0
- package/rules/.source/quicktvui/src/qrcode/QTQRCodeView.ts +24 -0
- package/rules/.source/quicktvui/src/qrcode/QtQRCodeAPI.ts +9 -0
- package/rules/.source/quicktvui/src/qt/QtAPI.ts +337 -0
- package/rules/.source/quicktvui/src/qt/QtAPIModule.ts +3 -0
- package/rules/.source/quicktvui/src/qt/warning.ts +9 -0
- package/rules/.source/quicktvui/src/qtListen/README.md +76 -0
- package/rules/.source/quicktvui/src/qtListen/effect.ts +141 -0
- package/rules/.source/quicktvui/src/qtListen/index.ts +11 -0
- package/rules/.source/quicktvui/src/qtListen/qtArray.ts +156 -0
- package/rules/.source/quicktvui/src/qtListen/qtDiff.ts +143 -0
- package/rules/.source/quicktvui/src/qtListen/reactive.ts +205 -0
- package/rules/.source/quicktvui/src/qtListen/ref.ts +98 -0
- package/rules/.source/quicktvui/src/qtListen/types.ts +311 -0
- package/rules/.source/quicktvui/src/qtListen/watch.ts +233 -0
- package/rules/.source/quicktvui/src/replace-child/QTIReplaceChildView.ts +5 -0
- package/rules/.source/quicktvui/src/replace-child/QTReplaceChildView.ts +30 -0
- package/rules/.source/quicktvui/src/replace-child/QtReplaceChildViewAPI.ts +37 -0
- package/rules/.source/quicktvui/src/row/QTIRow.ts +3 -0
- package/rules/.source/quicktvui/src/row/QtRowAPI.ts +9 -0
- package/rules/.source/quicktvui/src/row/index.vue +29 -0
- package/rules/.source/quicktvui/src/scroll-view/QTIScrollView.ts +7 -0
- package/rules/.source/quicktvui/src/scroll-view/QTScrollView.ts +45 -0
- package/rules/.source/quicktvui/src/scroll-view/QtScrollViewAPI.ts +62 -0
- package/rules/.source/quicktvui/src/section/index.vue +40 -0
- package/rules/.source/quicktvui/src/seekbar/QTISeekBar.ts +277 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBar.ts +1380 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarGravity.ts +5 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarIndicatorMode.ts +6 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarMode.ts +4 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarTickMarkGravity.ts +5 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarTickMarkLayoutGravity.ts +4 -0
- package/rules/.source/quicktvui/src/seekbar/QTSeekBarTickMarkMode.ts +4 -0
- package/rules/.source/quicktvui/src/seekbar/QtSeekBarAPI.ts +2645 -0
- package/rules/.source/quicktvui/src/series/DataAdapter.ts +329 -0
- package/rules/.source/quicktvui/src/series/QTIMediaSeries.ts +33 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeries.ts +9 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesData.ts +9 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesDataStyle.ts +4 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesEvent.ts +7 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesGroup.ts +8 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesGroupStyle.ts +58 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesStyleType.ts +5 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesType.ts +8 -0
- package/rules/.source/quicktvui/src/series/QTMediaSeriesVip.ts +4 -0
- package/rules/.source/quicktvui/src/series/QtMediaSeriesAPI.ts +140 -0
- package/rules/.source/quicktvui/src/series/component/media-series.vue +160 -0
- package/rules/.source/quicktvui/src/series/index.vue +316 -0
- package/rules/.source/quicktvui/src/series/item/media-series-number-item.vue +212 -0
- package/rules/.source/quicktvui/src/series/item/media-series-text-item.vue +239 -0
- package/rules/.source/quicktvui/src/tab/QTITab.ts +163 -0
- package/rules/.source/quicktvui/src/tab/QTTab.ts +8 -0
- package/rules/.source/quicktvui/src/tab/QTTabDataManager.ts +620 -0
- package/rules/.source/quicktvui/src/tab/QTTabEvent.ts +11 -0
- package/rules/.source/quicktvui/src/tab/QTTabEventParams.ts +12 -0
- package/rules/.source/quicktvui/src/tab/QTTabIndex.ts +8 -0
- package/rules/.source/quicktvui/src/tab/QTTabItem.ts +5 -0
- package/rules/.source/quicktvui/src/tab/QTTabItemType.ts +3 -0
- package/rules/.source/quicktvui/src/tab/QTTabPage.ts +5 -0
- package/rules/.source/quicktvui/src/tab/QTTabPageData.ts +11 -0
- package/rules/.source/quicktvui/src/tab/QTTabPageDataState.ts +8 -0
- package/rules/.source/quicktvui/src/tab/QTTabPageState.ts +8 -0
- package/rules/.source/quicktvui/src/tab/QtTabAPI.ts +578 -0
- package/rules/.source/quicktvui/src/tab/index.vue +1561 -0
- package/rules/.source/quicktvui/src/tab/useQtTabWatch.ts +203 -0
- package/rules/.source/quicktvui/src/text/QTIText.ts +12 -0
- package/rules/.source/quicktvui/src/text/QTTextSpan.ts +6 -0
- package/rules/.source/quicktvui/src/text/QTTextSpanAttribute.ts +6 -0
- package/rules/.source/quicktvui/src/text/QTTextSpanAttributeType.ts +4 -0
- package/rules/.source/quicktvui/src/text/QtTextAPI.ts +90 -0
- package/rules/.source/quicktvui/src/text/index.vue +44 -0
- package/rules/.source/quicktvui/src/theme/button.css +195 -0
- package/rules/.source/quicktvui/src/typings/shims-vue.d.ts +6 -0
- package/rules/.source/quicktvui/src/ul/QTIUL.ts +34 -0
- package/rules/.source/quicktvui/src/ul/QTULInitPosition.ts +3 -0
- package/rules/.source/quicktvui/src/ul/QtULAPI.ts +232 -0
- package/rules/.source/quicktvui/src/utils/QtVirtualViewAPI.ts +32 -0
- package/rules/.source/quicktvui/src/utils/VirtualView.ts +124 -0
- package/rules/.source/quicktvui/src/utils/functions.ts +1 -0
- package/rules/.source/quicktvui/src/utils/index.ts +3 -0
- package/rules/.source/quicktvui/src/utils/make-installer.ts +16 -0
- package/rules/.source/quicktvui/src/utils/objects.ts +4 -0
- package/rules/.source/quicktvui/src/utils/type.ts +1 -0
- package/rules/.source/quicktvui/src/utils/types.ts +42 -0
- package/rules/.source/quicktvui/src/utils/utils.ts +62 -0
- package/rules/.source/quicktvui/src/utils/vue/index.ts +3 -0
- package/rules/.source/quicktvui/src/utils/vue/install.ts +48 -0
- package/rules/.source/quicktvui/src/utils/vue/props/index.ts +3 -0
- package/rules/.source/quicktvui/src/utils/vue/props/runtime.ts +129 -0
- package/rules/.source/quicktvui/src/utils/vue/props/types.ts +165 -0
- package/rules/.source/quicktvui/src/utils/vue/props/util.ts +10 -0
- package/rules/.source/quicktvui/src/utils/vue/typescript.ts +9 -0
- package/rules/.source/quicktvui/src/view/QTIView.ts +3 -0
- package/rules/.source/quicktvui/src/view/QTIViewVisibility.ts +5 -0
- package/rules/.source/quicktvui/src/view/QTViewEvent.ts +3 -0
- package/rules/.source/quicktvui/src/view/QTViewState.ts +12 -0
- package/rules/.source/quicktvui/src/view/QtViewAPI.ts +9 -0
- package/rules/.source/quicktvui/src/view/index.vue +24 -0
- package/rules/.source/quicktvui/src/waterfall/QtWaterfallAPI.ts +219 -0
- package/rules/.source/quicktvui/src/waterfall/README.md +143 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTIWaterfall.ts +49 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTScrollState.ts +5 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfall.ts +13 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallCardItem.ts +11 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallCardPlaceHolder.ts +10 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallCardSection.ts +12 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallDataAdapter.ts +195 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallDataManager.ts +305 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallEvent.ts +11 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallFlexStyle.ts +19 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallIndex.ts +7 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallItem.ts +9 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallItemType.ts +7 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallPlaceholder.ts +5 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallPluginItem.ts +9 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallPluginSection.ts +8 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallSection.ts +17 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallSectionType.ts +14 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallTabItem.ts +10 -0
- package/rules/.source/quicktvui/src/waterfall/core/QTWaterfallVisibleType.ts +7 -0
- package/rules/.source/quicktvui/src/waterfall/index.vue +704 -0
- package/rules/.source/quicktvui/src/waterfall/item/card-item.vue +49 -0
- package/rules/.source/quicktvui/src/waterfall/item/plugin-item.vue +52 -0
- package/rules/.source/quicktvui/src/waterfall/section/blank-section.vue +27 -0
- package/rules/.source/quicktvui/src/waterfall/section/card-section.vue +81 -0
- package/rules/.source/quicktvui/src/waterfall/section/end-section.vue +50 -0
- package/rules/.source/quicktvui/src/waterfall/section/flex-section.vue +167 -0
- package/rules/.source/quicktvui/src/waterfall/section/list-section.vue +247 -0
- package/rules/.source/quicktvui/src/waterfall/section/loading-section.vue +34 -0
- package/rules/.source/quicktvui/src/waterfall/section/plugin-section.vue +87 -0
- package/rules/.source/quicktvui/src/waterfall/section/section-title.vue +63 -0
- package/rules/.source/quicktvui/src/waterfall/section/vue-section.vue +44 -0
- package/rules/.source/quicktvui/src/webview/QTIWebView.ts +199 -0
- package/rules/.source/quicktvui/src/webview/QTWebView.ts +957 -0
- package/rules/.source/quicktvui/src/webview/QTWebViewInterceptRule.ts +4 -0
- package/rules/.source/quicktvui/src/webview/QTWebViewLayerType.ts +6 -0
- package/rules/.source/quicktvui/src/webview/QTWebViewSniffingRule.ts +18 -0
- package/rules/.source/quicktvui/src/webview/QtWebViewAPI.ts +1963 -0
- package/rules/.source/quicktvui/src/x5webview/QTIX5WebView.ts +211 -0
- package/rules/.source/quicktvui/src/x5webview/QTX5WebView.ts +1014 -0
- package/rules/.source/quicktvui/src/x5webview/QTX5WebViewInterceptRule.ts +4 -0
- package/rules/.source/quicktvui/src/x5webview/QTX5WebViewLayerType.ts +6 -0
- package/rules/.source/quicktvui/src/x5webview/QTX5WebViewSniffingRule.ts +18 -0
- package/rules/.source/quicktvui/src/x5webview/QtX5WebViewAPI.ts +2015 -0
- package/rules/.source/quicktvui/tsconfig.json +34 -0
- package/rules/.source/quicktvui/web-types.json +1 -0
- package/rules/.source/quicktvui/yarn.lock +72 -0
- package/rules/.source/web/audio/index.ts +9 -0
- package/rules/.source/web/audio/src/audio.ts +34 -0
- package/rules/.source/web/audio/src/audio.vue +146 -0
- package/rules/.source/web/audio/src/instance.ts +3 -0
- package/rules/.source/web/audio-service/index.ts +10 -0
- package/rules/.source/web/audio-service/src/audio-service.ts +34 -0
- package/rules/.source/web/audio-service/src/audio-service.vue +115 -0
- package/rules/.source/web/audio-service/src/instance.ts +3 -0
- package/rules/.source/web/base/index.ts +1 -0
- package/rules/.source/web/base/src/base-types.ts +1 -0
- package/rules/.source/web/component.ts +25 -0
- package/rules/.source/web/docs/h.txt +6 -0
- package/rules/.source/web/docs/video.txt +88 -0
- package/rules/.source/web/h1/index.ts +9 -0
- package/rules/.source/web/h1/src/h1.ts +9 -0
- package/rules/.source/web/h1/src/h1.vue +30 -0
- package/rules/.source/web/h1/src/instance.ts +3 -0
- package/rules/.source/web/h2/index.ts +9 -0
- package/rules/.source/web/h2/src/h2.ts +9 -0
- package/rules/.source/web/h2/src/h2.vue +30 -0
- package/rules/.source/web/h2/src/instance.ts +3 -0
- package/rules/.source/web/h3/index.ts +9 -0
- package/rules/.source/web/h3/src/h3.ts +9 -0
- package/rules/.source/web/h3/src/h3.vue +30 -0
- package/rules/.source/web/h3/src/instance.ts +3 -0
- package/rules/.source/web/h4/index.ts +9 -0
- package/rules/.source/web/h4/src/h4.ts +9 -0
- package/rules/.source/web/h4/src/h4.vue +30 -0
- package/rules/.source/web/h4/src/instance.ts +3 -0
- package/rules/.source/web/h5/index.ts +9 -0
- package/rules/.source/web/h5/src/h5.ts +9 -0
- package/rules/.source/web/h5/src/h5.vue +30 -0
- package/rules/.source/web/h5/src/instance.ts +3 -0
- package/rules/.source/web/h6/index.ts +9 -0
- package/rules/.source/web/h6/src/h6.ts +9 -0
- package/rules/.source/web/h6/src/h6.vue +30 -0
- package/rules/.source/web/h6/src/instance.ts +3 -0
- package/rules/.source/web/index.ts +84 -0
- package/rules/.source/web/package.json +24 -0
- package/rules/.source/web/plugin.ts +3 -0
- package/rules/.source/web/rollup.config.js +37 -0
- package/rules/.source/web/shims-vue.d.ts +6 -0
- package/rules/.source/web/source/index.ts +9 -0
- package/rules/.source/web/source/src/instance.ts +3 -0
- package/rules/.source/web/source/src/source.ts +17 -0
- package/rules/.source/web/source/src/source.vue +19 -0
- package/rules/.source/web/tsconfig.json +34 -0
- package/rules/.source/web/utils/functions.ts +1 -0
- package/rules/.source/web/utils/index.ts +3 -0
- package/rules/.source/web/utils/make-installer.ts +16 -0
- package/rules/.source/web/utils/objects.ts +4 -0
- package/rules/.source/web/utils/types.ts +42 -0
- package/rules/.source/web/utils/vue/index.ts +3 -0
- package/rules/.source/web/utils/vue/install.ts +48 -0
- package/rules/.source/web/utils/vue/props/index.ts +3 -0
- package/rules/.source/web/utils/vue/props/runtime.ts +129 -0
- package/rules/.source/web/utils/vue/props/types.ts +165 -0
- package/rules/.source/web/utils/vue/props/util.ts +10 -0
- package/rules/.source/web/utils/vue/typescript.ts +9 -0
- package/rules/.source/web/video/index.ts +9 -0
- package/rules/.source/web/video/src/instance.ts +3 -0
- package/rules/.source/web/video/src/video.ts +34 -0
- package/rules/.source/web/video/src/video.vue +171 -0
- package/rules/.windsurfrules +28 -4
- package/rules/AGENTS.md +28 -4
- package/rules/CLAUDE.md +28 -3
- package/rules/GEMINI.md +26 -3
|
@@ -0,0 +1,1608 @@
|
|
|
1
|
+
/* Tencent is pleased to support the open source community by making Hippy available.
|
|
2
|
+
* Copyright (C) 2018 THL A29 Limited, a Tencent company. All rights reserved.
|
|
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
|
+
package com.tencent.mtt.hippy.views.image;
|
|
17
|
+
|
|
18
|
+
import android.content.Context;
|
|
19
|
+
import android.graphics.Bitmap;
|
|
20
|
+
import android.graphics.Canvas;
|
|
21
|
+
import android.graphics.Color;
|
|
22
|
+
import android.graphics.Movie;
|
|
23
|
+
import android.graphics.Rect;
|
|
24
|
+
import android.graphics.drawable.Drawable;
|
|
25
|
+
import android.graphics.drawable.LayerDrawable;
|
|
26
|
+
import android.text.TextUtils;
|
|
27
|
+
import android.util.Log;
|
|
28
|
+
import android.view.MotionEvent;
|
|
29
|
+
import android.view.View;
|
|
30
|
+
|
|
31
|
+
import android.support.annotation.ColorInt;
|
|
32
|
+
import android.support.annotation.NonNull;
|
|
33
|
+
import android.support.annotation.Nullable;
|
|
34
|
+
import android.view.ViewGroup;
|
|
35
|
+
|
|
36
|
+
import com.tencent.extend.AttachInfo;
|
|
37
|
+
import com.tencent.extend.AutoFocusManager;
|
|
38
|
+
import com.tencent.extend.FocusManagerModule;
|
|
39
|
+
import com.tencent.extend.IFloatFocusManager;
|
|
40
|
+
import com.tencent.extend.ITVView;
|
|
41
|
+
import com.tencent.extend.TVFocusScaleExcuter;
|
|
42
|
+
import com.tencent.extend.views.ExtendTag;
|
|
43
|
+
import com.tencent.mtt.hippy.FocusDispatchView;
|
|
44
|
+
import com.tencent.mtt.hippy.HippyEngineContext;
|
|
45
|
+
import com.tencent.mtt.hippy.HippyInstanceContext;
|
|
46
|
+
import com.tencent.mtt.hippy.adapter.image.HippyDrawable;
|
|
47
|
+
import com.tencent.mtt.hippy.adapter.image.HippyImageLoader;
|
|
48
|
+
import com.tencent.mtt.hippy.common.HippyMap;
|
|
49
|
+
import com.tencent.mtt.hippy.dom.node.NodeProps;
|
|
50
|
+
import com.tencent.mtt.hippy.uimanager.ExtendViewGroup;
|
|
51
|
+
import com.tencent.mtt.hippy.uimanager.HippyViewBase;
|
|
52
|
+
import com.tencent.mtt.hippy.uimanager.HippyViewController;
|
|
53
|
+
import com.tencent.mtt.hippy.uimanager.HippyViewEvent;
|
|
54
|
+
import com.tencent.mtt.hippy.uimanager.NativeGestureDispatcher;
|
|
55
|
+
import com.tencent.mtt.hippy.uimanager.RenderNode;
|
|
56
|
+
import com.tencent.mtt.hippy.uimanager.StateView;
|
|
57
|
+
import com.tencent.mtt.hippy.uimanager.ViewStateProvider;
|
|
58
|
+
import com.tencent.mtt.hippy.utils.ExtendUtil;
|
|
59
|
+
import com.tencent.mtt.hippy.utils.LogUtils;
|
|
60
|
+
import com.tencent.mtt.hippy.utils.PixelUtil;
|
|
61
|
+
import com.tencent.mtt.hippy.utils.UrlUtils;
|
|
62
|
+
import com.tencent.mtt.hippy.views.common.CommonBackgroundDrawable;
|
|
63
|
+
import com.tencent.mtt.hippy.views.common.CommonBorder;
|
|
64
|
+
import com.tencent.extend.views.fastlist.ListItemHolder;
|
|
65
|
+
import com.tencent.extend.views.fastlist.PostHandlerView;
|
|
66
|
+
import com.tencent.extend.views.fastlist.PostTaskHolder;
|
|
67
|
+
import com.tencent.mtt.hippy.views.view.CustomLayoutView;
|
|
68
|
+
import com.tencent.mtt.supportui.adapters.image.IDrawableTarget;
|
|
69
|
+
import com.tencent.mtt.supportui.utils.struct.ArrayMap;
|
|
70
|
+
import com.tencent.mtt.supportui.views.asyncimage.AsyncImageView;
|
|
71
|
+
import com.tencent.mtt.supportui.views.asyncimage.BackgroundDrawable;
|
|
72
|
+
import com.tencent.mtt.supportui.views.asyncimage.ContentDrawable;
|
|
73
|
+
|
|
74
|
+
import java.util.Arrays;
|
|
75
|
+
import java.util.HashMap;
|
|
76
|
+
import java.util.Map;
|
|
77
|
+
|
|
78
|
+
@SuppressWarnings({"deprecation", "unused"})
|
|
79
|
+
public class HippyImageView extends AsyncImageView implements CommonBorder, HippyViewBase, ITVView, StateView,
|
|
80
|
+
PostTaskHolder, ListItemHolder, ViewStateProvider {
|
|
81
|
+
|
|
82
|
+
public static final String IMAGE_TYPE_APNG = "apng";
|
|
83
|
+
public static final String IMAGE_TYPE_GIF = "gif";
|
|
84
|
+
public static final String IMAGE_PROPS = "props";
|
|
85
|
+
public static final String IMAGE_VIEW_OBJ = "viewobj";
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
/** zhaopeng**/
|
|
89
|
+
private HippyMap initProps = new HippyMap();
|
|
90
|
+
private boolean mHasSetTempBackgroundColor = false;
|
|
91
|
+
private boolean mUserHasSetBackgroudnColor = false;
|
|
92
|
+
private int mUserSetBackgroundColor = Color.TRANSPARENT;
|
|
93
|
+
|
|
94
|
+
private boolean isAutoFocus = false;
|
|
95
|
+
private boolean isFillParent = false;
|
|
96
|
+
private boolean focusScaleOnDuplicateParentState = false;
|
|
97
|
+
//zhaopeng add roleType
|
|
98
|
+
private RoleType mRoleType = RoleType.UNDEFINE;
|
|
99
|
+
|
|
100
|
+
public enum RoleType {
|
|
101
|
+
UNDEFINE,
|
|
102
|
+
COVER,
|
|
103
|
+
ICON,
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
private IImageStateListener<HippyImageView> mCustomStateListener;
|
|
109
|
+
|
|
110
|
+
public void setCustomImageRequestListener(IImageStateListener mCustomImageRequestListener) {
|
|
111
|
+
this.mCustomStateListener = mCustomImageRequestListener;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
public void setRoleType(RoleType mRoleType) {
|
|
115
|
+
this.mRoleType = mRoleType;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
public RoleType getRoleType() {
|
|
119
|
+
return mRoleType;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
public int getFetchState(){
|
|
123
|
+
return mUrlFetchState;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
public void setFocusScaleOnDuplicateParentState(boolean focusScaleOnDuplicateParentState) {
|
|
127
|
+
this.focusScaleOnDuplicateParentState = focusScaleOnDuplicateParentState;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
@Override
|
|
132
|
+
public void onSetSid(String sid) {
|
|
133
|
+
AutoFocusManager af = AutoFocusManager.findAutoFocusManagerFromRoot(this);
|
|
134
|
+
if(af != null){
|
|
135
|
+
if(af.isNextAutofocus(sid)){
|
|
136
|
+
//setAutoFocus(true,true);
|
|
137
|
+
onRequestAutofocus(this, this, ExtendViewGroup.AUTOFOCUS_TYPE_FORCE);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
@Override
|
|
144
|
+
public boolean isAutoFocus() {
|
|
145
|
+
return isAutoFocus;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
@Override
|
|
149
|
+
public void setAutoFocus(boolean b) {
|
|
150
|
+
setAutoFocus(b,false);
|
|
151
|
+
// if(b && isAttached() && !isFocused()
|
|
152
|
+
// && getWidth() > 0 && getHeight() > 0 && getVisibility() == View.VISIBLE){
|
|
153
|
+
// Log.i(AutoFocusManager.TAG,"auto requestFocus on setAutoFocus this:"+ExtendUtil.debugView(this));
|
|
154
|
+
// //AutoFocusManager.globalRequestFocus(this);
|
|
155
|
+
//// onRequestAutofocus(this,this,ExtendViewGroup.AUTOFOCUS_TYPE_FORCE);
|
|
156
|
+
// }
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
@Override
|
|
160
|
+
public void setAutoFocus(boolean b,boolean requestFocusOnExist) {
|
|
161
|
+
this.isAutoFocus = b;
|
|
162
|
+
if(b) {
|
|
163
|
+
Log.i(AutoFocusManager.TAG, "setAutoFocus true this:"+ExtendUtil.debugView(this)+",requestFocusOnExist "+requestFocusOnExist);
|
|
164
|
+
}
|
|
165
|
+
if(b && requestFocusOnExist && isAttached() && !isFocused()
|
|
166
|
+
&& getWidth() > 0 && getHeight() > 0 && getVisibility() == View.VISIBLE) {
|
|
167
|
+
Log.i(AutoFocusManager.TAG, "auto requestFocus on setAutofocus this:" + ExtendUtil.debugView(this));
|
|
168
|
+
onRequestAutofocus(this, this, ExtendViewGroup.AUTOFOCUS_TYPE_FORCE);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
private boolean skipRequestFocus = false;
|
|
173
|
+
|
|
174
|
+
@Override
|
|
175
|
+
public void setSkipRequestFocus(boolean b) {
|
|
176
|
+
this.skipRequestFocus = b;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
@Override
|
|
180
|
+
public boolean requestFocus(int direction, Rect previouslyFocusedRect) {
|
|
181
|
+
if(skipRequestFocus ||
|
|
182
|
+
(isInTouchMode() && !FocusManagerModule.getGlobalFocusConfig(getHippyContext()).enableFocusableTouchMode)){
|
|
183
|
+
Log.e(FocusDispatchView.TAG,"requestFocus return false on skipRequestFocus this:"+this);
|
|
184
|
+
return false;
|
|
185
|
+
}
|
|
186
|
+
boolean forceDisableFocus = FocusManagerModule.getGlobalFocusConfig(getHippyContext()).forceDisableFocus;
|
|
187
|
+
if(forceDisableFocus){
|
|
188
|
+
return false;
|
|
189
|
+
}
|
|
190
|
+
return super.requestFocus(direction, previouslyFocusedRect);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
protected HippyEngineContext getHippyContext() {
|
|
194
|
+
return ((HippyInstanceContext) getContext()).getEngineContext();
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
//zhaopeng add
|
|
198
|
+
// private final BorderFrontDrawable focusFrontDrawable;
|
|
199
|
+
|
|
200
|
+
protected PostHandlerView mPostView;
|
|
201
|
+
private boolean onBindNew = false;
|
|
202
|
+
private boolean enablePostTask = false;
|
|
203
|
+
private boolean shouldBindReset = true;
|
|
204
|
+
//border相关配置本地变量
|
|
205
|
+
private boolean isBorderVisible;
|
|
206
|
+
private boolean isBlackRectEnable;
|
|
207
|
+
private int borderColor;
|
|
208
|
+
private float borderCorner;
|
|
209
|
+
private int borderWidth;
|
|
210
|
+
private int globalVisibility = View.VISIBLE;
|
|
211
|
+
|
|
212
|
+
public void setEnablePostTask(boolean enablePostTask) {
|
|
213
|
+
this.enablePostTask = enablePostTask;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
@Override
|
|
218
|
+
public void setRootPostHandlerView(PostHandlerView pv) {
|
|
219
|
+
this.mPostView = pv;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
private int getPostType() {
|
|
223
|
+
return hashCode();
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
// @Override
|
|
227
|
+
// protected void onWindowVisibilityChanged(int visibility) {
|
|
228
|
+
//
|
|
229
|
+
// }
|
|
230
|
+
|
|
231
|
+
@Override
|
|
232
|
+
public void onResetBeforeCache() {
|
|
233
|
+
if (isPostTaskEnabled()) {
|
|
234
|
+
|
|
235
|
+
mPostView.clearTask(POST_TASK_CATEGORY_IMG, getPostType());
|
|
236
|
+
}
|
|
237
|
+
if (LogUtils.isDebug()) {
|
|
238
|
+
Log.i("HippyImage", "onResetBeforeCache this:" + this);
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
if (mCustomStateList != null && !mCustomStateList.isEmpty()) {
|
|
242
|
+
//mCustomStateList.clear();
|
|
243
|
+
for(String key:mCustomStateList.keySet()){
|
|
244
|
+
setCustomState(key,false);
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
// setAutoFocus(false);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
protected boolean isPostTaskEnabled() {
|
|
251
|
+
return enablePostTask && mPostView != null;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
@Override
|
|
255
|
+
protected void onVisibilityChanged(@NonNull View changedView, int visibility) {
|
|
256
|
+
super.onVisibilityChanged(changedView, visibility);
|
|
257
|
+
// if(LogUtils.isDebug()) {
|
|
258
|
+
// Log.i(AutoFocusManager.TAG,"div on view onVisibilityChanged visibility:"+visibility+",changedView:"+ExtendUtil.debugViewLite(changedView)+",hasFocus:"+changedView.hasFocus());
|
|
259
|
+
// if(changedView == getRootView()){
|
|
260
|
+
// Log.e(AutoFocusManager.TAG,"onVisibilityChanged on rootView visibility:"+visibility+",changedView:"+ExtendUtil.debugView(changedView));
|
|
261
|
+
// }
|
|
262
|
+
// }
|
|
263
|
+
// Log.v(AutoFocusManager.TAG,"onWindowVisibilityChanged visibility:"+visibility+",this:"+ExtendUtil.debugView(this));
|
|
264
|
+
globalVisibility = visibility;
|
|
265
|
+
if(AutoFocusManager.isAutofocusView(this) && visibility == View.VISIBLE){
|
|
266
|
+
if(changedView != getRootView()) {//这里如果是decorView,证明是activity之间的切换,理论上来说,不需要再次请求焦点
|
|
267
|
+
if (getWidth() > 0 && getHeight() > 0) {
|
|
268
|
+
if (LogUtils.isDebug()) {
|
|
269
|
+
Log.i(AutoFocusManager.TAG, "auto requestFocus on onWindowVisibilityChanged ,view:" + ExtendUtil.debugView(this));
|
|
270
|
+
}
|
|
271
|
+
onRequestAutofocus(this, this, ExtendViewGroup.AUTOFOCUS_TYPE_VISIBILITY);
|
|
272
|
+
} else {
|
|
273
|
+
Log.e(AutoFocusManager.TAG, "auto requestFocus return on onWindowVisibilityChanged ,view size invalid:" + ExtendUtil.debugView(this));
|
|
274
|
+
}
|
|
275
|
+
}else if(LogUtils.isDebug()){
|
|
276
|
+
Log.e(AutoFocusManager.TAG,"auto requestFocus return on rootView changed:"+ExtendUtil.debugView(changedView));
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
// if(visibility == View.VISIBLE) {
|
|
280
|
+
// if(getWidth() <1 || getHeight() < 1){
|
|
281
|
+
// Log.e(AutoFocusManager.TAG, "------onVisibilityChanged this:" + this + ",isAttached:" + isAttached() + ",width:" + getWidth());
|
|
282
|
+
// }else {
|
|
283
|
+
// Log.v(AutoFocusManager.TAG, "------onVisibilityChanged this:" + this + ",isAttached:" + isAttached() + ",width:" + getWidth());
|
|
284
|
+
// }
|
|
285
|
+
// }else{
|
|
286
|
+
// Log.e(AutoFocusManager.TAG, "------onVisibilityChanged to false this:" + this + ",isAttached:" + isAttached() + ",width:" + getWidth());
|
|
287
|
+
// }
|
|
288
|
+
// if(visibility == View.VISIBLE && (AutoFocusManager.isAutofocusView(this)) && getWidth() > 0 && getHeight() > 0){
|
|
289
|
+
// Log.i(AutoFocusManager.TAG,"auto requestFocus on onVisibilityChanged this:"+this);
|
|
290
|
+
// //AutoFocusManager.globalRequestFocus(this);
|
|
291
|
+
// onRequestAutofocus(this,this,ExtendViewGroup.AUTOFOCUS_TYPE_VISIBILITY);
|
|
292
|
+
// }
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
@Override
|
|
296
|
+
protected void postTask(Runnable task, int delayLoad) {
|
|
297
|
+
if (isPostTaskEnabled()) {
|
|
298
|
+
if (LogUtils.isDebug()) {
|
|
299
|
+
Log.i("HippyImage", "postTask by postView:" + hashCode() + ",url:" + getUrl() + ",task:" + task.hashCode() + ",mPostView:" + ((View) mPostView).getId());
|
|
300
|
+
}
|
|
301
|
+
mPostView.clearTask(POST_TASK_CATEGORY_IMG, getPostType());
|
|
302
|
+
mPostView.postTask(POST_TASK_CATEGORY_IMG, getPostType(), task, delayLoad);
|
|
303
|
+
} else {
|
|
304
|
+
if (LogUtils.isDebug()) {
|
|
305
|
+
Log.i("HippyImage", "postTask by super:" + this);
|
|
306
|
+
}
|
|
307
|
+
super.postTask(task, delayLoad);
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
/**
|
|
312
|
+
* 新增beforeItemBind方法,onItemBind前逻辑处理
|
|
313
|
+
*
|
|
314
|
+
* @param url bind的图片url
|
|
315
|
+
*/
|
|
316
|
+
public void beforeItemBind(Object url) {
|
|
317
|
+
if (LogUtils.isDebug()) {
|
|
318
|
+
Log.e("HippyImage", "beforeItemBind:" + hashCode() + ",url:" + url);
|
|
319
|
+
}
|
|
320
|
+
shouldBindReset = !(url instanceof String) || !TextUtils.equals(getUrl(), (String) url);
|
|
321
|
+
//setAutoFocus(false);
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
|
|
326
|
+
@Override
|
|
327
|
+
public void onItemBind() {
|
|
328
|
+
if (LogUtils.isDebug()) {
|
|
329
|
+
Log.e("HippyImage", "onItemBind:" + hashCode() + ",url:" + getUrl());
|
|
330
|
+
}
|
|
331
|
+
if (isPostTaskEnabled() && shouldBindReset) {
|
|
332
|
+
//resetContent();
|
|
333
|
+
// mOldDrawable = getBackground();
|
|
334
|
+
if (mBGDrawable != null) {
|
|
335
|
+
setBackgroundDrawable(mBGDrawable);
|
|
336
|
+
} else {
|
|
337
|
+
setBackgroundDrawable(null);
|
|
338
|
+
}
|
|
339
|
+
invalidate();
|
|
340
|
+
onBindNew = true;
|
|
341
|
+
mPostView.clearTask(POST_TASK_CATEGORY_IMG, getPostType());
|
|
342
|
+
}
|
|
343
|
+
shouldBindReset = true;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
//zhaopeng
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* 播放GIF动画的关键类
|
|
350
|
+
*/
|
|
351
|
+
private Movie mGifMovie;
|
|
352
|
+
private int mGifStartX = 0;
|
|
353
|
+
private int mGifStartY = 0;
|
|
354
|
+
private float mGifScaleX = 1;
|
|
355
|
+
private float mGifScaleY = 1;
|
|
356
|
+
private boolean mGifMatrixComputed = false;
|
|
357
|
+
private int mGifProgress = 0;
|
|
358
|
+
private long mGifLastPlayTime = -1;
|
|
359
|
+
private boolean selectState = false;
|
|
360
|
+
|
|
361
|
+
@Override
|
|
362
|
+
public void resetProps() {
|
|
363
|
+
HippyViewController.resetTransform(this);
|
|
364
|
+
setAlpha(1.0f);
|
|
365
|
+
mTintColor = 0;
|
|
366
|
+
mBGDrawable = null;
|
|
367
|
+
mContentDrawable = null;
|
|
368
|
+
mScaleType = AsyncImageView.ScaleType.FIT_XY;
|
|
369
|
+
setImagePositionX(0);
|
|
370
|
+
setImagePositionY(0);
|
|
371
|
+
setAutoFocus(false);
|
|
372
|
+
mUrl = null;
|
|
373
|
+
mImageType = null;
|
|
374
|
+
setBackgroundDrawable(null);
|
|
375
|
+
if (mCustomStateList != null && !mCustomStateList.isEmpty()) {
|
|
376
|
+
//mCustomStateList.clear();
|
|
377
|
+
for(String key:mCustomStateList.keySet()){
|
|
378
|
+
setCustomState(key,false);
|
|
379
|
+
}
|
|
380
|
+
}
|
|
381
|
+
// LogUtils.v("HippyDrawable","resetProps ,this:"+this);
|
|
382
|
+
Arrays.fill(mShouldSendImageEvent, false);
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
@Override
|
|
386
|
+
public void clear() {
|
|
387
|
+
//先解决图片绘制黑屏的问题。 更完全的改法是调用resetProps.
|
|
388
|
+
mTintColor = 0;
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
/**zhaopeng add*/
|
|
393
|
+
// protected PostHandlerView mPostHandlerView;
|
|
394
|
+
// protected boolean enablePostTask = false;
|
|
395
|
+
// @Override
|
|
396
|
+
// public void setRootPostHandlerView(PostHandlerView pv) {
|
|
397
|
+
// this.mPostHandlerView = pv;
|
|
398
|
+
// }
|
|
399
|
+
// protected boolean isPostTaskEnabled(){
|
|
400
|
+
// return mPostHandlerView != null && enablePostTask;
|
|
401
|
+
// }
|
|
402
|
+
|
|
403
|
+
/**
|
|
404
|
+
* zhaopeng add end
|
|
405
|
+
*/
|
|
406
|
+
|
|
407
|
+
public enum ImageEvent {
|
|
408
|
+
ONLOAD,
|
|
409
|
+
ONLOAD_START,
|
|
410
|
+
ONLOAD_END,
|
|
411
|
+
ONERROR
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
protected NativeGestureDispatcher mGestureDispatcher;
|
|
415
|
+
|
|
416
|
+
private OnLoadEvent mOnLoadEvent;
|
|
417
|
+
private OnLoadEndEvent mOnLoadEndEvent;
|
|
418
|
+
private OnErrorEvent mOnErrorEvent;
|
|
419
|
+
private OnLoadStartEvent mOnLoadStartEvent;
|
|
420
|
+
private final boolean[] mShouldSendImageEvent;
|
|
421
|
+
private Rect mNinePatchRect;
|
|
422
|
+
private final HippyEngineContext hippyEngineContext;
|
|
423
|
+
|
|
424
|
+
public HippyImageView(Context context) {
|
|
425
|
+
super(context);
|
|
426
|
+
mShouldSendImageEvent = new boolean[ImageEvent.values().length];
|
|
427
|
+
hippyEngineContext = ((HippyInstanceContext) context).getEngineContext();
|
|
428
|
+
if (hippyEngineContext != null) {
|
|
429
|
+
setImageAdapter(hippyEngineContext.getGlobalConfigs().getImageLoaderAdapter());
|
|
430
|
+
//自定义borderDrawable
|
|
431
|
+
this.borderType = hippyEngineContext.getGlobalConfigs().getEsBaseConfigManager().getFocusBorderType();
|
|
432
|
+
setBorderDrawable(hippyEngineContext.getGlobalConfigs().getBorderDrawableProvider().create());
|
|
433
|
+
}
|
|
434
|
+
//zhaopeng addsetBlackRectEnable
|
|
435
|
+
// focusFrontDrawable = new BorderFrontDrawable();
|
|
436
|
+
// focusFrontDrawable.setBorderVisible(false);
|
|
437
|
+
// focusFrontDrawable.setBlackRectEnable(FocusManagerModule.defaultFocusBorderInnerRectEnable);
|
|
438
|
+
// focusFrontDrawable.setVisible(false, false);
|
|
439
|
+
FocusManagerModule.GlobalFocusConfig focusConfig = FocusManagerModule.getGlobalFocusConfig(hippyEngineContext);
|
|
440
|
+
if (borderDrawable != null) {
|
|
441
|
+
borderDrawable.setBorderVisible(false);
|
|
442
|
+
borderDrawable.setCallback(this);
|
|
443
|
+
borderDrawable.setBlackRectEnable(focusConfig.defaultFocusBorderInnerRectEnable);
|
|
444
|
+
borderDrawable.setVisible(false, false);
|
|
445
|
+
}
|
|
446
|
+
setBlackRectEnable(focusConfig.defaultFocusBorderInnerRectEnable);
|
|
447
|
+
setFocusBorderColor(focusConfig.defaultFocusBorderColor);
|
|
448
|
+
setFocusBorderEnable(focusConfig.defaultFocusBorderEnable);
|
|
449
|
+
setFocusBorderCorner(focusConfig.defaultFocusBorderRadius);
|
|
450
|
+
setFocusBorderWidth(focusConfig.defaultFocusBorderWidth);
|
|
451
|
+
setFocusBorderInset(focusConfig.defaultFocusBorderInset);
|
|
452
|
+
if(focusConfig.defaultBlackFocusBorderRadius != -1){
|
|
453
|
+
borderDrawable.setBlackBorderCorner(focusConfig.defaultBlackFocusBorderRadius);
|
|
454
|
+
}
|
|
455
|
+
if(focusConfig.defaultBlackFocusBorderWidth != -1){
|
|
456
|
+
borderDrawable.setBlackBorderWidth(focusConfig.defaultBlackFocusBorderWidth);
|
|
457
|
+
}
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
@Override
|
|
461
|
+
public void invalidateDrawable(@NonNull Drawable dr) {
|
|
462
|
+
super.invalidateDrawable(dr);
|
|
463
|
+
if (borderDrawable != null && dr == borderDrawable) {
|
|
464
|
+
invalidate();
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
public void initBorderDrawable() {
|
|
469
|
+
if (borderDrawable != null) {
|
|
470
|
+
borderDrawable.setBorderVisible(this.isBorderVisible);
|
|
471
|
+
borderDrawable.setCallback(this);
|
|
472
|
+
borderDrawable.setBlackRectEnable(this.isBlackRectEnable);
|
|
473
|
+
borderDrawable.setVisible(false, false);
|
|
474
|
+
borderDrawable.setBorderColor(this.borderColor);
|
|
475
|
+
borderDrawable.setBorderCorner(this.borderCorner);
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
//设置focusDrawable样式
|
|
480
|
+
public void setFocusBorderType(int type) {
|
|
481
|
+
this.borderType = type;
|
|
482
|
+
if (hippyEngineContext != null) {
|
|
483
|
+
setBorderDrawable(hippyEngineContext.getGlobalConfigs().getBorderDrawableProvider().create());
|
|
484
|
+
initBorderDrawable();
|
|
485
|
+
invalidate();
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
//zhaopeng add
|
|
490
|
+
|
|
491
|
+
/**
|
|
492
|
+
* 设置边框颜色
|
|
493
|
+
*
|
|
494
|
+
* @param color
|
|
495
|
+
*/
|
|
496
|
+
public void setFocusBorderColor(@ColorInt int color) {
|
|
497
|
+
if (borderDrawable != null) {
|
|
498
|
+
this.borderColor = color;
|
|
499
|
+
borderDrawable.setBorderColor(color);
|
|
500
|
+
invalidate();
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
/**
|
|
505
|
+
* 设置边框弧度
|
|
506
|
+
*
|
|
507
|
+
* @param
|
|
508
|
+
*/
|
|
509
|
+
public void setFocusBorderCorner(float radius) {
|
|
510
|
+
if (borderDrawable != null) {
|
|
511
|
+
this.borderCorner = radius;
|
|
512
|
+
borderDrawable.setBorderCorner(radius);
|
|
513
|
+
invalidate();
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
|
|
517
|
+
/**
|
|
518
|
+
* 设置边框宽度
|
|
519
|
+
*
|
|
520
|
+
* @param
|
|
521
|
+
*/
|
|
522
|
+
public void setFocusBorderWidth(int width) {
|
|
523
|
+
if (borderDrawable != null && width > -1) {
|
|
524
|
+
this.borderWidth = width;
|
|
525
|
+
borderDrawable.setBorderWidth(width);
|
|
526
|
+
invalidate();
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
/**
|
|
531
|
+
* 设置边框宽度
|
|
532
|
+
*
|
|
533
|
+
* @param
|
|
534
|
+
*/
|
|
535
|
+
public void setFocusBorderInset(int inset) {
|
|
536
|
+
if (borderDrawable != null) {
|
|
537
|
+
borderDrawable.setBorderInset(inset);
|
|
538
|
+
invalidate();
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
|
|
542
|
+
public void setFocusBorderEnable(boolean enable) {
|
|
543
|
+
if (borderDrawable != null) {
|
|
544
|
+
this.isBorderVisible = enable;
|
|
545
|
+
borderDrawable.setBorderVisible(enable);
|
|
546
|
+
invalidate();
|
|
547
|
+
}
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
public void setBlackRectEnable(boolean enable) {
|
|
551
|
+
if (borderDrawable != null) {
|
|
552
|
+
this.isBlackRectEnable = enable;
|
|
553
|
+
borderDrawable.setBlackRectEnable(enable);
|
|
554
|
+
invalidate();
|
|
555
|
+
}
|
|
556
|
+
}
|
|
557
|
+
|
|
558
|
+
@Override
|
|
559
|
+
public void draw(Canvas canvas) {
|
|
560
|
+
super.draw(canvas);
|
|
561
|
+
if (borderDrawable != null) {
|
|
562
|
+
borderDrawable.onDraw(canvas);
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
|
|
566
|
+
//zhaopeng add
|
|
567
|
+
|
|
568
|
+
public void setInitProps(HippyMap props) {
|
|
569
|
+
initProps = props;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
/**
|
|
573
|
+
* 前端传递下来的参数 left 到左边的距离 right 到右边的距离 top 到上边的距离 botttom 到下边的距离 Robinsli
|
|
574
|
+
*/
|
|
575
|
+
public void setNinePatchCoordinate(boolean shouldClearNinePatch, int left, int top, int right,
|
|
576
|
+
int botttom) {
|
|
577
|
+
if (shouldClearNinePatch) {
|
|
578
|
+
mNinePatchRect = null;
|
|
579
|
+
} else {
|
|
580
|
+
if (mNinePatchRect == null) {
|
|
581
|
+
mNinePatchRect = new Rect();
|
|
582
|
+
}
|
|
583
|
+
mNinePatchRect.set(left, top, right, botttom);
|
|
584
|
+
}
|
|
585
|
+
if (mContentDrawable instanceof HippyContentDrawable) {
|
|
586
|
+
((HippyContentDrawable) mContentDrawable).setNinePatchCoordinate(mNinePatchRect);
|
|
587
|
+
invalidate();
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
|
|
591
|
+
public void setImageEventEnable(int index, boolean enable) {
|
|
592
|
+
mShouldSendImageEvent[index] = enable;
|
|
593
|
+
}
|
|
594
|
+
|
|
595
|
+
@Override
|
|
596
|
+
protected void resetContent() {
|
|
597
|
+
super.resetContent();
|
|
598
|
+
// LogUtils.v("HippyDrawable","resetContent ,this:"+this);
|
|
599
|
+
mGifMovie = null;
|
|
600
|
+
mGifProgress = 0;
|
|
601
|
+
mGifLastPlayTime = -1;
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
@Override
|
|
605
|
+
protected boolean shouldUseFetchImageMode(String url) {
|
|
606
|
+
return UrlUtils.isWebUrl(url) || UrlUtils.isFileUrl(url);
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
public void setHippyViewDefaultSource(String defaultSourceUrl) {
|
|
610
|
+
setDefaultSource(defaultSourceUrl);
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
@Override
|
|
614
|
+
protected void doFetchImage(Object param, final int sourceType) {
|
|
615
|
+
if (mImageAdapter != null) {
|
|
616
|
+
if (param == null) {
|
|
617
|
+
param = new HashMap<String, Object>();
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
if (param instanceof Map) {
|
|
621
|
+
if (hippyEngineContext != null) {
|
|
622
|
+
RenderNode node = hippyEngineContext.getRenderManager().getRenderNode(getId());
|
|
623
|
+
if (node != null) {
|
|
624
|
+
initProps = node.getProps();
|
|
625
|
+
}
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
try {
|
|
629
|
+
//noinspection unchecked,rawtypes
|
|
630
|
+
((Map) param).put(IMAGE_PROPS, initProps);
|
|
631
|
+
//noinspection unchecked,rawtypes
|
|
632
|
+
((Map) param).put(IMAGE_VIEW_OBJ, this);
|
|
633
|
+
} catch (Exception e) {
|
|
634
|
+
LogUtils.d("HippyImageView", "doFetchImage: " + e);
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
// 这里不判断下是取背景图片还是取当前图片怎么行?
|
|
639
|
+
final String url = sourceType == SOURCE_TYPE_SRC ? mUrl : mDefaultSourceUrl;
|
|
640
|
+
//noinspection unchecked
|
|
641
|
+
mImageAdapter.fetchImage(url, new HippyImageLoader.Callback() {
|
|
642
|
+
@Override
|
|
643
|
+
public void onRequestStart(HippyDrawable drawableTarget) {
|
|
644
|
+
mSourceDrawable = drawableTarget;
|
|
645
|
+
}
|
|
646
|
+
|
|
647
|
+
@Override
|
|
648
|
+
public void onRequestSuccess(HippyDrawable drawableTarget) {
|
|
649
|
+
if (sourceType == SOURCE_TYPE_SRC) {
|
|
650
|
+
if (!TextUtils.equals(url, mUrl)) {
|
|
651
|
+
return;
|
|
652
|
+
}
|
|
653
|
+
mUrlFetchState = IMAGE_LOADED;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
if (sourceType == SOURCE_TYPE_DEFAULT_SRC && !TextUtils.equals(url, mDefaultSourceUrl)) {
|
|
657
|
+
return;
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
handleImageRequest(drawableTarget, sourceType, null);
|
|
661
|
+
}
|
|
662
|
+
|
|
663
|
+
@Override
|
|
664
|
+
public void onRequestFail(Throwable throwable, String source) {
|
|
665
|
+
if (sourceType == SOURCE_TYPE_SRC) {
|
|
666
|
+
if (!TextUtils.equals(url, mUrl)) {
|
|
667
|
+
return;
|
|
668
|
+
}
|
|
669
|
+
mUrlFetchState = IMAGE_UNLOAD;
|
|
670
|
+
}
|
|
671
|
+
|
|
672
|
+
if (sourceType == SOURCE_TYPE_DEFAULT_SRC && !TextUtils.equals(url, mDefaultSourceUrl)) {
|
|
673
|
+
return;
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
handleImageRequest(null, sourceType, throwable);
|
|
677
|
+
}
|
|
678
|
+
}, param);
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
public void setBackgroundColor(int backgroundColor) {
|
|
683
|
+
mUserHasSetBackgroudnColor = true;
|
|
684
|
+
mUserSetBackgroundColor = backgroundColor;
|
|
685
|
+
// LogUtils.v("HippyDrawable","setBackgroundColor ,this:"+this);
|
|
686
|
+
super.setBackgroundColor(backgroundColor);
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
@Override
|
|
690
|
+
protected void onFetchImage(String url) {
|
|
691
|
+
if (mContentDrawable instanceof ContentDrawable &&
|
|
692
|
+
((ContentDrawable) mContentDrawable).getSourceType() == SOURCE_TYPE_DEFAULT_SRC) {
|
|
693
|
+
return;
|
|
694
|
+
}
|
|
695
|
+
|
|
696
|
+
Drawable oldBGDrawable = getBackground();
|
|
697
|
+
resetContent();
|
|
698
|
+
|
|
699
|
+
|
|
700
|
+
if (url != null && (UrlUtils.isWebUrl(url) || UrlUtils.isFileUrl(url))) {
|
|
701
|
+
int defaultBackgroundColor = Color.LTGRAY;
|
|
702
|
+
if (mUserHasSetBackgroudnColor) {
|
|
703
|
+
defaultBackgroundColor = mUserSetBackgroundColor;
|
|
704
|
+
}
|
|
705
|
+
|
|
706
|
+
if (oldBGDrawable instanceof CommonBackgroundDrawable) {
|
|
707
|
+
((CommonBackgroundDrawable) oldBGDrawable).setBackgroundColor(defaultBackgroundColor);
|
|
708
|
+
setCustomBackgroundDrawable((CommonBackgroundDrawable) oldBGDrawable);
|
|
709
|
+
} else if (oldBGDrawable instanceof LayerDrawable) {
|
|
710
|
+
LayerDrawable layerDrawable = (LayerDrawable) oldBGDrawable;
|
|
711
|
+
int numberOfLayers = layerDrawable.getNumberOfLayers();
|
|
712
|
+
|
|
713
|
+
if (numberOfLayers > 0) {
|
|
714
|
+
Drawable bgDrawable = layerDrawable.getDrawable(0);
|
|
715
|
+
if (bgDrawable instanceof CommonBackgroundDrawable) {
|
|
716
|
+
((CommonBackgroundDrawable) bgDrawable).setBackgroundColor(defaultBackgroundColor);
|
|
717
|
+
setCustomBackgroundDrawable((CommonBackgroundDrawable) bgDrawable);
|
|
718
|
+
}
|
|
719
|
+
}
|
|
720
|
+
}
|
|
721
|
+
super.setBackgroundColor(defaultBackgroundColor);
|
|
722
|
+
mHasSetTempBackgroundColor = true;
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
|
|
726
|
+
@Override
|
|
727
|
+
protected void afterSetContent(String url) {
|
|
728
|
+
restoreBackgroundColorAfterSetContent();
|
|
729
|
+
}
|
|
730
|
+
|
|
731
|
+
@Override
|
|
732
|
+
protected void restoreBackgroundColorAfterSetContent() {
|
|
733
|
+
if (mBGDrawable != null && mHasSetTempBackgroundColor) {
|
|
734
|
+
int defaultBackgroundColor = Color.TRANSPARENT;
|
|
735
|
+
mBGDrawable.setBackgroundColor(defaultBackgroundColor);
|
|
736
|
+
// LogUtils.v("HippyDrawable","restoreBackgroundColorAfterSetContent ,this:"+this);
|
|
737
|
+
mHasSetTempBackgroundColor = false;
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
|
|
741
|
+
@Override
|
|
742
|
+
protected void updateContentDrawableProperty(int sourceType) {
|
|
743
|
+
super.updateContentDrawableProperty(sourceType);
|
|
744
|
+
if (mContentDrawable instanceof HippyContentDrawable && sourceType == SOURCE_TYPE_SRC) {
|
|
745
|
+
((HippyContentDrawable) mContentDrawable).setNinePatchCoordinate(mNinePatchRect);
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
|
|
749
|
+
@Override
|
|
750
|
+
protected ContentDrawable generateContentDrawable() {
|
|
751
|
+
return new HippyContentDrawable();
|
|
752
|
+
}
|
|
753
|
+
|
|
754
|
+
@Override
|
|
755
|
+
protected BackgroundDrawable generateBackgroundDrawable() {
|
|
756
|
+
return new CommonBackgroundDrawable();
|
|
757
|
+
}
|
|
758
|
+
|
|
759
|
+
@Override
|
|
760
|
+
public boolean onTouchEvent(MotionEvent event) {
|
|
761
|
+
boolean result = super.onTouchEvent(event);
|
|
762
|
+
if (mGestureDispatcher != null) {
|
|
763
|
+
result |= mGestureDispatcher.handleTouchEvent(event);
|
|
764
|
+
}
|
|
765
|
+
return result;
|
|
766
|
+
}
|
|
767
|
+
|
|
768
|
+
@Override
|
|
769
|
+
public NativeGestureDispatcher getGestureDispatcher() {
|
|
770
|
+
return mGestureDispatcher;
|
|
771
|
+
}
|
|
772
|
+
|
|
773
|
+
@Override
|
|
774
|
+
public void setGestureDispatcher(NativeGestureDispatcher dispatcher) {
|
|
775
|
+
mGestureDispatcher = dispatcher;
|
|
776
|
+
}
|
|
777
|
+
|
|
778
|
+
@Override
|
|
779
|
+
protected void handleGetImageStart() {
|
|
780
|
+
// send onLoadStart event
|
|
781
|
+
super.handleGetImageStart();
|
|
782
|
+
if (mShouldSendImageEvent[ImageEvent.ONLOAD_START.ordinal()]) {
|
|
783
|
+
getOnLoadStartEvent().send(this, null);
|
|
784
|
+
}
|
|
785
|
+
onBindNew = false;
|
|
786
|
+
if (mCustomStateListener != null) {
|
|
787
|
+
mCustomStateListener.onRequestStart(this);
|
|
788
|
+
}
|
|
789
|
+
}
|
|
790
|
+
|
|
791
|
+
@Override
|
|
792
|
+
protected void handleGetImageSuccess() {
|
|
793
|
+
// send onLoad event
|
|
794
|
+
if (mShouldSendImageEvent[ImageEvent.ONLOAD.ordinal()]) {
|
|
795
|
+
getOnLoadEvent().send(this, null);
|
|
796
|
+
}
|
|
797
|
+
if(mCustomStateListener != null) {
|
|
798
|
+
mCustomStateListener.onRequestSuccess(this);
|
|
799
|
+
}
|
|
800
|
+
// send onLoadEnd event
|
|
801
|
+
if (mShouldSendImageEvent[ImageEvent.ONLOAD_END.ordinal()]) {
|
|
802
|
+
HippyMap map = new HippyMap();
|
|
803
|
+
map.pushInt("success", 1);
|
|
804
|
+
if (mSourceDrawable != null) {
|
|
805
|
+
Bitmap bitmap = mSourceDrawable.getBitmap();
|
|
806
|
+
HippyMap imageSize = new HippyMap();
|
|
807
|
+
if (bitmap != null) {
|
|
808
|
+
imageSize.pushInt("width", bitmap.getWidth());
|
|
809
|
+
imageSize.pushInt("height", bitmap.getHeight());
|
|
810
|
+
} else {
|
|
811
|
+
imageSize.pushInt("width", 0);
|
|
812
|
+
imageSize.pushInt("height", 0);
|
|
813
|
+
}
|
|
814
|
+
map.pushMap("image", imageSize);
|
|
815
|
+
} else {
|
|
816
|
+
HippyMap imageSize = new HippyMap();
|
|
817
|
+
imageSize.pushInt("width", 0);
|
|
818
|
+
imageSize.pushInt("height", 0);
|
|
819
|
+
map.pushMap("image", imageSize);
|
|
820
|
+
}
|
|
821
|
+
getOnLoadEndEvent().send(this, map);
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
|
|
825
|
+
@Override
|
|
826
|
+
protected void handleGetImageFail(Throwable throwable) {
|
|
827
|
+
// send onError event
|
|
828
|
+
if (mShouldSendImageEvent[ImageEvent.ONERROR.ordinal()]) {
|
|
829
|
+
getOnErrorEvent().send(this, null);
|
|
830
|
+
}
|
|
831
|
+
// send onLoadEnd event
|
|
832
|
+
if (mShouldSendImageEvent[ImageEvent.ONLOAD_END.ordinal()]) {
|
|
833
|
+
HippyMap map = new HippyMap();
|
|
834
|
+
map.pushInt("success", 0);
|
|
835
|
+
getOnLoadEndEvent().send(this, map);
|
|
836
|
+
}
|
|
837
|
+
onBindNew = false;
|
|
838
|
+
if (mCustomStateListener != null) {
|
|
839
|
+
mCustomStateListener.onRequestFail(throwable, getUrl());
|
|
840
|
+
}
|
|
841
|
+
}
|
|
842
|
+
|
|
843
|
+
private void computeMatrixParams() {
|
|
844
|
+
if (!mGifMatrixComputed) {
|
|
845
|
+
// reset
|
|
846
|
+
mGifStartX = 0;
|
|
847
|
+
mGifStartY = 0;
|
|
848
|
+
mGifScaleX = 1;
|
|
849
|
+
mGifScaleY = 1;
|
|
850
|
+
if (mGifMovie.width() > 0 && mGifMovie.height() > 0 && getWidth() > 0 && getHeight() > 0) {
|
|
851
|
+
mGifScaleX = getWidth() / (float) mGifMovie.width();
|
|
852
|
+
mGifScaleY = getHeight() / (float) mGifMovie.height();
|
|
853
|
+
}
|
|
854
|
+
ScaleType type = mScaleType != null ? mScaleType : ScaleType.FIT_XY;
|
|
855
|
+
switch (type) {
|
|
856
|
+
case FIT_XY:
|
|
857
|
+
// 拉伸图片且不维持宽高比,直到宽高都刚好填满容器
|
|
858
|
+
break;
|
|
859
|
+
case CENTER:
|
|
860
|
+
// 居中不拉伸
|
|
861
|
+
mGifScaleX = 1;
|
|
862
|
+
mGifScaleY = 1;
|
|
863
|
+
break;
|
|
864
|
+
case CENTER_INSIDE:
|
|
865
|
+
// 在保持图片宽高比的前提下缩放图片,直到宽度和高度都小于等于容器视图的尺寸
|
|
866
|
+
// 这样图片完全被包裹在容器中,容器中可能留有空白
|
|
867
|
+
if (mGifScaleX > mGifScaleY) {
|
|
868
|
+
//noinspection SuspiciousNameCombination
|
|
869
|
+
mGifScaleX = mGifScaleY;
|
|
870
|
+
} else {
|
|
871
|
+
//noinspection SuspiciousNameCombination
|
|
872
|
+
mGifScaleY = mGifScaleX;
|
|
873
|
+
}
|
|
874
|
+
break;
|
|
875
|
+
case CENTER_CROP:
|
|
876
|
+
// 在保持图片宽高比的前提下缩放图片,直到宽度和高度都大于等于容器视图的尺寸
|
|
877
|
+
// 这样图片完全覆盖甚至超出容器,容器中不留任何空白
|
|
878
|
+
if (mGifScaleX < mGifScaleY) {
|
|
879
|
+
//noinspection SuspiciousNameCombination
|
|
880
|
+
mGifScaleX = mGifScaleY;
|
|
881
|
+
} else {
|
|
882
|
+
//noinspection SuspiciousNameCombination
|
|
883
|
+
mGifScaleY = mGifScaleX;
|
|
884
|
+
}
|
|
885
|
+
break;
|
|
886
|
+
case ORIGIN:
|
|
887
|
+
mGifScaleX = mGifScaleY = 1;
|
|
888
|
+
// 不拉伸,居左上
|
|
889
|
+
break;
|
|
890
|
+
}
|
|
891
|
+
if (mScaleType != ScaleType.ORIGIN) {
|
|
892
|
+
mGifStartX = (int) ((getWidth() / mGifScaleX - mGifMovie.width()) / 2f);
|
|
893
|
+
mGifStartY = (int) ((getHeight() / mGifScaleY - mGifMovie.height()) / 2f);
|
|
894
|
+
}
|
|
895
|
+
mGifMatrixComputed = true;
|
|
896
|
+
}
|
|
897
|
+
}
|
|
898
|
+
|
|
899
|
+
@Override
|
|
900
|
+
protected void handleImageRequest(IDrawableTarget target, int sourceType, Object requestInfo) {
|
|
901
|
+
if (target != null && !TextUtils.isEmpty(target.getImageType())) {
|
|
902
|
+
mImageType = target.getImageType();
|
|
903
|
+
}
|
|
904
|
+
|
|
905
|
+
if (target instanceof HippyDrawable && ((HippyDrawable) target).isAnimated()) {
|
|
906
|
+
mGifMovie = ((HippyDrawable) target).getGIF();
|
|
907
|
+
setLayerType(View.LAYER_TYPE_SOFTWARE, null);
|
|
908
|
+
}
|
|
909
|
+
|
|
910
|
+
if (!TextUtils.isEmpty(mImageType) && mImageType.equals(IMAGE_TYPE_APNG)
|
|
911
|
+
&& sourceType == SOURCE_TYPE_SRC) {
|
|
912
|
+
if (target != null) {
|
|
913
|
+
Drawable drawable = target.getDrawable();
|
|
914
|
+
if (drawable != null) {
|
|
915
|
+
mSourceDrawable = null;
|
|
916
|
+
mContentDrawable = drawable;
|
|
917
|
+
mUrlFetchState = IMAGE_LOADED;
|
|
918
|
+
setContent(sourceType);
|
|
919
|
+
handleGetImageSuccess();
|
|
920
|
+
return;
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
|
|
924
|
+
mUrlFetchState = IMAGE_UNLOAD;
|
|
925
|
+
handleGetImageFail(requestInfo instanceof Throwable ? (Throwable) requestInfo : null);
|
|
926
|
+
} else {
|
|
927
|
+
super.handleImageRequest(target, sourceType, requestInfo);
|
|
928
|
+
}
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
protected boolean drawGIF(Canvas canvas) {
|
|
932
|
+
if (mGifMovie == null) {
|
|
933
|
+
return false;
|
|
934
|
+
}
|
|
935
|
+
|
|
936
|
+
int duration = mGifMovie.duration();
|
|
937
|
+
if (duration == 0) {
|
|
938
|
+
duration = 1000;
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
long now = System.currentTimeMillis();
|
|
942
|
+
|
|
943
|
+
if (!isGifPaused) {
|
|
944
|
+
if (mGifLastPlayTime != -1) {
|
|
945
|
+
mGifProgress += now - mGifLastPlayTime;
|
|
946
|
+
|
|
947
|
+
if (mGifProgress > duration) {
|
|
948
|
+
mGifProgress = 0;
|
|
949
|
+
}
|
|
950
|
+
}
|
|
951
|
+
mGifLastPlayTime = now;
|
|
952
|
+
}
|
|
953
|
+
|
|
954
|
+
computeMatrixParams();
|
|
955
|
+
mGifMovie.setTime(mGifProgress);
|
|
956
|
+
canvas.save(); // 保存变换矩阵
|
|
957
|
+
canvas.scale(mGifScaleX, mGifScaleY);
|
|
958
|
+
mGifMovie.draw(canvas, mGifStartX, mGifStartY);
|
|
959
|
+
canvas.restore(); // 恢复变换矩阵
|
|
960
|
+
|
|
961
|
+
if (!isGifPaused) {
|
|
962
|
+
postInvalidateDelayed(40);
|
|
963
|
+
}
|
|
964
|
+
|
|
965
|
+
return true;
|
|
966
|
+
}
|
|
967
|
+
|
|
968
|
+
protected boolean shouldFetchImage() {
|
|
969
|
+
if (mUrlFetchState == IMAGE_LOADING) {
|
|
970
|
+
return onBindNew;
|
|
971
|
+
} else if (mUrlFetchState == IMAGE_UNLOAD) {
|
|
972
|
+
return true;
|
|
973
|
+
}
|
|
974
|
+
|
|
975
|
+
boolean isGif = (initProps != null) && initProps.getBoolean(NodeProps.CUSTOM_PROP_ISGIF);
|
|
976
|
+
if (!isGif) {
|
|
977
|
+
isGif = !TextUtils.isEmpty(mImageType) && mImageType.equals(IMAGE_TYPE_GIF);
|
|
978
|
+
}
|
|
979
|
+
|
|
980
|
+
if (!TextUtils.isEmpty(mImageType) && mImageType.equals(IMAGE_TYPE_APNG)
|
|
981
|
+
&& mContentDrawable != null && !(mContentDrawable instanceof ContentDrawable)) {
|
|
982
|
+
return onBindNew;
|
|
983
|
+
} else if (isGif) {
|
|
984
|
+
return mGifMovie == null || onBindNew;
|
|
985
|
+
} else {
|
|
986
|
+
Bitmap bitmap = getBitmap();
|
|
987
|
+
//noinspection RedundantIfStatement
|
|
988
|
+
if (bitmap == null || bitmap.isRecycled()) {
|
|
989
|
+
return true;
|
|
990
|
+
}
|
|
991
|
+
}
|
|
992
|
+
|
|
993
|
+
return onBindNew;
|
|
994
|
+
}
|
|
995
|
+
|
|
996
|
+
// 图片自绘功能(方便自定义支持gif、webp、tpg等)尚未实现,暂时注释
|
|
997
|
+
// private void drawSelf(Canvas canvas, HippyDrawable drawable) {
|
|
998
|
+
// computeMatrixParams();
|
|
999
|
+
// canvas.save(); // 保存变换矩阵
|
|
1000
|
+
//
|
|
1001
|
+
// canvas.clipRect(new Rect(mGifStartX, mGifStartY, canvas.getWidth(), canvas.getHeight()));
|
|
1002
|
+
// canvas.scale(mGifScaleX, mGifScaleY);
|
|
1003
|
+
//
|
|
1004
|
+
// drawable.draw(canvas);
|
|
1005
|
+
//
|
|
1006
|
+
// // canvas.restore(); // 恢复变换矩阵
|
|
1007
|
+
// postInvalidateDelayed(40);
|
|
1008
|
+
// }
|
|
1009
|
+
|
|
1010
|
+
|
|
1011
|
+
@Override
|
|
1012
|
+
protected void onDetachedFromWindow() {
|
|
1013
|
+
super.onDetachedFromWindow();
|
|
1014
|
+
if (isFocusable() && borderDrawable != null) {
|
|
1015
|
+
borderDrawable.onDetachedFromWindow(this);
|
|
1016
|
+
}
|
|
1017
|
+
}
|
|
1018
|
+
|
|
1019
|
+
@Override
|
|
1020
|
+
public void onDraw(Canvas canvas) {
|
|
1021
|
+
super.onDraw(canvas);
|
|
1022
|
+
// 图片自绘功能(方便自定义支持gif、webp、tpg等)尚未实现,暂时注释
|
|
1023
|
+
// if (mSourceDrawable instanceof HippyDrawable)
|
|
1024
|
+
// {
|
|
1025
|
+
// HippyDrawable drawable = (HippyDrawable) mSourceDrawable;
|
|
1026
|
+
// if (drawable.isSelfDraw())
|
|
1027
|
+
// drawSelf(canvas, drawable);
|
|
1028
|
+
// }
|
|
1029
|
+
// else
|
|
1030
|
+
if (mGifMovie != null) {
|
|
1031
|
+
// 如果是GIF,就调用drawGIF()方法播放GIF动画
|
|
1032
|
+
drawGIF(canvas);
|
|
1033
|
+
}
|
|
1034
|
+
}
|
|
1035
|
+
|
|
1036
|
+
private boolean isGifPaused = false;
|
|
1037
|
+
|
|
1038
|
+
public void startPlay() {
|
|
1039
|
+
isGifPaused = false;
|
|
1040
|
+
invalidate();
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
public void pause() {
|
|
1044
|
+
isGifPaused = true;
|
|
1045
|
+
mGifLastPlayTime = -1;
|
|
1046
|
+
}
|
|
1047
|
+
|
|
1048
|
+
@Override
|
|
1049
|
+
public void notifySaveState() {
|
|
1050
|
+
|
|
1051
|
+
}
|
|
1052
|
+
|
|
1053
|
+
@Override
|
|
1054
|
+
public void notifyRestoreState() {
|
|
1055
|
+
|
|
1056
|
+
}
|
|
1057
|
+
|
|
1058
|
+
private OnLoadEvent getOnLoadEvent() {
|
|
1059
|
+
if (mOnLoadEvent == null) {
|
|
1060
|
+
mOnLoadEvent = new OnLoadEvent();
|
|
1061
|
+
}
|
|
1062
|
+
return mOnLoadEvent;
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
private OnLoadEndEvent getOnLoadEndEvent() {
|
|
1066
|
+
if (mOnLoadEndEvent == null) {
|
|
1067
|
+
mOnLoadEndEvent = new OnLoadEndEvent();
|
|
1068
|
+
}
|
|
1069
|
+
return mOnLoadEndEvent;
|
|
1070
|
+
}
|
|
1071
|
+
|
|
1072
|
+
private OnLoadStartEvent getOnLoadStartEvent() {
|
|
1073
|
+
if (mOnLoadStartEvent == null) {
|
|
1074
|
+
mOnLoadStartEvent = new OnLoadStartEvent();
|
|
1075
|
+
}
|
|
1076
|
+
return mOnLoadStartEvent;
|
|
1077
|
+
}
|
|
1078
|
+
|
|
1079
|
+
private OnErrorEvent getOnErrorEvent() {
|
|
1080
|
+
if (mOnErrorEvent == null) {
|
|
1081
|
+
mOnErrorEvent = new OnErrorEvent();
|
|
1082
|
+
}
|
|
1083
|
+
return mOnErrorEvent;
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1086
|
+
/**
|
|
1087
|
+
* event to js
|
|
1088
|
+
**/
|
|
1089
|
+
static class OnLoadEvent extends HippyViewEvent {
|
|
1090
|
+
|
|
1091
|
+
OnLoadEvent() {
|
|
1092
|
+
super("onLoad");
|
|
1093
|
+
}
|
|
1094
|
+
}
|
|
1095
|
+
|
|
1096
|
+
static class OnLoadEndEvent extends HippyViewEvent {
|
|
1097
|
+
|
|
1098
|
+
OnLoadEndEvent() {
|
|
1099
|
+
super("onLoadEnd");
|
|
1100
|
+
}
|
|
1101
|
+
}
|
|
1102
|
+
|
|
1103
|
+
static class OnLoadStartEvent extends HippyViewEvent {
|
|
1104
|
+
|
|
1105
|
+
OnLoadStartEvent() {
|
|
1106
|
+
super("onLoadStart");
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
|
|
1110
|
+
static class OnErrorEvent extends HippyViewEvent {
|
|
1111
|
+
|
|
1112
|
+
OnErrorEvent() {
|
|
1113
|
+
super("onError");
|
|
1114
|
+
}
|
|
1115
|
+
}
|
|
1116
|
+
|
|
1117
|
+
/**
|
|
1118
|
+
* add by zhaopeng 20201110
|
|
1119
|
+
*/
|
|
1120
|
+
|
|
1121
|
+
|
|
1122
|
+
private int mDuration = TVFocusScaleExcuter.DEFAULT_DURATION;
|
|
1123
|
+
private float mFocusScaleX = FocusManagerModule.defaultFocusScale;
|
|
1124
|
+
private float mFocusScaleY = FocusManagerModule.defaultFocusScale;
|
|
1125
|
+
|
|
1126
|
+
private final AttachInfo mAttachInfo = new AttachInfo();
|
|
1127
|
+
|
|
1128
|
+
/**
|
|
1129
|
+
* -------------------------------------------------------------------------------------
|
|
1130
|
+
**/
|
|
1131
|
+
|
|
1132
|
+
@Override
|
|
1133
|
+
public void onHandleFocusScale(boolean gainFocus, int direction, Rect previouslyFocusedRect) {
|
|
1134
|
+
if (isFocusable() && mFocusScaleX != 1 || mFocusScaleY != 1) {
|
|
1135
|
+
handleFocusScale(gainFocus, direction, previouslyFocusedRect, mDuration);
|
|
1136
|
+
}
|
|
1137
|
+
|
|
1138
|
+
}
|
|
1139
|
+
|
|
1140
|
+
|
|
1141
|
+
public void handleFocusScale(boolean gainFocus, int direction, Rect previouslyFocusedRect, int duration) {
|
|
1142
|
+
if ((mFocusScaleX != 1 || mFocusScaleY != 1)) {
|
|
1143
|
+
AutoFocusManager af = AutoFocusManager.findAutoFocusManagerFromRoot(this);
|
|
1144
|
+
if (af != null) {
|
|
1145
|
+
af.handleOnFocusChange(this, gainFocus, mFocusScaleX, mFocusScaleY, duration);
|
|
1146
|
+
}else {
|
|
1147
|
+
TVFocusScaleExcuter.handleOnFocusChange(this, gainFocus, mFocusScaleX, mFocusScaleY, duration);
|
|
1148
|
+
}
|
|
1149
|
+
}
|
|
1150
|
+
}
|
|
1151
|
+
|
|
1152
|
+
public void handleFocusScaleImmediately(boolean gainFocus, int direction, Rect previouslyFocusedRect) {
|
|
1153
|
+
if (isFocusable() && (mFocusScaleX != 1 || mFocusScaleY != 1)) {
|
|
1154
|
+
// Log.e("zhaopeng","!!!!!!handleFocusScaleImmediately gainFocus:"+gainFocus);
|
|
1155
|
+
TVFocusScaleExcuter.handleOnFocusChange(this, gainFocus, mFocusScaleX, mFocusScaleY, 0);
|
|
1156
|
+
}
|
|
1157
|
+
}
|
|
1158
|
+
|
|
1159
|
+
@Override
|
|
1160
|
+
public Rect getFloatFocusMarginRect() {
|
|
1161
|
+
return mAttachInfo.mFloatFocusMarginRect;
|
|
1162
|
+
}
|
|
1163
|
+
|
|
1164
|
+
|
|
1165
|
+
/**
|
|
1166
|
+
* {@link ITVView#setFocusScale(float)}
|
|
1167
|
+
*
|
|
1168
|
+
* @param scale 缩放倍数
|
|
1169
|
+
*/
|
|
1170
|
+
@Override
|
|
1171
|
+
public void setFocusScale(float scale) {
|
|
1172
|
+
this.mFocusScaleX = scale;
|
|
1173
|
+
this.mFocusScaleY = scale;
|
|
1174
|
+
}
|
|
1175
|
+
|
|
1176
|
+
|
|
1177
|
+
/**
|
|
1178
|
+
* 设置View获得焦点的放大倍数
|
|
1179
|
+
*/
|
|
1180
|
+
@Override
|
|
1181
|
+
public void setFocusScaleX(float scale) {
|
|
1182
|
+
this.mFocusScaleX = scale;
|
|
1183
|
+
}
|
|
1184
|
+
|
|
1185
|
+
/**
|
|
1186
|
+
* 设置View获得焦点的放大倍数
|
|
1187
|
+
*/
|
|
1188
|
+
@Override
|
|
1189
|
+
public void setFocusScaleY(float scale) {
|
|
1190
|
+
this.mFocusScaleY = scale;
|
|
1191
|
+
}
|
|
1192
|
+
|
|
1193
|
+
|
|
1194
|
+
/**
|
|
1195
|
+
* {@link ITVView#setFocusScaleDuration(int)}
|
|
1196
|
+
*
|
|
1197
|
+
* @param duration 缩放动画时长 单位:毫秒
|
|
1198
|
+
*/
|
|
1199
|
+
@Override
|
|
1200
|
+
public void setFocusScaleDuration(int duration) {
|
|
1201
|
+
this.mDuration = duration;
|
|
1202
|
+
}
|
|
1203
|
+
|
|
1204
|
+
@Override
|
|
1205
|
+
public float getFocusScale() {
|
|
1206
|
+
return mFocusScaleX ;
|
|
1207
|
+
}
|
|
1208
|
+
|
|
1209
|
+
@Override
|
|
1210
|
+
public float getFocusScaleX() {
|
|
1211
|
+
return mFocusScaleX;
|
|
1212
|
+
}
|
|
1213
|
+
|
|
1214
|
+
@Override
|
|
1215
|
+
public float getFocusScaleY() {
|
|
1216
|
+
return mFocusScaleY;
|
|
1217
|
+
}
|
|
1218
|
+
|
|
1219
|
+
@Override
|
|
1220
|
+
public IFloatFocusManager getFloatFocusManager() {
|
|
1221
|
+
return null;
|
|
1222
|
+
}
|
|
1223
|
+
|
|
1224
|
+
@Override
|
|
1225
|
+
public void setFloatFocusFocusedAlpha(float alpha) {
|
|
1226
|
+
mAttachInfo.setFloatFocusFocusedAlpha(alpha);
|
|
1227
|
+
}
|
|
1228
|
+
|
|
1229
|
+
@Override
|
|
1230
|
+
public AttachInfo getAttachInfo() {
|
|
1231
|
+
return mAttachInfo;
|
|
1232
|
+
}
|
|
1233
|
+
|
|
1234
|
+
@Override
|
|
1235
|
+
public View getView() {
|
|
1236
|
+
return this;
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
|
|
1240
|
+
protected int getUserSetBackgroundColor() {
|
|
1241
|
+
return mUserSetBackgroundColor;
|
|
1242
|
+
}
|
|
1243
|
+
|
|
1244
|
+
private boolean mInReFocus = false;
|
|
1245
|
+
|
|
1246
|
+
@Override
|
|
1247
|
+
public void notifyInReFocus(boolean isIn) {
|
|
1248
|
+
this.mInReFocus = isIn;
|
|
1249
|
+
// Log.d("zhaopeng"," notifyInReFocus :"+isIn+" this:"+this);
|
|
1250
|
+
if (!isFocusable()) {
|
|
1251
|
+
for (int i = 0; i < getChildCount(); i++) {
|
|
1252
|
+
final View child = getChildAt(i);
|
|
1253
|
+
if (child instanceof ITVView) {
|
|
1254
|
+
((ITVView) child).notifyInReFocus(isIn);
|
|
1255
|
+
}
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
}
|
|
1259
|
+
|
|
1260
|
+
@Override
|
|
1261
|
+
protected void onFocusChanged(boolean gainFocus, int direction, @Nullable Rect previouslyFocusedRect) {
|
|
1262
|
+
super.onFocusChanged(gainFocus, direction, previouslyFocusedRect);
|
|
1263
|
+
if (borderDrawable != null && isBorderVisible) {
|
|
1264
|
+
borderDrawable.onFocusChanged(this, gainFocus);
|
|
1265
|
+
}
|
|
1266
|
+
}
|
|
1267
|
+
|
|
1268
|
+
@Override
|
|
1269
|
+
public boolean isInReFocus() {
|
|
1270
|
+
return mInReFocus;
|
|
1271
|
+
}
|
|
1272
|
+
|
|
1273
|
+
private int mUserSetFocusBackgroundColor = 0;
|
|
1274
|
+
private int mUserSetSelectBackgroundColor = 0;
|
|
1275
|
+
private boolean relayoutAfterAttach = false;
|
|
1276
|
+
|
|
1277
|
+
|
|
1278
|
+
/***
|
|
1279
|
+
*
|
|
1280
|
+
* @param color
|
|
1281
|
+
*/
|
|
1282
|
+
public void setFocusBackGroundColor(int color) {
|
|
1283
|
+
this.mUserSetFocusBackgroundColor = color;
|
|
1284
|
+
// invalidate();
|
|
1285
|
+
drawableStateChanged();
|
|
1286
|
+
}
|
|
1287
|
+
|
|
1288
|
+
/***
|
|
1289
|
+
*
|
|
1290
|
+
* @param color
|
|
1291
|
+
*/
|
|
1292
|
+
public void setSelectBackGroundColor(int color) {
|
|
1293
|
+
this.mUserSetSelectBackgroundColor = color;
|
|
1294
|
+
// invalidate();
|
|
1295
|
+
drawableStateChanged();
|
|
1296
|
+
}
|
|
1297
|
+
|
|
1298
|
+
|
|
1299
|
+
public void setRelayoutAfterAttach(boolean relayoutAfterAttach) {
|
|
1300
|
+
this.relayoutAfterAttach = relayoutAfterAttach;
|
|
1301
|
+
}
|
|
1302
|
+
|
|
1303
|
+
@Override
|
|
1304
|
+
protected void onAttachedToWindow() {
|
|
1305
|
+
super.onAttachedToWindow();
|
|
1306
|
+
if (selectState) {
|
|
1307
|
+
setSelected(true);
|
|
1308
|
+
}
|
|
1309
|
+
if (relayoutAfterAttach) {
|
|
1310
|
+
if (getWidth() <= 0 || getHeight() <= 0) {
|
|
1311
|
+
if (getContext() instanceof HippyInstanceContext) {
|
|
1312
|
+
final HippyEngineContext context = ((HippyInstanceContext) getContext()).getEngineContext();
|
|
1313
|
+
if (context != null) {
|
|
1314
|
+
final RenderNode node = context.getRenderManager().getRenderNode(getId());
|
|
1315
|
+
if (node != null && !node.isDelete()) {
|
|
1316
|
+
node.updateLayout(node.getX(), node.getY(), node.getWidth(), node.getHeight());
|
|
1317
|
+
node.updateViewRecursive();
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1320
|
+
}
|
|
1321
|
+
}
|
|
1322
|
+
}
|
|
1323
|
+
//Log.v(AutoFocusManager.TAG, "------onAttachedToWindow this:" + this + ",isAttached:" + isAttached()+",width:"+getWidth());
|
|
1324
|
+
if(getWidth() > 0 && getHeight() > 0 && getVisibility() == View.VISIBLE){
|
|
1325
|
+
if(AutoFocusManager.isAutofocusView(this)) {
|
|
1326
|
+
if(LogUtils.isDebug()) {
|
|
1327
|
+
Log.i(AutoFocusManager.TAG, "auto requestFocus on onAttachedToWindow ,view:" + this);
|
|
1328
|
+
}
|
|
1329
|
+
onRequestAutofocus(this, this,ExtendViewGroup.AUTOFOCUS_TYPE_ATTACH);
|
|
1330
|
+
}
|
|
1331
|
+
}
|
|
1332
|
+
// LogUtils.v("HippyDrawable","onAttachedToWindow ,this:"+this);
|
|
1333
|
+
}
|
|
1334
|
+
|
|
1335
|
+
@Override
|
|
1336
|
+
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
|
|
1337
|
+
super.onSizeChanged(w, h, oldw, oldh);
|
|
1338
|
+
if (borderDrawable != null) {
|
|
1339
|
+
borderDrawable.onSizeChanged(w, h, oldw, oldh);
|
|
1340
|
+
}
|
|
1341
|
+
for(int i = 0; i < getChildCount(); i ++){
|
|
1342
|
+
final View v = getChildAt(i);
|
|
1343
|
+
if(v instanceof ITVView){
|
|
1344
|
+
final ITVView cv = (ITVView) v;
|
|
1345
|
+
if(cv.isFillParent()){
|
|
1346
|
+
cv.getView().layout(0,0,w,h);
|
|
1347
|
+
//layoutChildrenLegacy(cv.getView(),l,t,r,b);
|
|
1348
|
+
if(LogUtils.isDebug()) {
|
|
1349
|
+
Log.d(CustomLayoutView.TAG, "layout fill child:" + cv.getView());
|
|
1350
|
+
}
|
|
1351
|
+
}
|
|
1352
|
+
}
|
|
1353
|
+
}
|
|
1354
|
+
|
|
1355
|
+
if(oldw < 1 && oldh < 1 && w > 0 && h > 0){
|
|
1356
|
+
//Log.v(AutoFocusManager.TAG,"------onSizeChanged this:"+this+",isAttached:"+isAttached());
|
|
1357
|
+
//v-show变化后
|
|
1358
|
+
if(globalVisibility == View.VISIBLE && getVisibility() == View.VISIBLE && isAttached()){
|
|
1359
|
+
//AutoFocusManager.globalRequestFocus(this);
|
|
1360
|
+
if(AutoFocusManager.isAutofocusView(this)) {
|
|
1361
|
+
if(LogUtils.isDebug()) {
|
|
1362
|
+
Log.i(AutoFocusManager.TAG, "auto requestFocus on size changed ,view:" + ExtendUtil.debugView(this));
|
|
1363
|
+
}
|
|
1364
|
+
onRequestAutofocus(this, this,ExtendViewGroup.AUTOFOCUS_TYPE_SIZE_VALID);
|
|
1365
|
+
}
|
|
1366
|
+
}
|
|
1367
|
+
//这里由于设置backgroundColorStr背景色,在尺寸0的时候不生效,所以这里再设置一下。
|
|
1368
|
+
ExtendTag tag = ExtendTag.getExtendTag(this);
|
|
1369
|
+
if(tag!= null && tag.pendingBackGroundColor != -1){
|
|
1370
|
+
setBackgroundColor(tag.pendingBackGroundColor);
|
|
1371
|
+
tag.pendingBackGroundColor = -1;
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
//if(AutoFocusManager.)
|
|
1375
|
+
}
|
|
1376
|
+
}
|
|
1377
|
+
|
|
1378
|
+
public void onRequestAutofocus(View child, View target, int type) {
|
|
1379
|
+
if(child.getParent() instanceof ExtendViewGroup){
|
|
1380
|
+
ExtendViewGroup parent = (ExtendViewGroup) child.getParent();
|
|
1381
|
+
parent.onRequestAutofocus(child,target,type);
|
|
1382
|
+
}else{
|
|
1383
|
+
Log.i(AutoFocusManager.TAG,"onRequestAutofocus parent is not a instance of ExtendViewGroup parent: "+getParent());
|
|
1384
|
+
}
|
|
1385
|
+
}
|
|
1386
|
+
|
|
1387
|
+
@Override
|
|
1388
|
+
protected void onDrawableAttached() {
|
|
1389
|
+
super.onDrawableAttached();
|
|
1390
|
+
}
|
|
1391
|
+
|
|
1392
|
+
protected void onChangeShowOnState() {
|
|
1393
|
+
|
|
1394
|
+
}
|
|
1395
|
+
|
|
1396
|
+
private Runnable updateBGTask;
|
|
1397
|
+
|
|
1398
|
+
private void postSetBGColor(final int bg) {
|
|
1399
|
+
// if(updateBGTask != null){
|
|
1400
|
+
// removeCallbacks(updateBGTask);
|
|
1401
|
+
// }
|
|
1402
|
+
// updateBGTask = () -> {
|
|
1403
|
+
// getBackgroundDrawable().setBackgroundColor(bg);
|
|
1404
|
+
// invalidate();
|
|
1405
|
+
// };
|
|
1406
|
+
// postDelayed(updateBGTask,16);
|
|
1407
|
+
getBackgroundDrawable().setBackgroundColor(bg);
|
|
1408
|
+
postInvalidateDelayed(16);
|
|
1409
|
+
// invalidate();
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
|
|
1413
|
+
|
|
1414
|
+
@Override
|
|
1415
|
+
protected void drawableStateChanged() {
|
|
1416
|
+
super.drawableStateChanged();
|
|
1417
|
+
int[] states = getDrawableState();
|
|
1418
|
+
|
|
1419
|
+
|
|
1420
|
+
if (!isFocused() && isDuplicateParentStateEnabled()) {
|
|
1421
|
+
final boolean focused = ExtendUtil.stateContainsAttribute(states, android.R.attr.state_focused);
|
|
1422
|
+
if(isBorderVisible){
|
|
1423
|
+
if (borderDrawable != null) {
|
|
1424
|
+
borderDrawable.onDrawableStateChanged(this, focused);
|
|
1425
|
+
}
|
|
1426
|
+
}
|
|
1427
|
+
if (focusScaleOnDuplicateParentState && (mFocusScaleX != 1 || mFocusScaleY != 1)) {
|
|
1428
|
+
//TVFocusScaleExcuter.handleOnFocusChange(this, focused, mFocusScaleX, mFocusScaleY, mDuration);
|
|
1429
|
+
// onHandleFocusScale();
|
|
1430
|
+
handleFocusScale(focused,-1,null,mDuration);
|
|
1431
|
+
}
|
|
1432
|
+
}
|
|
1433
|
+
if (ExtendUtil.handleShowOnState(this, states, showOnState)) {
|
|
1434
|
+
onChangeShowOnState();
|
|
1435
|
+
}
|
|
1436
|
+
ExtendUtil.handleCustomShowOnState(this, mCustomStateList,showOnStateCustom);
|
|
1437
|
+
// if(showOnState == null && isDuplicateParentStateEnabled()) {
|
|
1438
|
+
// if(LogUtils.isDebug()) {
|
|
1439
|
+
// LogUtils.e("HippyDrawable", "isDuplicateParentStateEnabled0 ,this:" + hashCode() + ",showOnState is NULL");
|
|
1440
|
+
// }
|
|
1441
|
+
// }
|
|
1442
|
+
// else{
|
|
1443
|
+
// LogUtils.v("HippyDrawable", "isDuplicateParentStateEnabled0 ,this:" + hashCode() + ",showOnState length:" + showOnState.length);
|
|
1444
|
+
// }
|
|
1445
|
+
if (isFocusable() || isDuplicateParentStateEnabled()) {
|
|
1446
|
+
if (mUserSetFocusBackgroundColor != 0) {
|
|
1447
|
+
|
|
1448
|
+
final boolean focused = ExtendUtil.stateContainsAttribute(states, android.R.attr.state_focused);
|
|
1449
|
+
if (focused || isFocused()) {
|
|
1450
|
+
postSetBGColor(mUserSetFocusBackgroundColor);
|
|
1451
|
+
return;
|
|
1452
|
+
}
|
|
1453
|
+
}
|
|
1454
|
+
|
|
1455
|
+
final boolean select = ExtendUtil.stateContainsAttribute(states, android.R.attr.state_selected);
|
|
1456
|
+
if (mUserSetSelectBackgroundColor != 0) {
|
|
1457
|
+
if (select || isSelected()) {
|
|
1458
|
+
postSetBGColor(mUserSetSelectBackgroundColor);
|
|
1459
|
+
return;
|
|
1460
|
+
}
|
|
1461
|
+
}
|
|
1462
|
+
if (mUrlFetchState != IMAGE_LOADED || onBindNew || getId() != -1) {
|
|
1463
|
+
//zhaopeng 因为图片已经加载成功,直接展示图片,不需要再展示背景
|
|
1464
|
+
//getId != -1的判断是由于在fastList里会走onBindNew,而在普通的img标签上却没有机会执行,所以这里做一下修正
|
|
1465
|
+
postSetBGColor(getUserSetBackgroundColor());
|
|
1466
|
+
} else {
|
|
1467
|
+
postInvalidateDelayed(16);
|
|
1468
|
+
}
|
|
1469
|
+
}
|
|
1470
|
+
}
|
|
1471
|
+
|
|
1472
|
+
@Override
|
|
1473
|
+
public void getState(@NonNull HippyMap map) {
|
|
1474
|
+
if (getBitmap() != null) {
|
|
1475
|
+
map.pushInt("imgWidth", getBitmap().getWidth());
|
|
1476
|
+
map.pushInt("imgHeight", getBitmap().getHeight());
|
|
1477
|
+
}
|
|
1478
|
+
}
|
|
1479
|
+
|
|
1480
|
+
private int[] showOnState;
|
|
1481
|
+
|
|
1482
|
+
|
|
1483
|
+
@Override
|
|
1484
|
+
public void setShowOnState(int[] showOnState) {
|
|
1485
|
+
if (LogUtils.isDebug()) {
|
|
1486
|
+
LogUtils.i("HippyDrawable", "setShowOnState ,showOnState size:" + showOnState.length + ",this:" + hashCode());
|
|
1487
|
+
}
|
|
1488
|
+
this.showOnState = showOnState;
|
|
1489
|
+
}
|
|
1490
|
+
|
|
1491
|
+
/** custom showOnState
|
|
1492
|
+
* --------------------
|
|
1493
|
+
*/
|
|
1494
|
+
private String[] showOnStateCustom;
|
|
1495
|
+
ArrayMap<String,Boolean> mCustomStateList = null;
|
|
1496
|
+
@Override
|
|
1497
|
+
public void setCustomState(String state, boolean on) {
|
|
1498
|
+
if (mCustomStateList == null) {
|
|
1499
|
+
mCustomStateList = new ArrayMap<>();
|
|
1500
|
+
}
|
|
1501
|
+
mCustomStateList.put(state,on);
|
|
1502
|
+
if("selected".equals(state)){
|
|
1503
|
+
setSelectState(on);
|
|
1504
|
+
}
|
|
1505
|
+
Log.i("CustomState","setCustomState state:"+state+" on:"+on+" this:"+ExtendUtil.debugViewLite(this));
|
|
1506
|
+
changeChildrenCustomState(this,state,on);
|
|
1507
|
+
refreshDrawableState();
|
|
1508
|
+
}
|
|
1509
|
+
|
|
1510
|
+
void changeChildrenCustomState(ViewGroup view,String state, boolean on){
|
|
1511
|
+
for (int i = 0; i < view.getChildCount(); i++) {
|
|
1512
|
+
View child = view.getChildAt(i);
|
|
1513
|
+
if (child.isDuplicateParentStateEnabled()) {
|
|
1514
|
+
if (child instanceof StateView) {
|
|
1515
|
+
((StateView) child).setCustomState(state, on);
|
|
1516
|
+
} else if (child instanceof ViewGroup) {
|
|
1517
|
+
changeChildrenCustomState((ViewGroup) child, state, on);
|
|
1518
|
+
}
|
|
1519
|
+
}
|
|
1520
|
+
}
|
|
1521
|
+
}
|
|
1522
|
+
|
|
1523
|
+
|
|
1524
|
+
@Override
|
|
1525
|
+
public void setShowOnCustomState(String[] showOnState) {
|
|
1526
|
+
this.showOnStateCustom = showOnState;
|
|
1527
|
+
}
|
|
1528
|
+
|
|
1529
|
+
/**custom showOnState
|
|
1530
|
+
* ----------------
|
|
1531
|
+
*/
|
|
1532
|
+
/**
|
|
1533
|
+
* -------------------------------------------------------------------------------------
|
|
1534
|
+
**/
|
|
1535
|
+
|
|
1536
|
+
public void setSelectState(boolean selectState) {
|
|
1537
|
+
this.selectState = selectState;
|
|
1538
|
+
setSelected(selectState);
|
|
1539
|
+
}
|
|
1540
|
+
|
|
1541
|
+
|
|
1542
|
+
|
|
1543
|
+
@Override
|
|
1544
|
+
public void setSelected(boolean selected) {
|
|
1545
|
+
super.setSelected(selected);
|
|
1546
|
+
if (showOnState != null && showOnState.length > 0) {
|
|
1547
|
+
HippyMap hippyMap = new HippyMap();
|
|
1548
|
+
hippyMap.pushBoolean("isSelected", selected);
|
|
1549
|
+
new HippyViewEvent("onSelect").send(this, hippyMap);
|
|
1550
|
+
}
|
|
1551
|
+
}
|
|
1552
|
+
|
|
1553
|
+
|
|
1554
|
+
@Override
|
|
1555
|
+
public void setFillParent(boolean b) {
|
|
1556
|
+
isFillParent = b;
|
|
1557
|
+
}
|
|
1558
|
+
|
|
1559
|
+
@Override
|
|
1560
|
+
public boolean isFillParent() {
|
|
1561
|
+
return isFillParent;
|
|
1562
|
+
}
|
|
1563
|
+
|
|
1564
|
+
|
|
1565
|
+
|
|
1566
|
+
@Override
|
|
1567
|
+
protected void onLayout(boolean changed, int l, int t, int r, int b) {
|
|
1568
|
+
super.onLayout(changed, l, t, r, b);
|
|
1569
|
+
if(changed){
|
|
1570
|
+
if (mCustomStateListener != null) {
|
|
1571
|
+
mCustomStateListener.onImageLayout(this, l, t, r, b);
|
|
1572
|
+
}
|
|
1573
|
+
}
|
|
1574
|
+
}
|
|
1575
|
+
|
|
1576
|
+
@Override
|
|
1577
|
+
public void notifyBringToFront(boolean b) {
|
|
1578
|
+
|
|
1579
|
+
}
|
|
1580
|
+
|
|
1581
|
+
//这里暂不需要
|
|
1582
|
+
// static void layoutChildrenLegacy(View view,int l, int t, int r, int b){
|
|
1583
|
+
// if(!(view instanceof ViewGroup)){
|
|
1584
|
+
// return;
|
|
1585
|
+
// }
|
|
1586
|
+
// for(int i = 0; i < ((ViewGroup) view).getChildCount(); i ++){
|
|
1587
|
+
// final View child = ((ViewGroup) view).getChildAt(i);
|
|
1588
|
+
// LayoutParams lp = child.getLayoutParams();
|
|
1589
|
+
// int cl,ct,cr,cb;cl = ct= cr = cb = 0;
|
|
1590
|
+
// if (lp != null) {
|
|
1591
|
+
// if(lp.width == LayoutParams.MATCH_PARENT){
|
|
1592
|
+
// cr = r - l;
|
|
1593
|
+
// }
|
|
1594
|
+
// if(lp.height == LayoutParams.MATCH_PARENT){
|
|
1595
|
+
// cb = b - t ;
|
|
1596
|
+
// }
|
|
1597
|
+
// }else {
|
|
1598
|
+
// cr = r - l;
|
|
1599
|
+
// cb = b - t;
|
|
1600
|
+
// }
|
|
1601
|
+
// Log.e(CustomLayoutView.TAG,"layoutChildrenLegacy left:"+cl+",top :"+ct+",right :"+cr+",b:"+cb);
|
|
1602
|
+
// RenderUtil.layoutView(child,cl,ct,cr,cb);
|
|
1603
|
+
// layoutChildrenLegacy(child,cl,ct,cr,cb);
|
|
1604
|
+
//
|
|
1605
|
+
// }
|
|
1606
|
+
// }
|
|
1607
|
+
|
|
1608
|
+
}
|