diff options
author | Jonathan Duran | 2012-05-11 14:13:07 -0700 |
---|---|---|
committer | Jonathan Duran | 2012-05-11 14:13:07 -0700 |
commit | 1e2138fc7d0007b0ad3cb4807dc1c9101190f2f2 (patch) | |
tree | 2563aa7694c3caaf813ca71ef3250b2a76ee0041 /js/controllers/styles-controller.js | |
parent | 32257ac142f872d3c1f6c07504bae77ae884ed93 (diff) | |
parent | 6fcaa4e923a19672b5860b4c6f67d836680e7e99 (diff) | |
download | ninja-1e2138fc7d0007b0ad3cb4807dc1c9101190f2f2.tar.gz |
Merge branch 'refs/heads/TimelineUber' into TimelineProps
Diffstat (limited to 'js/controllers/styles-controller.js')
-rwxr-xr-x | js/controllers/styles-controller.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/js/controllers/styles-controller.js b/js/controllers/styles-controller.js index ec4314f9..2ff3e235 100755 --- a/js/controllers/styles-controller.js +++ b/js/controllers/styles-controller.js | |||
@@ -795,7 +795,9 @@ var stylesController = exports.StylesController = Montage.create(Component, { | |||
795 | ///// method to apply/test the new value | 795 | ///// method to apply/test the new value |
796 | dec.setProperty(property, value, priority); | 796 | dec.setProperty(property, value, priority); |
797 | 797 | ||
798 | this.styleSheetModified(rule.parentStyleSheet); | 798 | if(rule.parentStyleSheet) { |
799 | this.styleSheetModified(rule.parentStyleSheet); | ||
800 | } | ||
799 | 801 | ||
800 | ///// Return browser value for value we just set | 802 | ///// Return browser value for value we just set |
801 | return dec.getPropertyValue(property); | 803 | return dec.getPropertyValue(property); |
@@ -1102,7 +1104,7 @@ var stylesController = exports.StylesController = Montage.create(Component, { | |||
1102 | ///// The dominant rule might not have the style property defined - why? | 1104 | ///// The dominant rule might not have the style property defined - why? |
1103 | ///// If no rules have the property defined, we can use the | 1105 | ///// If no rules have the property defined, we can use the |
1104 | ///// most-specific single-target rule as the dominant rule (for setting styles) | 1106 | ///// most-specific single-target rule as the dominant rule (for setting styles) |
1105 | return element.ownerDocument.defaultView.getComputedStyle(element).getPropertyValue(property); | 1107 | return (element.ownerDocument.defaultView ? element.ownerDocument.defaultView.getComputedStyle(element).getPropertyValue(property) : null); |
1106 | } | 1108 | } |
1107 | 1109 | ||
1108 | return value; | 1110 | return value; |