Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(174)

Side by Side Diff: sky/tests/styles/transforms.sky

Issue 969893002: Make removing a transform not crash. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sky/engine/core/rendering/RenderBox.cpp ('k') | sky/tests/styles/transforms-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <style> 1 <style>
2 .container { 2 .container {
3 height: 100px; 3 height: 100px;
4 width: 200px; 4 width: 200px;
5 margin: 30px; 5 margin: 30px;
6 outline: 1px solid black; 6 outline: 1px solid black;
7 } 7 }
8 .box { 8 .box {
9 height: 100%; 9 height: 100%;
10 width: 100%; 10 width: 100%;
(...skipping 30 matching lines...) Expand all
41 testTransformRoundTrip('translate(80px, 90px)', 'matrix(1, 0, 0, 1, 80, 90 )'); 41 testTransformRoundTrip('translate(80px, 90px)', 'matrix(1, 0, 0, 1, 80, 90 )');
42 }); 42 });
43 43
44 test('percent translate should roundtrip', () { 44 test('percent translate should roundtrip', () {
45 testTransformRoundTrip('translate(10px, 50%)', 'matrix(1, 0, 0, 1, 10, 60) '); 45 testTransformRoundTrip('translate(10px, 50%)', 'matrix(1, 0, 0, 1, 10, 60) ');
46 }); 46 });
47 47
48 test('scale should roundtrip', () { 48 test('scale should roundtrip', () {
49 testTransformRoundTrip('scale(1.2, 0.8)', 'matrix(1.2, 0, 0, 0.8, 0, 0)'); 49 testTransformRoundTrip('scale(1.2, 0.8)', 'matrix(1.2, 0, 0, 0.8, 0, 0)');
50 }); 50 });
51
52 test('removing a transform should not crash', () {
53 testBox.style['transform'] = 'translate(0, 0, 0)';
54 testBox.getBoundingClientRect();
55 testBox.style.removeProperty('transform');
56 testBox.getBoundingClientRect();
57 });
51 } 58 }
52 </script> 59 </script>
OLDNEW
« no previous file with comments | « sky/engine/core/rendering/RenderBox.cpp ('k') | sky/tests/styles/transforms-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698