@react-native-ohos/react-native-reanimated 3.18.3 → 3.18.4-beta.2
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/CHANGELOG.md +1070 -0
- package/harmony/reanimated/BuildProfile.ets +1 -1
- package/harmony/reanimated/oh-package.json5 +1 -1
- package/harmony/reanimated/src/main/cpp/Common/cpp/reanimated/NativeModules/ReanimatedModuleProxy.cpp +2 -0
- package/harmony/reanimated/src/main/cpp/ReanimatedModule.cpp +7 -1
- package/harmony/reanimated/src/main/cpp/patches/NativeModules/ReanimatedModuleProxy.cpp +14 -0
- package/harmony/reanimated.har +0 -0
- package/package.json +18 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Use these variables when you tailor your ArkTS code. They must be of the const type.
|
|
3
3
|
*/
|
|
4
|
-
export const HAR_VERSION = '3.18.
|
|
4
|
+
export const HAR_VERSION = '3.18.4-beta.2';
|
|
5
5
|
export const BUILD_MODE_NAME = 'debug';
|
|
6
6
|
export const DEBUG = true;
|
|
7
7
|
export const TARGET_NAME = 'default';
|
|
@@ -600,6 +600,7 @@ void ReanimatedModuleProxy::cleanupSensors() {
|
|
|
600
600
|
void ReanimatedModuleProxy::markNodeAsRemovable(
|
|
601
601
|
jsi::Runtime &rt,
|
|
602
602
|
const jsi::Value &shadowNodeWrapper) {
|
|
603
|
+
auto lock = propsRegistry_->createLock();
|
|
603
604
|
auto shadowNode = shadowNodeFromValue(rt, shadowNodeWrapper);
|
|
604
605
|
propsRegistry_->markNodeAsRemovable(shadowNode);
|
|
605
606
|
}
|
|
@@ -607,6 +608,7 @@ void ReanimatedModuleProxy::markNodeAsRemovable(
|
|
|
607
608
|
void ReanimatedModuleProxy::unmarkNodeAsRemovable(
|
|
608
609
|
jsi::Runtime &rt,
|
|
609
610
|
const jsi::Value &viewTag) {
|
|
611
|
+
auto lock = propsRegistry_->createLock();
|
|
610
612
|
propsRegistry_->unmarkNodeAsRemovable(viewTag.asNumber());
|
|
611
613
|
}
|
|
612
614
|
|
|
@@ -44,13 +44,18 @@ ReanimatedModule::ReanimatedModule(const ArkTSTurboModule::Context ctx, const st
|
|
|
44
44
|
|
|
45
45
|
ReanimatedModule::~ReanimatedModule()
|
|
46
46
|
{
|
|
47
|
-
|
|
47
|
+
const bool isOnMain = m_ctx.taskExecutor &&
|
|
48
|
+
m_ctx.taskExecutor->isOnTaskThread(TaskThread::MAIN);
|
|
49
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=module_dtor_begin"
|
|
50
|
+
<< " on_main=" << isOnMain
|
|
51
|
+
<< " proxy_alive=" << static_cast<bool>(weakNativeReanimatedModule_.lock());
|
|
48
52
|
if (eventListener) {
|
|
49
53
|
m_ctx.scheduler->removeEventListener(eventListener);
|
|
50
54
|
}
|
|
51
55
|
if (keyboardEventDataUpdater_) {
|
|
52
56
|
keyboardEventDataUpdater_ = nullptr;
|
|
53
57
|
}
|
|
58
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=module_dtor_complete";
|
|
54
59
|
}
|
|
55
60
|
|
|
56
61
|
void ReanimatedModule::installTurboModule(facebook::jsi::Runtime &rt)
|
|
@@ -199,6 +204,7 @@ void ReanimatedModule::installTurboModule(facebook::jsi::Runtime &rt)
|
|
|
199
204
|
auto nativeReanimatedModule = std::make_shared<ReanimatedModuleProxy>(workletsModuleProxy,
|
|
200
205
|
rt, jsInvoker_, platformDepMethodsHolder, isBridgeless, isReducedMotion);
|
|
201
206
|
weakNativeReanimatedModule_ = nativeReanimatedModule;
|
|
207
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=proxy_installed";
|
|
202
208
|
nativeReanimatedModule->init(platformDepMethodsHolder);
|
|
203
209
|
ReanimatedPerformOperations reanimatedPerformOperations = [weakNativeReanimatedModule =
|
|
204
210
|
weakNativeReanimatedModule_]() {
|
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
#endif // RCT_NEW_ARCH_ENABLED
|
|
28
28
|
|
|
29
29
|
#include <functional>
|
|
30
|
+
#include <glog/logging.h>
|
|
30
31
|
#include <utility>
|
|
31
32
|
|
|
32
33
|
#ifdef RCT_NEW_ARCH_ENABLED
|
|
@@ -228,6 +229,14 @@ void ReanimatedModuleProxy::init(
|
|
|
228
229
|
}
|
|
229
230
|
|
|
230
231
|
ReanimatedModuleProxy::~ReanimatedModuleProxy() {
|
|
232
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=proxy_dtor"
|
|
233
|
+
<< " frame_callbacks=" << frameCallbacks_.size()
|
|
234
|
+
#ifdef RCT_NEW_ARCH_ENABLED
|
|
235
|
+
<< " pending_operations=" << operationsInBatch_.size()
|
|
236
|
+
<< " props_registry=" << static_cast<bool>(propsRegistry_)
|
|
237
|
+
<< " layout_proxy=" << static_cast<bool>(layoutAnimationsProxy_)
|
|
238
|
+
#endif
|
|
239
|
+
;
|
|
231
240
|
// event handler registry and frame callbacks store some JSI values from UI
|
|
232
241
|
// runtime, so they have to go away before we tear down the runtime
|
|
233
242
|
eventHandlerRegistry_.reset();
|
|
@@ -286,9 +295,12 @@ ReanimatedModuleProxy::~ReanimatedModuleProxy() {
|
|
|
286
295
|
// UIManager(及 ComponentDescriptorRegistry)仍存活
|
|
287
296
|
commitHook_.reset();
|
|
288
297
|
mountHook_.reset();
|
|
298
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=fabric_hooks_removed";
|
|
289
299
|
uiManager_.reset();
|
|
290
300
|
#endif // RCT_NEW_ARCH_ENABLED
|
|
301
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=ui_runtime_reset_begin";
|
|
291
302
|
uiWorkletRuntime_.reset();
|
|
303
|
+
LOG(WARNING) << "[RNOH_REA_TEARDOWN_V1] stage=proxy_dtor_complete";
|
|
292
304
|
}
|
|
293
305
|
|
|
294
306
|
void ReanimatedModuleProxy::scheduleOnUI(
|
|
@@ -653,6 +665,7 @@ void ReanimatedModuleProxy::cleanupSensors() {
|
|
|
653
665
|
void ReanimatedModuleProxy::markNodeAsRemovable(
|
|
654
666
|
jsi::Runtime &rt,
|
|
655
667
|
const jsi::Value &shadowNodeWrapper) {
|
|
668
|
+
auto lock = propsRegistry_->createLock();
|
|
656
669
|
auto shadowNode = shadowNodeFromValue(rt, shadowNodeWrapper);
|
|
657
670
|
propsRegistry_->markNodeAsRemovable(shadowNode);
|
|
658
671
|
}
|
|
@@ -660,6 +673,7 @@ void ReanimatedModuleProxy::markNodeAsRemovable(
|
|
|
660
673
|
void ReanimatedModuleProxy::unmarkNodeAsRemovable(
|
|
661
674
|
jsi::Runtime &rt,
|
|
662
675
|
const jsi::Value &viewTag) {
|
|
676
|
+
auto lock = propsRegistry_->createLock();
|
|
663
677
|
propsRegistry_->unmarkNodeAsRemovable(viewTag.asNumber());
|
|
664
678
|
}
|
|
665
679
|
|
package/harmony/reanimated.har
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
"alias": "react-native-reanimated",
|
|
5
5
|
"redirectInternalImports": true
|
|
6
6
|
},
|
|
7
|
-
"version": "3.18.
|
|
8
|
-
"description": "",
|
|
7
|
+
"version": "3.18.4-beta.2",
|
|
8
|
+
"description": "More powerful alternative to Animated library for React Native.",
|
|
9
9
|
"main": "lib/index.js",
|
|
10
10
|
"scripts": {
|
|
11
11
|
"build": "tsc",
|
|
@@ -46,6 +46,20 @@
|
|
|
46
46
|
"lib",
|
|
47
47
|
"harmony",
|
|
48
48
|
"src",
|
|
49
|
-
"./harmony.tar.gz"
|
|
50
|
-
|
|
49
|
+
"./harmony.tar.gz",
|
|
50
|
+
"CHANGELOG.md",
|
|
51
|
+
"!build"
|
|
52
|
+
],
|
|
53
|
+
"publishConfig": {
|
|
54
|
+
"access": "public",
|
|
55
|
+
"registry": "https://registry.npmjs.org/"
|
|
56
|
+
},
|
|
57
|
+
"homepage": "https://gitcode.com/CPF-RN/rntpc_react-native-reanimated",
|
|
58
|
+
"bugs": {
|
|
59
|
+
"url": "https://gitcode.com/CPF-RN/rntpc_react-native-reanimated/issues"
|
|
60
|
+
},
|
|
61
|
+
"repository": {
|
|
62
|
+
"type": "git",
|
|
63
|
+
"url": "https://gitcode.com/CPF-RN/rntpc_react-native-reanimated.git"
|
|
64
|
+
}
|
|
51
65
|
}
|