Commit graph

11181 commits

Author SHA1 Message Date
Andreas Kling
58fb3ebf66 LibCore+AK: Move MappedFile from AK to LibCore
MappedFile is strictly a userspace thing, so it doesn't belong in AK
(which is supposed to be user/kernel agnostic.)
2021-11-23 11:33:36 +01:00
Andreas Kling
c1c9da6c35 LoginServer: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
c1a3968c66 LibCore: Make LocalSocket takeover mechanism return ErrorOr<T> 2021-11-23 11:33:36 +01:00
Andreas Kling
c37a02341b LibCore: Add Core::System wrappers for fstat() and fcntl() 2021-11-23 11:33:36 +01:00
Andreas Kling
21a5fb0fa2 LibCore+LibSystem: Move syscall wrappers from LibSystem to LibCore
With this change, System::foo() becomes Core::System::foo().

Since LibCore builds on other systems than SerenityOS, we now have to
make sure that wrappers work with just a standard C library underneath.
2021-11-23 11:33:36 +01:00
Andreas Kling
acc2eccede LibSystem: Add wrapper for fstat() 2021-11-23 11:33:36 +01:00
Andreas Kling
2828d58a10 RequestServer: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
5e93db93fc ImageDecoder: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
c6a581f267 WebSocket: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
c2b90bab9f LanguageServers/Shell: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
54155f8c64 LanguageServers/Cpp: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
9d4c946515 FileSystemAccessServer: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Andreas Kling
32e05f9b14 WebContent: Port to LibMain :^) 2021-11-23 11:33:36 +01:00
Mustafa Quraish
4d302e0e88 Everywhere: Use Application::construct() with Main::Arguments directly
Use the updated API everywhere we are currently manually passing in
`arguments.argc` and `arguments.argv`.
2021-11-22 21:13:42 -08:00
Mustafa Quraish
2fbcab46bf Everywhere: Use ArgsParser::parse() with Main::Arguments directly
Use the updated API everywhere we are currently manually passing in
`arguments.argc` and `arguments.argv`.
2021-11-22 21:13:42 -08:00
Mustafa Quraish
7720644ae2 LibCore: Let ArgsParser::parse() accept Main::Arguments
Instead of manually passing in `arguments.argc` and `arguments.argv`,
we can now just pass in the arguments directly.
2021-11-22 21:13:42 -08:00
Mustafa Quraish
a0ef655451 LibGUI: Let Application constructor accept in Main::Arguments
Instead of manually passing in `arguments.argc` and `arguments.argv`,
we can now just pass in the arguments directly.
2021-11-22 21:13:42 -08:00
Ali Mohammad Pur
3ca00c8ae6 LibGfx: Avoid unaligned loads and stores in GlyphBitmap 2021-11-22 21:10:25 -08:00
pbrw
71298ad9ba Spider: Port to LibMain
Simplified two pledge() and two unveil() by using TRY()
2021-11-22 21:03:45 -08:00
Pedro Pereira
85ae298b85 FlappyBug: Port to LibMain
Simplified two pledge() and two unveil() by using TRY().
2021-11-22 21:02:14 -08:00
Pascal Puffke
ca7b603578 Mail: Port to LibMain 2021-11-22 23:56:22 +01:00
Pascal Puffke
41b80f3d85 Piano: Port to LibMain 2021-11-22 23:56:22 +01:00
Pascal Puffke
61408e2397 PDFViewer: Port to LibMain 2021-11-22 23:56:22 +01:00
Pascal Puffke
bec7ffaf0a PixelPaint: Port to LibMain 2021-11-22 23:56:22 +01:00
Pedro Pereira
55db1811c7 Chess: Port to LibMain
Simplified two pledge() and five unveil() by using TRY().
2021-11-22 23:55:42 +01:00
Andreas Kling
b65a039db7 Applets/ResourceGraph: Port to LibMain :^)
This simplifies a bunch of calls to pledge() and unveil().
2021-11-22 23:52:47 +01:00
Andreas Kling
d0db6c472c Applets/ResourceGraph: Remove unnecessary unveiling of /etc/passwd
This used to be needed by Core::ProcessStatisticsReader, but since we no
longer use that for the CPU graph, we can just lose it (along with a
FIXME about it.)
2021-11-22 23:52:47 +01:00
Andreas Kling
c5c54f634e FileManager: Port to LibMain :^)
This simplifies a handful of calls to pledge() and sigaction().
2021-11-22 23:52:47 +01:00
Andreas Kling
9cf874ef9a WindowServer: Port to LibMain :^)
This simplifies some pledge(), unveil() and sigaction() calls.
2021-11-22 23:52:47 +01:00
Sam Atkins
97eb662e62 Browser: Scope bookmark actions so that they don't block the delete key
This fixes #10940.

Previously, all presses of the Delete key without a modifier in Browser
were uselessly consumed by the "Delete" action in the bookmark context
menu.
2021-11-22 23:48:10 +01:00
Pedro Pereira
fb5ea617f1 2048: Port to LibMain
Simplified two pledge() and two unveil() by using TRY().
2021-11-22 23:44:55 +01:00
Pedro Pereira
6e6228d40d Breakout: Port to LibMain
Simplified two pledge() and two unveil() by using TRY().
2021-11-22 23:44:09 +01:00
Linus Groh
8fa5dc7241 js: Use pledge()
It is now no longer possible to make network connections from a hijacked
js(1) :^)
2021-11-22 23:07:43 +01:00
Linus Groh
cfecfbb214 js: Port to LibMain :^)
This wasn't particularly difficult, and there's not much use for the
nicer interface yet either. While unveil() is of limited use in js(1)
as it should be able to open arbitrary files, I feel like we should be
able to add a pledge() call.
2021-11-22 23:07:43 +01:00
kleines Filmröllchen
b14a64b3c8 Piano: Move to LibDSP's Classic synthesizer
Almost all synthesizer code in Piano is removed in favor of the LibDSP
reimplementation.

This causes some issues that mainly have to do with the way Piano
currently handles talking to LibDSP. Additionally, the sampler is gone
for now and will be reintroduced with future work.
2021-11-22 22:26:17 +01:00
kleines Filmröllchen
3ca059da2d LibDSP: Create Classic synth
The Classic synthesizer is a replication of Piano's old synthesizer
engine that is removed in the next commit.
2021-11-22 22:26:17 +01:00
kleines Filmröllchen
7663fbb19e LibDSP: Introduce ProcessorEnumParameter 2021-11-22 22:26:17 +01:00
kleines Filmröllchen
cc9aab7462 LibDSP: Add Envelope abstraction
For the upcoming synthesizer, having an abstracted ADSR envelope concept
is highly desirable. Additionally, Envelope is mostly constexpr and
therefore super fast :^)
2021-11-22 22:26:17 +01:00
Ben Wiederhake
afc456edd6 PixelPaint: Use better-fitting image size
This makes the default image fit perfectly into the default viewport,
which means the first fit_image_to_view call will end up with a scale of
exactly 1. This scale level has no visual artifacts, which is the more
intuitive 'default' behavior.

Fixes #10975.
2021-11-22 22:14:53 +01:00
Ben Wiederhake
177478dadf PixelPaint: Add interactive zoom ComboBox to toolbar
Before, there was nothing that tells the user the current zoom level,
which is unknown after a 'fit to image' (the initial state).
2021-11-22 22:14:53 +01:00
Ben Wiederhake
9013d0fe38 PixelPaint: Add ability to fit to either width, height, or image 2021-11-22 22:14:53 +01:00
Ben Wiederhake
be697a440f PixelPaint: Allow setting ImageEditor scale and listening for changes 2021-11-22 22:14:53 +01:00
Ben Wiederhake
7f962cd9d3 PixelPaint: Floor effective viewport size to whole integers
We don't have fractional pixels available, so don't attempt to use them.
2021-11-22 22:14:53 +01:00
Pedro Pereira
a436f0c668 LibMain: Rename .arguments to .strings :^)
Before this change, we would need to write arguments.arguments to access
the Span<>, which doesn't feel too pretty.
2021-11-22 22:13:22 +01:00
Tim Schumacher
75978d5fff tar: Support extracting symlinks
We can now extract GitHub's LLVM tarballs. :^)
2021-11-22 21:57:42 +01:00
Pedro Pereira
a0c80a6f17 Minesweeper: Port to LibMain
Simplified two unveil() and two pledge() by using TRY().
2021-11-22 21:56:31 +01:00
Pedro Pereira
0ed3520ef5 Starfield: Port to LibMain
Simplified two pledge() by using TRY().
2021-11-22 21:56:20 +01:00
Pedro Pereira
272f7c340e 3DFileViewer: Port to LibMain
Simplified one pledge() and five unveil() by using TRY().
2021-11-22 21:56:04 +01:00
Andreas Kling
05e45bfdc5 Browser: Port to LibMain :^) 2021-11-22 19:47:14 +01:00
Andreas Kling
f5927f167b nproc: Port to LibMain :^) 2021-11-22 19:43:26 +01:00