Commit graph

49655 commits

Author SHA1 Message Date
Karol Kosek
0b110c88ae PDFViewer: Propagate errors from PDFViewerWidget::initialize_menubar() 2023-04-20 17:02:23 +01:00
Karol Kosek
41cf3b741f HexEditor: Propagate errors from HexEditorWidget::initialize_menubar() 2023-04-20 17:02:23 +01:00
Karol Kosek
abe5787126 CharacterMap: Propagate errors from initialize_menubar() 2023-04-20 17:02:23 +01:00
Linus Groh
b4f78760f2 LibWeb/HTML: Store NonnullGCPtr in browsing context group set
These are never supposed to be null.
2023-04-20 16:47:57 +01:00
Linus Groh
4ee72420e8 LibWeb/HTML: Store NonnullGCPtr in browsing context set
These are never supposed to be null.
2023-04-20 16:47:53 +01:00
Fabian Dellwing
af20b74a83 Ports: Add more supported functions to README 2023-04-20 11:50:27 +02:00
Fabian Dellwing
47c5b77116 Ports: Update zsh 2023-04-20 11:50:27 +02:00
Tim Ledbetter
8b6c538f2a Chess: Gracefully handle ChessEngine disconnections
The GUI now tracks when it becomes disconnected from ChessEngine.
If not currently waiting for a move from ChessEngine, it will
automatically reconnect on the next engine move. If a disconnection
occurs while waiting for a move, the player is asked whether they
want to try again or not.
2023-04-20 09:59:18 +01:00
Tim Ledbetter
55347ed6a5 ChessEngine: Gracefully handle GUI disconnections 2023-04-20 09:59:18 +01:00
Tim Ledbetter
680d4e34d5 LibChess: Allow UCIEndpoint to handle unexpected disconnections 2023-04-20 09:59:18 +01:00
Tim Ledbetter
bf320e4826 Chess: Send a quit command to ChessEngine when it is no longer in use
The chess GUI now instructs the ChessEngine to gracefully exit by
sending a UCI quit command.
2023-04-20 09:59:18 +01:00
Tim Ledbetter
c2b9376409 ChessEngine: Handle the UCI quit command 2023-04-20 09:59:18 +01:00
Tim Ledbetter
13dbc69c23 LibChess: Add the UCI quit command 2023-04-20 09:59:18 +01:00
Timothy Flynn
d2f9645cc0 LibWeb: Properly stop, rather than terminate, ongoing media fetches
We are currently using the fetch controller's terminate() method to stop
ongoing fetches when the HTMLMediaElement load algorithm is invoked.
This method ultimately causes the fetch response to be a network error,
which we propagate through the HTMLMediaElement's error event. This can
cause websites, such as Steam, to avoid attempting to play any video.

The spec does not actually specify what it means to "stop" or "cancel" a
fetching process. But we should not use terminate() as that is a defined
spec method, and the spec does tend to indicate when that method should
be used (e.g. as it does in XMLHttpRequest).
2023-04-20 06:19:41 +02:00
Timothy Flynn
8d4d01d99a LibWeb: Invent a method to stop an in-progress fetch without errors
The HTMLMediaElement will need to stop fetching processes when its load
algorithm is invoked while a fetch is ongoing. We don't have a way to
really stop the process, due to the way it runs on nested deferred task
invocations. So for now, this swaps the fetch callbacks (e.g. to process
a fetch response) with empty callbacks.
2023-04-20 06:19:41 +02:00
Timothy Flynn
1fb0c7826b LibWeb: Do not handle media ready state changes for empty network states
This was missed in the header text of the ready state transition spec.
2023-04-20 06:19:41 +02:00
Timothy Flynn
27fd31b2ad LibWeb: Implement the HTMLMediaElement delaying-the-load-event flag 2023-04-20 06:19:41 +02:00
Timothy Flynn
1a67b86b76 LibWeb: Implement the HTMLMediaElement currentSrc attribute 2023-04-20 06:19:41 +02:00
Andreas Kling
74a6f50c91 LibWeb: Add HTML::TraversableNavigable
This is the "traversable navigable" concept from the HTML spec.

Co-authored-by: Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
2023-04-19 18:26:45 +02:00
Andreas Kling
2d602dcb34 LibWeb: Add HTML::Navigable
This is the first step towards implementing the new "navigable" concept
from the HTML spec.

Co-authored-by: Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
2023-04-19 18:26:45 +02:00
Andreas Kling
d8ccc2d54e LibWeb: Rename BrowsingContextContainer => NavigableContainer
The "browsing context container" concept in the HTML spec has been
replaced with "navigable container". Renaming this is the first step of
many towards implementing the new world.

Co-authored-by: Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
2023-04-19 18:26:45 +02:00
Sam Atkins
0f9f6aef81 LibWeb: Simplify StyleValue API now that auto isn't a length
Now that LengthStyleValue never contains `auto`, IdentifierStyleValue is
the only type that can hold an identifier. This lets us remove a couple
of virtual methods from StyleValue.

I've kept `has_auto()` and `to_identifier()` for convenience, but they
are now simple non-virtual methods.
2023-04-19 18:25:18 +02:00
Sam Atkins
4ddacf4740 LibWeb: Verify we don't accidentally create an auto LengthStyleValue 2023-04-19 18:25:18 +02:00
Sam Atkins
e3b557fa64 LibWeb: Stop creating auto LengthStyleValue for resolved style 2023-04-19 18:25:18 +02:00
Sam Atkins
5647d37d42 LibWeb: Stop parsing auto as a Length
Previously, whether trying to parse a `<length>` or `<dimension>`, we
would accept `auto` and produce a `LengthStyleValue` from it. This
would fool the `property_accepts_value()` into allowing `auto` where it
does not belong, if the property did accept lengths.

Of the few places in the parser that called `parse_dimension_value()` or
`parse_length()`, none of them were expecting it to accept `auto`, so
this fixes those too. :^)
2023-04-19 18:25:18 +02:00
Sam Atkins
7458cf4231 LibWeb: Check flex longhands first when parsing flex shorthand
Currently, `property_accepts_value()` always returns `true` if the
property is a shorthand. (This is a bug, and should actually be fixed
properly at some point...) This means that all identifiers are caught
here, including `auto`, which should be handled by the `flex-basis`
branch instead.

This works currently because `auto` is a LengthStyleValue, but that's
about to change!
2023-04-19 18:25:18 +02:00
Sam Atkins
6bf5371124 LibWeb: Properly handle auto in StyleProperties::length_percentage()
This relied on `auto` being a LengthStyleValue, which soon will not be
true. :^)
2023-04-19 18:25:18 +02:00
Sam Atkins
22cb74d9ff LibWeb: Properly handle auto when parsing background-size
This code assumed that `auto` was always stored as a LengthStyleValue,
which will not be true in the next commit. (And was not a safe
assumption to make anyway.)
2023-04-19 18:25:18 +02:00
Andreas Kling
8c03d21e95 LibWeb: Fix broken handling of flex: <flex-grow> shorthand
This is a tiny bit messy because:

- The spec says we should expand this to `flex: <flex-grow> 1 0`
- All major engines expand it to `flex: <flex-grow> 1 0%`

Spec bug: https://github.com/w3c/csswg-drafts/issues/5742
2023-04-19 12:07:16 +02:00
Hendiadyoin1
d10e838efd Kernel: Add a FIXME about SD card synchronicity
This is a major bottleneck when booting the system, especially in
non-smp mode.
2023-04-19 10:53:33 +01:00
Hendiadyoin1
863d0ac260 Kernel: Add High Speed support to the SDHC driver
This should not affect boot times on qemu, as that does not use
dynamic transfer delays in its adma code path.
On real hardware this could potentially double the data throughput,
decreasing load times.
2023-04-19 10:53:33 +01:00
Hendiadyoin1
857c9b4558 Kernel: Add basic ADMA2 support to the SD card driver
It only takes ~10s to fully boot with smp enabled!
2023-04-19 10:53:33 +01:00
Hendiadyoin1
daf85732bc Kernel: Make SDHC InterruptStatus a bitfield
A raw accessor was left as a means to use already existing codepaths.
2023-04-19 10:53:33 +01:00
Hendiadyoin1
35ec96fd28 Kernel: Add V4.10 fields to SDHC Command struct
They are not used yet but might become helpful in the future
2023-04-19 10:53:33 +01:00
Hendiadyoin1
fb79b09688 Kernel: Turn SD CapabilitiesRegister into a bit-field 2023-04-19 10:53:33 +01:00
Karol Kosek
7e33857afa WindowServer+LibGUI: Port WindowServer's Menu name to new String 2023-04-19 07:59:54 +02:00
Karol Kosek
51bd9ca037 LibGUI+Userland: Make Menu::*add_submmenu take name using new string 2023-04-19 07:59:54 +02:00
Karol Kosek
969543a847 LibGUI+Userland: Make Window::*add_menu take name using new string 2023-04-19 07:59:54 +02:00
Karol Kosek
60a338758c LibGUI: Port Menubar to new string 2023-04-19 07:59:54 +02:00
Karol Kosek
dccd70385d LibGUI+Browser: Set menu names using the new String class 2023-04-19 07:59:54 +02:00
Karol Kosek
956f4d9205 Userland: Construct Menus with name using the non-deprecated String 2023-04-19 07:59:54 +02:00
Karol Kosek
c4c1df7621 LibGUI: Store Menu names as new String 2023-04-19 07:59:54 +02:00
Timothy Flynn
f8d6a67294 LibWeb: Implement the HTMLMediaElement crossOrigin attribute 2023-04-19 07:57:52 +02:00
Timothy Flynn
7833b321a3 LibWeb: Stub out the HTMLMediaElement buffered attribute
This is needed by https://store.steampowered.com. For now, we return an
empty TimeRanges object.
2023-04-19 07:57:52 +02:00
Timothy Flynn
680a9f748e LibWeb: Stub out the HTML TimeRanges IDL interface
This is used by media elements. Provide a stub for websites which depend
on the interface existing.
2023-04-19 07:57:52 +02:00
Tim Schumacher
6f47c53ff9 Ports: Force patch regeneration after resolving conflicts
Otherwise, the post-conflict state will be used as a reference point,
and no changes will be detected.
2023-04-19 07:53:18 +02:00
Tim Schumacher
fb049d6913 Ports: Don't mangle patches when requiring manual edits
While at it, pass the `--3way` option to give the user something to work
with. Otherwise, Git will just prepare the commit metadata and nothing
else. Note that this has a relatively low chance of working, since the
recorded blob hashes aren't known to a freshly imported repository.
2023-04-19 07:53:18 +02:00
Andreas Kling
ce5a939148 LibWeb: Layout <svg> nested inside <svg>
This is far from perfect, but let's at least make an attempt at laying
out <svg> when encountering it inside another <svg>.

This makes https://awesomekling.substack.com actually load and render
instead of asserting. :^)
2023-04-19 07:52:26 +02:00
Andreas Kling
ec5d5918c4 LibWeb: Make SVG <g> elements generate a SVGGraphicsPaintable
...instead of defaulting to a PaintableBox. This way it gets the same
behavior as other SVG boxes during paint.
2023-04-19 07:52:26 +02:00
Jelle Raaijmakers
0e8ef1b886 LibGfx: Prevent out-of-bounds accumulation in PathRasterizer
Negative accumulation on the right-hand side of the accumulation bitmap
would wrap around to the left, causing a negative start for certain
lines which resulted in horizontal streaks of lower alpha values.
Prevent this by not writing out of bounds :^)

Fixes #18394
2023-04-19 06:05:10 +02:00