Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
- Let undefined variables throw a ReferenceError by using
Identifier::execute() rather than doing variable lookup manually and
ASSERT()ing
- Coerce value to number rather than ASSERT()ing
- Make code DRY
- Add tests
|
|
|
|
|
|
|
|
Make it constexpr and do perfect forwarding.
|
|
|
|
Co-Authored-By: Andreas Kling <kling@serenityos.org>
|
|
A neat error message is displayed when failing to open a directory!
|
|
This will allow us to catch errors early on FileManager
|
|
|
|
|
|
|
|
|
|
|
|
This makes sure we repaint it right away so we can see the changes.
|
|
The original implementation only sent out notifications when there was
something being drawn on screen. If nothing was going on, we'd get too
lazy and just not notify display links.
This obviously break requestAnimationFrame(), so now we just drive the
DisplayLinks at 60 fps no matter what. :^)
|
|
An ImageData is a wrapper around a Bitmap wrapper around a
JS::Uint8ClampedArray.
|
|
|
|
This is a special kind of byte array that clamps its values to 0...255
It will be used for HTML ImageData objects.
I made Object::put_by_index() and get_by_index() virtual for this.
We'll probably need to make non-numeric property name lookups virtual
as well, but this solves my current problem well enough.
|
|
|
|
|
|
This patch adds GUI::Action::create_checkable() helpers that work just
like the existing create() helpers, but the actions become checkable(!)
Clients are no longer required to manage the checked state of their
actions manually, but instead they will be checked/unchecked as needed
by GUI::Action itself before the activation hook is fired.
|
|
|
|
This prevents accesing the parent window menubar when a modal is
currently open, which was not a desired behavior.
|
|
PR #1495 fixes #1464 but only accounts for window menus. In File
Manager, for example, attempting to pop up the context menu on the file
name text box of the properties modal window, will result in the same
behavior.
Removing the code altogether solves the problem, altough I'm
not sure if it could have any bad implications.
I was thinking it might allow interaction with a parent window menu if
it remains open just before the popup window is shown, but I have not
seen a way to replicate this behavior.
|
|
This makes it show up in Inspector with all the menus inside it. :^)
|
|
It was impractical to return a RefPtr<File> since that left us no way
to extract the error string. This is usually needed for the UI, so the
old static open() got basically no use.
|
|
There were some ideas about how to use this class but we never actually
started using it, so let's just simplify it and get it ready for use.
The basic idea is: a function returns a Result<ValueType, ErrorType>.
Callers check if the result object is_error(). If so, an ErrorType can
be fetched with the error() getter. Otherwise, a ValueType is fetched
with the value() getter. That's it. :^)
|
|
|
|
This was not done previously and resulted in modal windows not being
able to accept input unless they were clicked one time if their parent
windows were the active input window.
|
|
|
|
this_value to the callee's bound |this| in CallExpression::execute()
|
|
value and bound arguments
This allows Function objects produced by Function.prototype.bind, as well
as arrow functions to track their |this| values and bound arguments.
|
|
|
|
|
|
|
|
This little tweak fixes the issue where the scrolling speeds up
significantly if the user wiggles their cursor. Just something obvious
I spotted while watching the video :^)
|
|
|
|
Seems to be a typo.
|
|
|
|
|
|
Previously, TextEditor processed the Select all command directly on the
keydown event handler. For this reason, WindowManager would not process
it as an action for the focused control and an action with the same
keyboard shortcut from the parent could override the TextEditor's one
even when it is focused.
For instance, when pressing Ctrl+A on the FileManager's path bar, all
files were selected instead, which is not the expected behavior.
Now the Select all command is an actual action on TextEditor, so that
WindowManager can process it correctly before any other actions. I also
added an icon for it!
|
|
If you select some text and drag the cursor outside the widget on the
left hand side, we would previously suddenly snap the selection cursor
to the end of the line instead of keeping it at the start of the line
as you would expect. This patch fixes that. :^)
|
|
If you start selecting text and move the cursor outside the TextEditor
widget area without letting go of the mouse button, we will now keep
scrolling a little bit every 100ms.
|
|
We don't support these yet, and it broke all the tests. :^)
|
|
Suggesting whatever the user has input is not quite sane :^)
|