Commit graph

64582 commits

Author SHA1 Message Date
MacDue
e21ccdc087 LibGfx: Add support for notifications to glass window theme 2024-12-30 06:36:48 -05:00
MacDue
28c71e1ead LibGfx: Remove some hardcoded values in the glass window theme 2024-12-30 06:36:48 -05:00
MacDue
026bbb46f2 LibGfx: Fix position of maximized glass window theme title buttons
Previously, the buttons would be cropped (by the border thickness) as
the border is not shown on maximized windows. This patch adjusts the
button positions to correct for that.
2024-12-30 06:36:48 -05:00
MacDue
d725fba0c5 LibGfx: Add TitleButtonInactiveAlpha metric to system themes
This property allows controlling the alpha of inactive window title
buttons. This is useful for fading out buttons on inactive windows.
2024-12-30 06:36:48 -05:00
Bastiaan van der Plaat
3899092ea3 SystemMonitor: Grow CPU and memory charts to window size 2024-12-29 18:00:32 -05:00
MacDue
90a67e24a6 LibGfx: Improve glass window theme performance
This patch clips any parts of the frame gradient obscured by the window
contents.
2024-12-29 13:57:52 -05:00
Lucas CHOLLET
9a5d25ce1b WindowServer: Remove unnecessary debug print 2024-12-29 02:11:40 +01:00
Eyad Ahmed
e395dd9cb2 Meta: Use rm -rf instead of rmdir in QEMU image build script
If you run `serenity.sh run` with missing fuse2fs and/or fusermount3,
then install the needed packages, and then try to run the script
again, rmdir step will fail with "non-empty directory" error
causing QEMU to not start. The patch avoids this by recursively
removing disk mount directory instead of just unlinking it.
2024-12-28 11:56:21 -07:00
djwisdom
67ea0bf4ba Ports: Add menu entry for Jakt 2024-12-28 15:50:30 +01:00
butter1125
9ddb108539 Ports/findutils: Update to 4.10.0 2024-12-28 15:47:37 +01:00
butter1125
d91eda4c4f Ports/ca-certificates: Update to version 2024-11-26 2024-12-28 15:46:57 +01:00
djwisdom
0038ae2037 Ports: Add SQLite to menu entry 2024-12-28 15:46:07 +01:00
djwisdom
61f8fb3d56 Ports: Update sqlite3 from 346 to 347 2024-12-28 15:46:07 +01:00
butter1125
b133b87b97 Ports/bc: Update to 7.0.3 2024-12-28 01:04:26 +01:00
butter1125
45397d2129 Ports/coreutils: Update to 9.5 2024-12-27 23:22:14 +01:00
djwisdom
c3553d213e Ports: Add menu entry for Lua 2024-12-25 19:38:51 -05:00
djwisdom
5f479c7835 Ports: Add menu entry for Tcl 2024-12-25 19:38:24 -05:00
djwisdom
599f44c8f3 Ports: Add Zsh to menu entry 2024-12-25 19:37:55 -05:00
djwisdom
7ebe75e42a Ports: Add bash to menu entry 2024-12-25 19:37:36 -05:00
Nico Weber
17622bf0d0 AK: Add a better implementation of tan() on non-x86 2024-12-25 19:04:22 -05:00
Nico Weber
5152950ffa AK: Implement atan() in terms of asin() on non-x86 2024-12-25 19:04:22 -05:00
Nico Weber
f79ad30feb AK: Reduce > 0.5 arm of asin() to asin() instead of to atan() 2024-12-25 19:04:22 -05:00
Nico Weber
dcf88d9461 AK: Move atan() below asin()
Pure code move, no behavior change.
2024-12-25 19:04:22 -05:00
Nico Weber
69b2b86b29 AK: Implement atan2() in terms of atan() on non-x86
atan() isn't implemented yet on non-x86, so this isn't super useful yet.
But it does handle a couple corner cases correctly already, and those
are even enough to make all the atan2 tests in Tests/LibC/TestMath.cpp
pass 🙃
2024-12-24 13:11:07 -05:00
Nico Weber
982c8cc7fb AK+LibC: Move generic copysign() into AK 2024-12-24 13:11:07 -05:00
Nico Weber
d4f037cf0f AK: Make sin() and cos() a bit better
With this, sin() and cos() are fairly close to the correct values
for all x. It's neither fast nor very accurate, but much better than
what we had before.
2024-12-24 13:11:07 -05:00
Nico Weber
8756244d66 AK: Make sin() and cos() periodic
Now that we have fmod(), we can implement some symmetries for
sin() and cos(). The core approximation is still very simplistic,
but now it only has to approximate in [0, Pi/2]. So while its error
is still high, it's no longer unbounded.
2024-12-24 13:11:07 -05:00
Nico Weber
085dc27bdf AK: Add an implementation of fmod() on non-x86
This is a pretty naive implementation, but it mostly works.
2024-12-24 13:11:07 -05:00
Sönke Holz
555d2ac5ef Kernel/aarch64: Don't print the register state twice for crashes
`handle_crash` already calls `dump_registers`, so there is no need for
the AArch64 exception handler to do it as well.

The second register dump (the one made by `handle_crash`) previously
also often reported an incorrect ESR_EL1 value, as interrupts are
enabled at that point in time.
This problem can simply be solved by saving the ESR_EL1 value in the
`RegisterState`, similar to how we save `scause` on RISC-V.
2024-12-24 01:12:26 +01:00
Sönke Holz
86bb060d4b Kernel/aarch64: Don't set SCTLR_EL1 to very permissive values initially
The initial value we used for SCLTR_EL1 would allow EL0 to do things it
shouldn't be allowed to, like disabling interrupts.

Setting that register to more permissive values and overriding it later
shouldn't cause any problems, but it's still less confusing this way.
2024-12-24 01:12:26 +01:00
Liav A.
53f433b35d Utilities/init: Mark all mounts as immutable 2024-12-23 20:38:38 +01:00
Liav A.
439428b464 Base: Mark all mounts in /etc/fstab as immutable
These mounts are the base set of mounts we need for a fully functional
system. The bind mounts are also there for protection from malicious
software or accidental overwrite/deletion of files.

Therefore, marking these mounts as immutable makes sense, because they
should not be changed during runtime anyway.
2024-12-23 20:38:38 +01:00
Liav A.
1dfc9e2df3 Kernel+Userland: Add immutable mounts
Immutable mounts are mounts that can't be changed in any aspect, if the
VFSRootContext that hold them is used by a process. This includes two
operations on a mount:
1. Trying to remove the mount from the mount table.
2. Trying to change the flags of the mount.

The condition of a VFSRootContext being held by a process or not is
crucial, as the intention is to allow removal of mounts that marked as
immutable if the VFSRootContext is not being used anymore (for example,
if the container that was created with such context stopped).

Marking mounts as immutable on the first VFS root context essentially
ensures they will never be modified because there will be a process
using that context (which is the "main" VFS root context in the system
runtime).

It should be noted that setting a mount as immutable can be done in
creation time of the mount by passing the MS_IMMUTABLE flag, or by doing
a remount with MS_IMMUTABLE flag.
2024-12-23 20:38:38 +01:00
Nico Weber
d6bdb9a3ed AK: Add implementations of exp2() and exp() on non-x86
This is a pretty naive implementation of exp2() that can be improved
a lot, but hey, it beats the sin() and cos() implementation on non-x86.

It also implements exp(x) as exp2(x * log2(e)), with the same
disclaimer.
2024-12-23 08:42:48 -05:00
Nico Weber
1edd0cd8e0 AK: Reorder exp() and exp2() in Math
No behavior change, just moving one function after the other,
to make an upcoming diff easier to read.
2024-12-23 08:42:48 -05:00
MacDue
cd2a614732 Base: Add some missing window icons to Redmond Plastic 2024-12-22 13:11:10 -05:00
MacDue
ed1405a02d Base: Add some missing window icons to Redmond Glass 2024-12-22 13:11:10 -05:00
Nico Weber
25365e2890 Meta: Use response file for linking shared libraries in GN build
Linking liblagom-web.so produces a ~132K long command line. Ninja
passes the whole command line as a single arg to `sh -c <arg>`,
and the limit for single arguments (`MAX_ARG_STRLEN`) on Linux
is `PAGE_SIZE * 32` == 128K.

A response file passes the list of files in a file on disk, which
lets us sidestep this problem. Ninja writes response files before
invoking commands, and deletes them after (unless `-d keeprsp` is
passed to ninja, then it keeps them on disk).
2024-12-21 20:50:35 -05:00
Sam Atkins
fadd346d83 LibWeb/CSS: Don't overwrite active font load when requesting a pt size
start_loading_next_url() is a no-op if there's a pending resource load,
but not if that resource load has successfully loaded already. There is
a delay between the font resource loading, and it being processed into
a vector font. Calling font_with_point_size() in that gap would
previously erase the previously-loaded font, if the font had multiple
URLs to choose from.

This fixes the icon font on mods.factorio.com :^)

(cherry picked from commit 28388f1fd24c0019d2c4be7900584c6c536527ad)
2024-12-21 14:58:20 -05:00
Pavel Shliak
2fccdf6371 LibWeb: Refer a spec issue in Location::internal_get_own_property
(cherry picked from commit 4cd1ef12d7bdddc7cbb235350d50fee65fbd5f34)
2024-12-21 14:58:20 -05:00
Pavel Shliak
2270cd93f4 LibWeb: Update Location initialization according to spec
(cherry picked from commit 361c6f1b64393de645c6728712658a6052e857a1)
2024-12-21 14:58:20 -05:00
Timothy Flynn
026b5e53eb LibCrypto: Protect the SignedBigInteger ctor against integer overflow
In particular, if given a value of -2147483648, we would invoke signed
integer overflow (which is UB).

(cherry picked from commit edd3b14ddf049048e5d6bd952677133237adb652)
2024-12-21 14:58:20 -05:00
Totto16
960b5a4e94 LibWeb: Add test for getComputedStyle with a PseudoElement argument
This test checks the case, where an unknown pseudo element is used as
second argument to getComputedStyle

(cherry picked from commit 540c840755755844c84b0b9f41c50d2e835486fe)
2024-12-21 14:58:20 -05:00
Totto16
db43de0c58 LibWeb: Handle special cases of PseudoElement::Type correctly
There are some special values for CSS::Selector::PseudoElement::Type
which are after `KnownPseudoElementCount` and therefore not present in
various arrays of pseudo elements, this leads to some errors, if a type
after `KnownPseudoElementCount` is used without checking first. This
adds explicit checks to all usages

(cherry picked from commit d21bfda9001efd1f2303dc86af6c1f0a2d7da182)
2024-12-21 14:58:20 -05:00
Jelle Raaijmakers
36f87b9a56 LibWeb: Resolve performance FIXME in Node::is_equal_node()
(cherry picked from commit f29457b61ecd5b7d4a27414259010eb7e1ae6d2c)
2024-12-21 14:58:20 -05:00
Jelle Raaijmakers
5b85d2a558 LibWeb: Remove unused (Tree)Node::index_of_child()
(cherry picked from commit c357fbf03668c7da18140864b6317387d3d0fc39)
2024-12-21 14:58:20 -05:00
Gustavo Ramirez
63cbda39a7 LibWeb/CSS: Refactor phase() method to reduce redundancy
The function AnimationEffect::phase() contained duplicated condition
checks for the animation phase determination. This refactor eliminates
the redundant checks by simplifying the logic.

(cherry picked from commit 108701c8997e8484890adee8dbf1d4cb81a51c39)
2024-12-21 14:58:20 -05:00
Timothy Flynn
e0a25b5cdd LibJS: Return the allocated dst register from deleting super properties
Even though calling delete on a super property will ultimately throw a
ReferenceError, we must return the allocated register for the result of
the delete operation (which would normally be a boolean). If the delete
operation is used in a return statement, the bytecode generator for the
return statement must be able to assume the statement had some output.

(cherry picked from commit 5947c37637f8ea3d4c323a04e5e5dfe9fad5a4d7)
2024-12-21 14:58:20 -05:00
Pavel Shliak
55f8790da8 LibGC: Preallocate space before dumping GC graph
Speeds up the append_gc_graph function by preallocating space.
This change reduces the time taken to dump the GC graph by 4%
on about:blank.

(cherry picked from commit 03ac6e6e87488fdc638cd3a84b2c59890bdba3cc)
2024-12-21 14:58:20 -05:00
Timothy Flynn
62ced93997 LibJS: Avoid internal assertion accessing detached TA internal slots
This defers accessing TA internal slots until we know we have a valid,
attached TA. Our implementation has assertions that guard against this.

(cherry picked from commit 962441b3cf34c1350877ac7c73351657c10f675b)
2024-12-21 14:58:20 -05:00