1112 Commits

Author SHA1 Message Date
Adam Barth
dea3a0922c Add package:sky/rendering.dart
Similar to widgets.dart, rendering.dart exports the entire rendering layer.
Also, update the examples to use rendering.dart and widgets.dart. Also clean up
some exports so that the examples have more sensible imports.
2015-08-18 21:39:51 -07:00
Adam Barth
ce8f75dac8 Merge pull request #684 from abarth/explode_box
Split box.dart into many files
2015-08-18 21:04:58 -07:00
Adam Barth
50bfdedbf4 Split box.dart into many files
Sadly, box.dart has grown much longer than 1000 lines. This patch splits it up
into several files based on the class hierarchy. Fortunately, many of these
classes are loosely coupled to each other.
2015-08-18 20:55:32 -07:00
Ian Hickson
1418d271ed Update README.md 2015-08-18 20:53:16 -07:00
Ian Hickson
e4f6a417df Update README.md 2015-08-18 20:51:48 -07:00
Adam Barth
5b40e03129 RenderImage should handle the case of a null image
When given a null image, RenderImage should be as small as possible (isntead of
being NaNxNaN).

Also, plumb ImageFit and ImageRepeat through the various image widgets.
2015-08-18 20:05:52 -07:00
Adam Barth
6cc103cf07 Borders on Containers shouldn't overlap the content
This CL inflates the padding of Container to account for the borders so that
the borders are allocated space in the layout and don't draw behind the
Container's child.
2015-08-18 16:10:40 -07:00
Collin Jackson
a16ee23f0e Merge pull request #678 from collinjackson/gridlines
Request gridlines for fitness chart
2015-08-18 15:46:26 -07:00
Adam Barth
b7421fcbf1 Improve RenderImage constraint solving
We now fold the width and height properties into the constraints and try to
find a size for the image that perserves the image's intrinsict aspect ratio
while fitting within the given constraints.
2015-08-18 15:23:04 -07:00
Collin Jackson
429c39455d Request gridlines for fitness chart 2015-08-18 15:15:49 -07:00
Adam Barth
39ca4fa1ce Merge pull request #672 from abarth/render_image_fit
Apply ImageFit and ImageRepeat to RenderImage
2015-08-18 11:12:00 -07:00
Adam Barth
0ad2c11cc6 Apply ImageFit and ImageRepeat to RenderImage
These properties should apply to foreground images as well as background
images. Also, rename these types from BackgroundFit and BackgroundRepeat
because they apply to things other than backgrounds.
2015-08-18 11:11:31 -07:00
Viktor Lidholt
d9c743e1c5 Fixes loading of assets in demo game 2015-08-18 10:33:34 -07:00
Adam Barth
66c2cc2ae1 Merge pull request #670 from abarth/expand_dimension
Container should expand in dimensions without constraints
2015-08-18 10:07:23 -07:00
Adam Barth
516616aaf6 Container should expand in dimensions without constraints
... as long as it doesn't have a child. If it has a child, it should size
according to that child. Essentially, if Container doesn't have a child, it
pretends like it has a child that expands to fill its constraints.
2015-08-18 10:06:49 -07:00
Viktor Lidholt
882f32bb95 Merge pull request #666 from vlidholt/master
Adds bounce and elastic easing to animation curves
2015-08-18 09:37:02 -07:00
Viktor Lidholt
b9629155c4 Minor fixes to new animation curves 2015-08-18 09:34:07 -07:00
Hixie
e4ac518908 Port clipping to the new layer world.
- Add Canvas.getSaveCount()
- Make RenderClipRect call context.paintChildWithClip instead of doing the clipping itself
- Make ClipLayer take a Rect instead of a Size
- Make PaintingContext.canvas read-only
- Add PaintingContext.paintChildWithClip()
- Minor rearrangings of code and style tweaks
2015-08-18 08:34:42 -07:00
Eric Seidel
db3d632a5a Add release notes for SkyDemo.apk 0.0.23 2015-08-17 18:00:10 -07:00
Eric Seidel
f714ec6bca Add release notes for Fitness 0.0.3
@collinjackson
2015-08-17 17:51:50 -07:00
Eric Seidel
b3947162ff Make Asteroids.apk use background music from its bundle
This was the last instance of loading assets off of Github.

@abarth
2015-08-17 17:10:38 -07:00
Viktor Lidholt
9cb2cdacba Updates demo game to use curves from the animation package 2015-08-17 17:07:55 -07:00
Viktor Lidholt
dafaddff89 Adds bounce and elastic easing to animation curves 2015-08-17 17:07:30 -07:00
Eric Seidel
ba7b9db5f9 Merge pull request #660 from eseidelGoogle/sounds_bundle
Teach Asteroids Sounds how to load from AssetBundle
2015-08-17 16:15:06 -07:00
Ian Hickson
9b1addf54c Merge pull request #646 from Hixie/animations
Trivial code changes for style and readability in animation/ directory.
2015-08-17 16:08:23 -07:00
Ian Hickson
6287d877b0 Merge pull request #641 from Hixie/dependencies
Update READMEs for painting/ and animation/ to be up to date with current dependencies.
2015-08-17 16:08:19 -07:00
Ian Hickson
5213451142 Merge pull request #640 from Hixie/lerp-whitespace
Improve style in lerp.dart and box_painter.dart
2015-08-17 16:08:12 -07:00
Eric Seidel
67c481b2ef Teach Asteroids Sounds how to load from AssetBundle
@abarth
2015-08-17 16:07:08 -07:00
Collin Jackson
4cae568fec Move inheritedOfType from Component to Widget so that Switch can use it 2015-08-17 15:03:21 -07:00
Eric Seidel
74a14d2aca Merge pull request #659 from eseidelGoogle/analyzer
Fix analyzer warnings
2015-08-17 14:34:54 -07:00
Eric Seidel
d5fe622a22 Fix analyzer warnings
We had a remarkable number of analyzer failures.

I'll fix the bots to analyze across the whole project
in a follow-up patch, that should prevent this
in the future.

@abarth
2015-08-17 14:32:29 -07:00
Adam Barth
91a783bf62 Rename Widget.root to Widget.renderObject
The name `root` is confusing because this value isn't the root of anything.
It's just the associated `RenderObject` instance.
2015-08-17 14:15:26 -07:00
Adam Barth
46fc8e6a21 Merge pull request #653 from abarth/drag_target
Add support for drag-and-drop
2015-08-17 14:06:35 -07:00
Adam Barth
ac0ec3221b Add support for drag-and-drop
Widgets that want to receive drops should include a DropTarget in their build.
Currently there's no widget for initiating a drag. Components can use the
DragController directly. In the future, we'll probably want to add a Draggable
that knows how to do some of this work automatically.

Fixes #612
2015-08-17 14:06:19 -07:00
Adam Barth
fca0c3c929 Merge pull request #650 from Hixie/theme
Trivial documentation for files in theme/.
2015-08-17 13:30:36 -07:00
Adam Barth
d19d4ee37d Merge pull request #649 from Hixie/mojo-README
Add a trivial README for the mojo/ directory in the SDK.
2015-08-17 13:30:21 -07:00
Hixie
73c4f8adbf Add a trivial README for the mojo/ directory in the SDK. 2015-08-17 12:55:53 -07:00
Viktor Lidholt
f49a490dc0 Adds SoundManager class 2015-08-17 12:49:32 -07:00
Hixie
d867b8ab02 Trivial documentation for files in theme/. 2015-08-17 12:49:06 -07:00
Eric Seidel
f19fee31e2 Roll Fitness and SkyDemo in preparation for release
@abarth
2015-08-17 12:46:30 -07:00
Viktor Lidholt
23aabee8ae Merge pull request #638 from vlidholt/master
Adds a new ActionDelay class to sprites
2015-08-17 12:43:30 -07:00
Hixie
49b43e2e0f Trivial code changes for style in animation/ directory. 2015-08-17 12:35:02 -07:00
Hixie
067fbd5041 Update READMEs for painting/ and animation/ to be up to date with current dependencies. 2015-08-17 10:53:06 -07:00
Hixie
789064a433 Tweak box_painter.dart to match style better. 2015-08-17 10:52:05 -07:00
Hixie
a24c32fcf6 Fix spaces in lerp.dart to match style better. 2015-08-17 10:24:58 -07:00
Viktor Lidholt
d028875510 Adds a new ActionDelay class to sprites 2015-08-17 09:23:13 -07:00
Adam Barth
183ea1042e Merge pull request #625 from abarth/less_grey
Don't grey out Sky code in Atom
2015-08-14 15:40:35 -07:00
Adam Barth
a94d398847 Don't grey out Sky code in Atom
For some reason having |packages| in this .gitignore file is causing Atom to
grey out all the files in the Sky package. Moving the entry up to the root of
the git repo fixes the issue.
2015-08-14 15:39:09 -07:00
Chinmay Garde
6794429ec5 Merge pull request #624 from chinmaygarde/master
Add iOS sky_app target for the fitness app example
2015-08-14 15:34:48 -07:00
Chinmay Garde
99b68e3139 Add iOS sky_app target for the fitness app example 2015-08-14 15:07:20 -07:00