mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Update GeneratePropsJavaDelegate to handle PlatformColor
Summary: $title Changelog: [Internal] (Note: this ignores all push blocking failures!) Reviewed By: rickhanlonii Differential Revision: D20175915 fbshipit-source-id: 96d75e8cc098ea6ce78288f40191f7bae24d5aa5
This commit is contained in:
committed by
Facebook Github Bot
parent
f4de45800f
commit
03ac8e872e
+2
-2
@@ -106,7 +106,7 @@ function getJavaValueForProp(
|
||||
case 'NativePrimitiveTypeAnnotation':
|
||||
switch (typeAnnotation.name) {
|
||||
case 'ColorPrimitive':
|
||||
return 'value == null ? null : ((Double) value).intValue()';
|
||||
return 'ColorPropConverter.getColor(value, view.getContext())';
|
||||
case 'ImageSourcePrimitive':
|
||||
return '(ReadableMap) value';
|
||||
case 'PointPrimitive':
|
||||
@@ -230,7 +230,7 @@ function getClassExtendString(component): string {
|
||||
}
|
||||
|
||||
function getDelegateImports(component) {
|
||||
const imports = getImports(component);
|
||||
const imports = getImports(component, 'delegate');
|
||||
// The delegate needs ReadableArray for commands always.
|
||||
// The interface doesn't always need it
|
||||
if (component.commands.length > 0) {
|
||||
|
||||
Reference in New Issue
Block a user