-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Labels
enhancementNew feature or requestNew feature or request
Description
A native component I'm trying to reuse for React Native migration has multiple inheritance. A simplified code is like the following.
public interface INative1
{
void method1();
}
public interface INative2: public INative1
{
void method2();
}
public class Native: public INative2 {}
With this setup, only method2() is projected to JavaScript, and method1() is unavailable. The following code is not traversing up the inheritance chain but only looking through the direct parents. ☹
react-native-winrt-main\rnwinrt\rnwinrt\react\strings\base.cpp
projected_object_instance::projected_object_instance(const winrt::IInspectable& instance) : m_instance(instance)
{
auto iids = winrt::get_interfaces(m_instance); <<<< Getting direct parents.
for (auto&& iid : iids)
{
if (auto iface = find_interface(iid))
{
m_interfaces.push_back(iface); <<<< Not pushing back the ancestors of the direct parent interface.
}
}
}
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request