Skip to content

Commit bde23b1

Browse files
committed
adapts the new rnoh code
1 parent 6c1795b commit bde23b1

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

harmony/smart_refresh_layout.har

-48 Bytes
Binary file not shown.

harmony/smart_refresh_layout/src/main/cpp/PullToRefreshNode.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ namespace rnoh {
2323
auto columnHandle = NativeNodeApi::getInstance()->createNode(ArkUI_NodeType::ARKUI_NODE_COLUMN);
2424
m_listArkUINodeHandle = NativeNodeApi::getInstance()->createNode(ArkUI_NodeType::ARKUI_NODE_STACK);
2525

26-
uint32_t colorValue1 = 0xFFFFFFFF
26+
uint32_t colorValue1 = 0xFFFFFFFF;
2727
ArkUI_NumberValue preparedColorValue1[] = {{.u32 = colorValue1}};
2828
ArkUI_AttributeItem colorItem1 = {preparedColorValue1, sizeof(preparedColorValue1) / sizeof(ArkUI_NumberValue)};
2929
NativeNodeApi::getInstance()->setAttribute(m_listArkUINodeHandle, NODE_BACKGROUND_COLOR, &colorItem1);

harmony/smart_refresh_layout/src/main/cpp/SmartRefreshLayoutPackage.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@ namespace rnoh {
3737

3838
ComponentInstance::Shared create(ComponentInstance::Context ctx) override {
3939
if (ctx.componentName == "RNCAnyHeader") {
40-
return std::make_shared<RNCAnyHeaderComponentInstance>(std::move(ctx));
40+
return std::make_shared<RNCAnyHeaderComponentInstance>(ctx);
4141
} else if (ctx.componentName == "SmartRefreshLayout") {
42-
return std::make_shared<SmartRefreshLayoutComponentInstance>(std::move(ctx));
42+
return std::make_shared<SmartRefreshLayoutComponentInstance>(ctx);
4343
}
4444
return nullptr;
4545
}
@@ -50,7 +50,7 @@ namespace rnoh {
5050
SmartRefreshLayoutPackage(Package::Context ctx) : Package(ctx) {}
5151

5252
ComponentInstanceFactoryDelegate::Shared createComponentInstanceFactoryDelegate() override {
53-
return std::make_shared<SmartRefreshLayoutPackageComponentInstanceFactoryDelegate>();
53+
return std::make_shared<SmartRefreshLayoutPackageComponentInstanceFactoryDelegate>(m_ctx);
5454
}
5555

5656
std::vector<facebook::react::ComponentDescriptorProvider> createComponentDescriptorProviders() override {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@react-native-oh-tpl/react-native-smartrefreshlayout",
3-
"version": "0.6.7-0.2.2",
3+
"version": "0.6.7-0.2.3",
44
"description": "基于android SmartRefreshLayout的封装",
55
"harmony": {
66
"alias": "react-native-smartrefreshlayout"

0 commit comments

Comments
 (0)