@Test public void testUpdateProperties(){ testBind(); Map<String, Object> prop = new HashMap<>(); prop.put(WXDomPropConstant.WX_ATTR_DISABLED, "false"); prop.put(WXDomPropConstant.WX_OPACITY, 0.8f); mWXText.updateProperties(prop); assertTrue(mWXText.getView().isEnabled()); assertTrue(mWXText.getView().getAlpha()>=0.799 && mWXText.getView().getAlpha()<=0.811); prop.put(WXDomPropConstant.WX_ATTR_DISABLED, "true"); mWXText.updateProperties(prop); assertFalse(mWXText.getView().isEnabled()); }
@Override public WXTextView getView() { return (WXTextView) super.getView(); }
WXText extends WXComponent { @Override public WXTextView getView() { return (WXTextView) super.getView(); } }
WXText extends WXComponent { @Override public WXTextView getView() { return (WXTextView) super.getView(); } WXText(WXSDKInstance instance, WXDomObject node,
                WXVContainer parent, boolean lazy); }
WXText extends WXComponent { @Override public WXTextView getView() { return (WXTextView) super.getView(); } WXText(WXSDKInstance instance, WXDomObject node,
                WXVContainer parent, boolean lazy); @Override WXTextView getView(); @Override void updateExtra(Object extra); }
WXText extends WXComponent { @Override public WXTextView getView() { return (WXTextView) super.getView(); } WXText(WXSDKInstance instance, WXDomObject node,
                WXVContainer parent, boolean lazy); @Override WXTextView getView(); @Override void updateExtra(Object extra); static final int sDEFAULT_SIZE; }