-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
# Description - Elm-architecture-inspired event iterator - The previous version populated the epoll event data with a pointer. This pointer was a function pointer to an implementation of a wayland message handler. When processing messages / events this then happens in a relatively hidden fashion. Particularly code navigation will be hampered and the code generally harder to understand. - This change replaces the function pointer dispatch with a data / iterator approach. When we have activity on some subsystem(s) epoll will wake up and return an event iterator. Each call to `.next()` will return a new event (or null). We will exhaust all events for a given subsystem before moving onto another subsystem that has activity. - We exchange a function call (with the function pointers) with returning a data structure for each event. - Those events are then dispatched by `switch`ing on the event. - In this way we end up with a very straightforward dispatch method that is very explicit in the code and easy to reason about / navigate over. - Resource allocation has been reworked. - Previously resources (clients, window, regions, etc.) were statically allocated. - This has been replaced with `IterablePool` and `SubsetPool`. These allocate on startup but not thereafter. - The wayland protocol implementation is completely rewritten to provide way better type safety with an explicit `union` of wayland objects and messages. - The protocol generator has been rewritten in zig (using https://github.com/mitchellh/zig-build-libxml2 for XML parsing) so that we can jettison the `python` dependency. The generator is currently at https://github.com/malcolmstill/foxwhale-gen. I think I'll move the generator code into this repo, but will wait for mitchellh/zig-build-libxml2#3 so I don't have to vendor to include the changes in that PR # Closes - Closes #59 - Closes #58 - Closes #44 - Closes #11 # Follow ups - Reimplement DRM/KMS backend
- Loading branch information
1 parent
51b7057
commit f4c5b8e
Showing
82 changed files
with
14,079 additions
and
10,500 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
.{ | ||
.name = "foxwhale", | ||
// This is a [Semantic Version](https://semver.org/). | ||
// In a future version of Zig it will be used for package deduplication. | ||
.version = "0.0.0", | ||
|
||
// This field is optional. | ||
// This is currently advisory only; Zig does not yet do anything | ||
// with this value. | ||
//.minimum_zig_version = "0.11.0", | ||
|
||
// This field is optional. | ||
// Each dependency must either provide a `url` and `hash`, or a `path`. | ||
// `zig build --fetch` can be used to fetch all dependencies of a package, recursively. | ||
// Once all dependencies are fetched, `zig build` no longer requires | ||
// internet connectivity. | ||
.dependencies = .{ | ||
// See `zig fetch --save <url>` for a command-line interface for adding dependencies. | ||
.foxwhale_gen = .{ | ||
// When updating this field to a new URL, be sure to delete the corresponding | ||
// `hash`, otherwise you are communicating that you expect to find the old hash at | ||
// the new URL. | ||
.url = "https://github.com/malcolmstill/foxwhale-gen/archive/21c0f17c7d2258fcdf0819866d4cf4c784f00213.tar.gz", | ||
|
||
// This is computed from the file contents of the directory of files that is | ||
// obtained after fetching `url` and applying the inclusion rules given by | ||
// `paths`. | ||
// | ||
// This field is the source of truth; packages do not come from a `url`; they | ||
// come from a `hash`. `url` is just one of many possible mirrors for how to | ||
// obtain a package matching this `hash`. | ||
// | ||
// Uses the [multihash](https://multiformats.io/multihash/) format. | ||
.hash = "122006b5217a03a29dab5ffc6040814e9cf3da85de6553177d72cd00a7d61584634b", | ||
|
||
// When this is provided, the package is found in a directory relative to the | ||
// build root. In this case the package's hash is irrelevant and therefore not | ||
// computed. This field and `url` are mutually exclusive. | ||
// .path = "foo", | ||
}, | ||
}, | ||
|
||
// Specifies the set of files and directories that are included in this package. | ||
// Only files and directories listed here are included in the `hash` that | ||
// is computed for this package. | ||
// Paths are relative to the build root. Use the empty string (`""`) to refer to | ||
// the build root itself. | ||
// A directory listed here means that all files within, recursively, are included. | ||
.paths = .{ | ||
// This makes *all* files, recursively, included in this package. It is generally | ||
// better to explicitly list the files and directories instead, to insure that | ||
// fetching from tarballs, file system paths, and version control all result | ||
// in the same contents hash. | ||
"", | ||
// For example... | ||
//"build.zig", | ||
//"build.zig.zon", | ||
//"src", | ||
//"LICENSE", | ||
//"README.md", | ||
}, | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.