Commit Graph

23402 Commits

Author SHA1 Message Date
Linus Groh
439b35dc7d LibJS/Tests: Add tests for Temporal.TimeZone() constructor 2021-07-08 23:08:27 +01:00
Linus Groh
51c581f604 LibJS: Implement Temporal.TimeZone.prototype.id 2021-07-08 23:08:27 +01:00
Linus Groh
7f0fe352e2 LibJS: Implement Temporal.TimeZone.prototype.toJSON() 2021-07-08 23:08:27 +01:00
Linus Groh
8d00504ff2 LibJS: Implement Temporal.TimeZone.prototype.toString() 2021-07-08 23:08:27 +01:00
Linus Groh
2e968700aa LibJS: Implement Temporal.TimeZone.prototype[@@toStringTag] 2021-07-08 23:08:27 +01:00
Andrea Martinelli
ab1caad1e9 Taskbar: Make clicks at the edges and corners work as expected
This makes it easy for the user to just throw the mouse at the corner
of the screen and obtain the desired outcome (eg. opening the start
menu), without having to precisely position the cursor over one of the
buttons.
2021-07-08 22:45:40 +02:00
networkException
dac7b25b8a WindowServer: Add missing minimize check to highlighted window callback
This patch adds a missing minimize check for highligted windows in
WindowStack::for_each_visible_window_of_type_from_front_to_back().
Minimized windows should not be treated as visible in this context.

Previously, iterating through each visible Window when recomputing
occlusions in the Compositor would cause a crash if a highlighted
Window is also minimized at the same time. As the WindowSwitcher
currently highligts Windows even when they are minimized, opening
it while any Window is minimized would cause WindowServer to crash.
2021-07-08 22:31:21 +02:00
Marcus Nilsson
791a018c99 PixelPaint: Add method to merge visible layers
This adds a function that merges all visible layers to one, ignoring the
invisible.
2021-07-08 20:16:26 +02:00
Marcus Nilsson
0900e31fe0 PixelPaint: Scroll into view when reordering layers
Make LayerListWidget scroll into view when reordering layers.
2021-07-08 20:16:26 +02:00
Marcus Nilsson
618bb2d33e PixelPaint: Make brush draw on mousedown
This makes the brush tool start drawing a point before the user moves
the mouse, like in Photoshop and Gimp. The number of iterations of
draw_point makes for roughly 4 clicks to full opacity.
2021-07-08 20:16:26 +02:00
Marcus Nilsson
9be08e33ea PixelPaint: Add method to flatten image layers
This adds Image::flatten_all_layers() that allows the user to flatten
all the visible layers into one.
2021-07-08 20:16:26 +02:00
networkException
76a18e1172 WindowServer: Remove rect behind window icon in WindowSwitcher
This patch removes the background behind window icons
in the WindowSwitcher which looked like it was being
rendered incorrectly (without alpha) previously.
2021-07-08 20:15:23 +02:00
pancake
390d3e9fbe
LibVT: Ignore DECSTBM with invalid values (#8559)
Co-authored-by: pancake <pancake@nopcode.org>
2021-07-08 22:41:55 +04:30
Idan Horowitz
241f9f21d4 LibJS: Add %TypedArray%.prototype.reduceRight 2021-07-08 16:30:09 +01:00
Idan Horowitz
2356382938 LibJS: Add %TypedArray%.prototype.reduce 2021-07-08 16:30:09 +01:00
Idan Horowitz
f0abcde00c LibJS: Add %TypedArray%.prototype.lastIndexOf 2021-07-08 16:30:09 +01:00
Idan Horowitz
6343bfa9d7 LibJS: Add %TypedArray%.prototype.indexOf 2021-07-08 16:30:09 +01:00
Idan Horowitz
da49a7a9f8 LibJS: Add %TypedArray%.prototype.includes 2021-07-08 16:30:09 +01:00
Idan Horowitz
3b9886949f LibJS: Add %TypedArray%.prototype.fill 2021-07-08 16:30:09 +01:00
Idan Horowitz
a9de3b1d8f LibJS: Add missing a TypedArray excessive length limit check
These checks already existed for the 3 other TypedArray construction
methods. (This commit also fixes an incorrect type in one of them)
2021-07-08 16:30:09 +01:00
Luke
c7a839bb24 LibJS: Add %TypedArray%.prototype.copyWithin
This fixes 44 test262 cases.
2021-07-08 15:12:52 +01:00
modmuss50
1b4138e687 Ports: Fix building gcc on arm64 macs 2021-07-08 16:07:14 +02:00
modmuss50
036f2a14ed Toolchain: Fix building toolchain on arm64 macs
This patch is based off:
https://github.com/osx-cross/homebrew-avr/pull/248 and
https://github.com/riscv/riscv-gnu-toolchain/issues/800
2021-07-08 16:07:14 +02:00
pancake
f1266335e7 Ports: Add './package.sh shell' to get a shell with the build env set 2021-07-08 15:42:51 +02:00
Jan de Visser
e72448888b SystemServer: Add entry for SQLServer in SystemServer.ini 2021-07-08 17:55:59 +04:30
Jan de Visser
23ad4bcdf7 Utilities: Teach sql utility to use the SQLClient class
This allows the utility to connect to databases and submit SQL
statements.
2021-07-08 17:55:59 +04:30
Jan de Visser
99dc3469e8 Lagom: Exclude LibSQL/SQLClient.cpp and the sql utility from Lagom
Lagom doesn't seem to like IPC services, and sql needs SQLClient.
2021-07-08 17:55:59 +04:30
Jan de Visser
a034774e3a LibSQL+SQLServer: Build SQLServer system service
This patch introduces the SQLServer system server. This service is
supposed to be the only process/application talking to database storage.
This makes things like locking and caching more reliable, easier to
implement, and more efficient.

In LibSQL we added a client component that does the ugly IPC nitty-
gritty for you. All that's needed is setting a number of event handler
lambdas and you can connect to databases and execute statements on them.

Applications that wish to use this SQLClient class obviously need to
link LibSQL and LibIPC.
2021-07-08 17:55:59 +04:30
Jan de Visser
1037d6b0eb LibSQL: Invent statement execution machinery and CREATE SCHEMA statement
This patch introduces the ability execute parsed SQL statements. The
abstract AST Statement node now has a virtual 'execute' method. This
method takes a Database object as parameter and returns a SQLResult
object.

Also introduced here is the CREATE SCHEMA statement. Tables live in a
schema, and if no schema is present in a table reference the 'default'
schema is implied. This schema is created if it doesn't yet exist when
a Database object is created.

Finally, as a proof of concept, the CREATE SCHEMA and CREATE TABLE
statements received an 'execute' implementation. The CREATE TABLE
method is not able to create tables created from SQL queries yet.
2021-07-08 17:55:59 +04:30
Jan de Visser
30691549fd LibSQL: Move Order and Nulls enums from SQL::AST to SQL namespace
The Order enum is used in the Meta component of LibSQL. Using this enum
meant having to include the monster AST/AST.h include file. Furthermore,
they are sort of basic and therefore can live in the general SQL
namespace. Moved to LibSQL/Type.h.

Also introduced a new class, SQLResult, which is needed in future
patches.
2021-07-08 17:55:59 +04:30
pancake
633dc74606 Ports: Add radare2-5.4.0-git package 2021-07-08 14:34:08 +02:00
Andrea Martinelli
5397845a41 WindowServer: Add a new IPC to set the cursor position 2021-07-08 14:15:07 +02:00
pancake
86a4d0694f FileManager: Add Open in Terminal on folder context menu 2021-07-08 16:15:55 +04:30
networkException
47e1d5c05e Base: Remove www. from link to project website in welcome page
The www subdomain does not allow http and as LibTLS currently
has no cipher suite in common the request fails.
2021-07-08 11:10:16 +01:00
Tom
c1006a3689 Kernel: Return an already destructed PhysicalPage to the allocators
By making sure the PhysicalPage instance is fully destructed the
allocators will have a chance to reclaim the PhysicalPageEntry for
free-list purposes. Just pass them the physical address of the page
that was freed, which is enough to lookup the PhysicalPageEntry later.
2021-07-08 11:43:34 +02:00
Tom
87dc4c3d2c Kernel: Move PhysicalPage classes out of the heap into an array
By moving the PhysicalPage classes out of the kernel heap into a static
array, one for each physical page, we can avoid the added overhead and
easily find them by indexing into an array.

This also wraps the PhysicalPage into a PhysicalPageEntry, which allows
us to re-use each slot with information where to find the next free
page.
2021-07-08 11:43:34 +02:00
Tom
ad5d9d648b Kernel: Use PAE to allow accessing all physical memory beyond 4GB
We already use PAE for the NX bit, but this changes the PhysicalAddress
structure to be able to hold 64 bit physical addresses. This allows us
to use all the available physical memory.
2021-07-08 11:43:34 +02:00
Andreas Kling
658b41a06c Meta: Add Daniel Bertalan to the contributors list :^) 2021-07-08 10:38:32 +02:00
Daniel Bertalan
5208bc05ce LibC: Don't include fenv.h from float.h
This fixes a build issue where `compiler-rt` tried to declare its own
version of the `FE_*` macros, and included `float.h` in order to get the
constants. `compiler-rt` tried to declare these as an enum, and failed
with a syntax error when the constant's literal values were substituted.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
2ee39ed5f0 AK: Fix UFixedBigInt not building with Clang
Clang does not like that we are trying to refer to our own size while
our declaration is not yet complete, and fails to compile this file.
This is fixed by introducing a function which returns the correct
sizeof. This only gets evaluated in the `requires` clause after the
whole class has been parsed, so it will compile fine.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
494ead3eb8 Kernel: Add memchr and malloc to StdLib.cpp
These are needed by `libcxxabi`'s demangle support. `memchr` is taken
straight-up from the `LibC/string.cpp` source code.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
6f6b1b3ea1 ChessEngine: Don't call non-constexpr sqrt in a constexpr intiializer
GCC likely has a builtin intrinsic that evaluates the operation at
compile-time, even if the `LibM` is not declared as constexpr. Clang,
however, does not like it, and it failed to compile this code.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
44b6f402ae Utilities/run-tests: Don't use using enum
`using enum` statements will only be supported by the upcoming Clang 13
compiler, so the current code can't be built with the almost-ready Clang
toolchain yet.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
3bdefb4623 UserspaceEmulator: Use long double in FABS
`fpu_get` returns a long double and `fpu_set` expects a long double as
its parameter, and the X87 FPU uses long doubles as its internal
storage, meaning the `FABS` operates on them. This means the correct
intrinsic function for implementing it is `__builtin_fabsl`.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
a36c37db47 LibIPC: Remove unnecessary template<>
This fixes a Clang warning.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
2db4709c0c Everywhere: Add braces to aggregate initializers
This fixes a couple of warnings emitted by Clang.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
98260c5862 LibC+Utilities: Add gnu::format attributes
Without these attributes present on these custom formatting functions,
Clang would warn use about nonliteral format strings. As an added bonus,
we now get type checking on these.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
e8e628de57 Everywhere: Add Clang pragmas
We use these to prevent UB from being optimized away in `/bin/crash` and
to make the compiler not warn about the many implicit floating point
type promotions in LibM.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
98a9a1d7f9 Everywhere: Add break after the last case label before default
We already do this in most places, so the style should be consistent.
Also, Clang does not like it, as this could cause an unexpected compile
error if some statements are added to the default label or a new label
is added above it.
2021-07-08 10:11:00 +02:00
Daniel Bertalan
b0208ce433 Everywhere: Forward declare structs as structs
While structs being forward declared as classes is not strictly an
issue, Clang complains as this is not portable code, since some ABIs
treat classes declared as `class` and `struct` differently.

It's easier to fix these than to reason about explicitly disabling
another warning.
2021-07-08 10:11:00 +02:00