Skip to content

Commit 26fab9b

Browse files
committed
update changes section of readme
1 parent ba58c7e commit 26fab9b

File tree

2 files changed

+59
-51
lines changed

2 files changed

+59
-51
lines changed

CHANGELOG.md

Lines changed: 46 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -21,48 +21,52 @@
2121
* Scene callbacks are all updated to support the OTP 21+ callback returns.
2222
* Scenes now have the terminate callback.
2323

24-
**Deprecations:**
25-
* `push_graph/1` is deprecated in favor of returning `{:push, graph}`
26-
([keyword](https://hexdocs.pm/elixir/Keyword.html)) options
27-
from the `Scenic.Scene` callbacks. Since this is only a deprecation `push_graph/1` will
28-
continue to work, but will log a warning when used. `push_graph/1` will be removed in a
29-
future release.
30-
* This allows us to utilize the full suite of OTP GenServer callback behaviors (such as
31-
timeout and `handle_continue`)
32-
* Replacing the call of `push_graph(graph)` within a callback function depends slightly
33-
on the context in which it is used.
34-
* in `init/2`:
35-
* `{:ok, state, [push: graph]}`
36-
* in `filter_event/3`:
37-
* `{:halt, state, [push: graph]}`
38-
* `{:cont, event, state, [push: graph]}`
39-
* in `handle_cast/2`:
40-
* `{:noreply, state, [push: graph]}`
41-
* in `handle_info/2`:
42-
* `{:noreply, state, [push: graph]}`
43-
* in `handle_call/3`:
44-
* `{:reply, reply, state, [push: graph]}`
45-
* `{:noreply, state, [push: graph]}`
46-
* in `handle_continue/3`:
47-
* `{:noreply, state, [push: graph]}`
48-
49-
**Breaking Changes:**
50-
* Breaking changes to Scenic.Cache. It has been replaced by asset specific caches.
51-
52-
| Asset Class | Module |
53-
| ------------- | -----|
54-
| Fonts | `Scenic.Cache.Static.Font` |
55-
| Font Metrics | `Scenic.Cache.Static.FontMetrics` |
56-
| Textures (images in a fill) | `Scenic.Cache.Static.Texture` |
57-
| Raw Pixel Maps | `Scenic.Cache.Dynamic.Texture` |
58-
59-
Some of the Cache support modules have moved
60-
61-
| Old Module | New Module |
62-
| ------------- | -----|
63-
| `Scenic.Cache.Hash` | `Scenic.Cache.Support.Hash` |
64-
| `Scenic.Cache.File` | `Scenic.Cache.Support.File` |
65-
| `Scenic.Cache.Supervisor` | `Scenic.Cache.Support.Supervisor` |
24+
### Deprecations
25+
26+
`push_graph/1` is deprecated in favor of returning `{:push, graph}`
27+
([keyword](https://hexdocs.pm/elixir/Keyword.html)) options
28+
from the `Scenic.Scene` callbacks. Since this is only a deprecation `push_graph/1` will
29+
continue to work, but will log a warning when used.
30+
31+
`push_graph/1` will be removed in a future release.
32+
33+
* This allows us to utilize the full suite of OTP GenServer callback behaviors (such as
34+
timeout and `handle_continue`)
35+
* Replacing the call of `push_graph(graph)` within a callback function depends slightly
36+
on the context in which it is used.
37+
* in `init/2`:
38+
* `{:ok, state, [push: graph]}`
39+
* in `filter_event/3`:
40+
* `{:halt, state, [push: graph]}`
41+
* `{:cont, event, state, [push: graph]}`
42+
* in `handle_cast/2`:
43+
* `{:noreply, state, [push: graph]}`
44+
* in `handle_info/2`:
45+
* `{:noreply, state, [push: graph]}`
46+
* in `handle_call/3`:
47+
* `{:reply, reply, state, [push: graph]}`
48+
* `{:noreply, state, [push: graph]}`
49+
* in `handle_continue/3`:
50+
* `{:noreply, state, [push: graph]}`
51+
52+
### Breaking Changes
53+
54+
Scenic.Cache has been removed. It has been replaced by asset specific caches.
55+
56+
| Asset Class | Module |
57+
| ------------- | -----|
58+
| Fonts | `Scenic.Cache.Static.Font` |
59+
| Font Metrics | `Scenic.Cache.Static.FontMetrics` |
60+
| Textures (images in a fill) | `Scenic.Cache.Static.Texture` |
61+
| Raw Pixel Maps | `Scenic.Cache.Dynamic.Texture` |
62+
63+
Some of the Cache support modules have moved
64+
65+
| Old Module | New Module |
66+
| ------------- | -----|
67+
| `Scenic.Cache.Hash` | `Scenic.Cache.Support.Hash` |
68+
| `Scenic.Cache.File` | `Scenic.Cache.Support.File` |
69+
| `Scenic.Cache.Supervisor` | `Scenic.Cache.Support.Supervisor` |
6670

6771

6872
## 0.9.0

README.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -95,18 +95,22 @@ continue to work, but will log a warning when used.
9595

9696
### Breaking Changes
9797

98-
##### Changes to the Cache
98+
Scenic.Cache has been removed. It has been replaced by asset specific caches.
9999

100-
The most important (and immediate) change you need to deal with is to the cache. In order to handle static items with different life-cycle requirements, the cache has been broken out into multiple smaller caches, each for a specific type of content.
100+
| Asset Class | Module |
101+
| ------------- | -----|
102+
| Fonts | `Scenic.Cache.Static.Font` |
103+
| Font Metrics | `Scenic.Cache.Static.FontMetrics` |
104+
| Textures (images in a fill) | `Scenic.Cache.Static.Texture` |
105+
| Raw Pixel Maps | `Scenic.Cache.Dynamic.Texture` |
101106

102-
The module `Scenic.Cache` is gone and should be replace with the appropriate cache in your code.
107+
Some of the Cache support modules have moved
103108

104-
| Asset Type | Module |
105-
| --- | --- |
106-
| Static Textures | `Scenic.Cache.Static.Texture` |
107-
| Fonts | `Scenic.Cache.Static.Font` |
108-
| Font Metrics | `Scenic.Cache.Static.FontMetrics` |
109-
| Dynamic Textures | `Scenic.Cache.Dynamic.Texture` |
109+
| Old Module | New Module |
110+
| ------------- | -----|
111+
| `Scenic.Cache.Hash` | `Scenic.Cache.Support.Hash` |
112+
| `Scenic.Cache.File` | `Scenic.Cache.Support.File` |
113+
| `Scenic.Cache.Supervisor` | `Scenic.Cache.Support.Supervisor` |
110114

111115
##### Static vs. Dynamic Caches
112116

0 commit comments

Comments
 (0)