瀏覽代碼

Fix contextual menu wrong index (#541)

Guy Carmeli 8 年之前
父節點
當前提交
e948eb8cb8

+ 1
- 1
android/app/src/main/java/com/reactnativenavigation/params/parsers/ContextualMenuButtonParamsParser.java 查看文件

@@ -24,7 +24,7 @@ public class ContextualMenuButtonParamsParser extends TitleBarButtonParamsParser
24 24
         result.showAsAction = parseShowAsAction(button.getString("showAsAction"));
25 25
         result.color = StyleParams.Color.parse(button, "color");
26 26
         result.label = button.getString("label");
27
-        result.index = (int) button.getDouble("index");
27
+        result.index = button.getInt("index");
28 28
         return result;
29 29
     }
30 30
 }