OLD | NEW |
(Empty) | |
| 1 |
| 2 class _CSSStyleSheetImpl extends _StyleSheetImpl implements CSSStyleSheet { |
| 3 _CSSStyleSheetImpl._wrap(ptr) : super._wrap(ptr); |
| 4 |
| 5 CSSRuleList get cssRules() => _wrap(_ptr.cssRules); |
| 6 |
| 7 CSSRule get ownerRule() => _wrap(_ptr.ownerRule); |
| 8 |
| 9 CSSRuleList get rules() => _wrap(_ptr.rules); |
| 10 |
| 11 int addRule(String selector, String style, [int index = null]) { |
| 12 if (index === null) { |
| 13 return _wrap(_ptr.addRule(_unwrap(selector), _unwrap(style))); |
| 14 } else { |
| 15 return _wrap(_ptr.addRule(_unwrap(selector), _unwrap(style), _unwrap(index
))); |
| 16 } |
| 17 } |
| 18 |
| 19 void deleteRule(int index) { |
| 20 _ptr.deleteRule(_unwrap(index)); |
| 21 return; |
| 22 } |
| 23 |
| 24 int insertRule(String rule, int index) { |
| 25 return _wrap(_ptr.insertRule(_unwrap(rule), _unwrap(index))); |
| 26 } |
| 27 |
| 28 void removeRule(int index) { |
| 29 _ptr.removeRule(_unwrap(index)); |
| 30 return; |
| 31 } |
| 32 } |
OLD | NEW |