Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
In addition to it now handling allocation failures, the encode() API is
now consistent with PNGWriter.
|
|
Let's make it clear that these functions deal with ASCII case only.
|
|
|
|
|
|
Nobody uses this return value any more. It also lets us remove a whole
bunch of `(void)` casts. :^)
|
|
|
|
|
|
|
|
|
|
As usual, this removes many unused includes and moves used includes
further down the chain.
|
|
Because usage of the input_type parameter is now higher than of the
placeholder parameter, this makes for a cleaner API.
|
|
Do this where we were already checking if the input was empty after the
InputBox was submitted. Those places gain interactive input validation.
:^)
|
|
|
|
Those don't have any non-try counterpart, so we might as well just omit
it.
|
|
|
|
The patch is tiny as WidgetGallery is only using `LibFSAC` for its file
picker.
|
|
These are not needed anymore since the introduction of the new
get_root_session_id syscall.
|
|
|
|
Also update the LibGfxDemo to actually show off these alignments.
|
|
Simplify a lot of uses of ElapsedTimer by converting the callers to
elapsed_time from elapsed, as the AK::Time returned is better for unit
conversions and comparisons against constants.
|
|
It's the only one, so the `try` prefix is unnecessary now.
|
|
MOAR FIXMES! ;^)
|
|
These functions return the deprecated `Core::File` class, so let's mark
it as such to avoid possible confusion between future non try_*
functions which will use Core::Stream family classes and to possibly
grab someone's attention. :^)
|
|
Rip that bandaid off!
This does the following, in one big, awkward jump:
- Replace all uses of `set_main_widget<Foo>()` with the `try` version.
- Remove `set_main_widget<Foo>()`.
- Rename the `try` version to just be `set_main_widget` because it's now
the only one.
The majority of places that call `set_main_widget<Foo>()` are inside
constructors, so this unfortunately gives us a big batch of new
`release_value_but_fixme_should_propagate_errors()` calls.
|
|
This keeps some overloads that accept ints to avoid adding calls to
.to_type<float>() all over the place.
|
|
Similar to the Settings application, this adds a single Screensaver
application to launch all screensaver demos. This is to declutter the
taskbar menu a bit.
|
|
This is to avoid naming conflicts with an upcoming Screensaver launcher
application.
|
|
This wasn't doing anything interesting enough to justify being its own
demo application. If we need a spinning cube, we can just load a cube
model into 3DFileViewer. :^)
|
|
These instances were detected by searching for files that include
stdlib.h, but don't match the regex:
\\b(_abort|abort|abs|aligned_alloc|arc4random|arc4random_buf|arc4random_
uniform|atexit|atof|atoi|atol|atoll|bsearch|calloc|clearenv|div|div_t|ex
it|_Exit|EXIT_FAILURE|EXIT_SUCCESS|free|getenv|getprogname|grantpt|labs|
ldiv|ldiv_t|llabs|lldiv|lldiv_t|malloc|malloc_good_size|malloc_size|mble
n|mbstowcs|mbtowc|mkdtemp|mkstemp|mkstemps|mktemp|posix_memalign|posix_o
penpt|ptsname|ptsname_r|putenv|qsort|qsort_r|rand|RAND_MAX|random|reallo
c|realpath|secure_getenv|serenity_dump_malloc_stats|serenity_setenv|sete
nv|setprogname|srand|srandom|strtod|strtof|strtol|strtold|strtoll|strtou
l|strtoull|system|unlockpt|unsetenv|wcstombs|wctomb)\\b
(Without the linebreaks.)
This regex is pessimistic, so there might be more files that don't
actually use anything from the stdlib.
In theory, one might use LibCPP to detect things like this
automatically, but let's do this one step after another.
|
|
This was a plain-looking test app for debugging mouse events.
Mouse events work now, and if we want mouse testing facilities, they
can be added to MouseSettings instead.
|
|
This served no purpose other than looking somewhat neat.
|
|
This change adds the ability to use the scroll wheel to change
the speed in starfield.
|
|
We have 3 demos with pretty similar window logic and quitting behavior
on user activity, so centralize that into `Desktop::Screensaver`.
|
|
All interesting code from the demo now lives in LibVirtGPU.
|
|
Moved all images into a Vector instead of storing every animation frame
in its own member variable. This greatly simplifies the bitmap selection
logic and removes redundant if() checks.
Also fixes minor state bugs. For example, CatDog woudld go to sleep
immediately after actively moving for > 5 seconds. Also fixes arbitrary
hardcoded values for mouse offset movement tresholds as well as
inconsistent movement increments. This allows clicking anywhere on the
CatDog window without moving CatDog.
In addition to removing many member variables, the API interface is
also cleaned up a bit to expose less CatDog internals. Nobody likes
exposed CatDog internals ;).
Variables and function are also renamed where necessary to (hopefully)
improve readability.
|
|
This removes a measly 1 FIXME :))
|
|
This fixes an astonishing 22 FIXMEs. :^)
|
|
|
|
|
|
This is a first step towards handling PNG encoding failures instead of
just falling over and crashing the program.
This initial step will cause encode() to return an error if the final
ByteBuffer copy fails to allocate. There are more potential failures
that will be surfaced by subsequent commits.
Two FIXMEs were killed in the making of this patch. :^)
|
|
...and if we do get an error, present it to the user.
|
|
Before this commit it was a bit ambiguous which buttons the function
name were referring to; this instead now makes it clear that it's
related to mouse input. Additionally, this also fixes incorrect getter
naming leftover from yesteryear.
|
|
Just two ints like Gfx::IntPoint.
|
|
This is just two ints or 8 bytes or the size of the reference on
x86_64 or AArch64.
|
|
This will make it easier to support both string types at the same time
while we convert code, and tracking down remaining uses.
One big exception is Value::to_string() in LibJS, where the name is
dictated by the ToString AO.
|
|
We have a new, improved string type coming up in AK (OOM aware, no null
state), and while it's going to use UTF-8, the name UTF8String is a
mouthful - so let's free up the String name by renaming the existing
class.
Making the old one have an annoying name will hopefully also help with
quick adoption :^)
|
|
The drawing had several visual artifacts with the colors not perfectly
filling out their outlines. By re-using the path for both stroke and
fill, we ensure that the exact same floating point coordinates are
used. Drawing the fill first and the stroke after also helps eliminate
artifacts.
|