Commit Graph

1884 Commits

Author SHA1 Message Date
Andreas Kling
7fcca0ce4b GHttp: Rename GHttpNetworkJob => GHttpJob. And tidy up a little bit. 2019-04-08 02:24:34 +02:00
Andreas Kling
37ae00a4dd Kernel+Userland: Add the rename() syscall along with a basic /bin/mv. 2019-04-07 23:35:26 +02:00
Andreas Kling
71b6436552 GHttp: Fix little bug in HTTP header parsing. 2019-04-07 22:47:34 +02:00
Andreas Kling
f93b3b7806 AK: Improve StringImpl chomping a bit.
Chomp off any number of trailing [\0\n\r] characters and trim the allocation
to fit instead of keeping the original size.
2019-04-07 20:21:11 +02:00
Andreas Kling
31b9d8354e GIODevice: Remove accidentally committed debug spam. 2019-04-07 20:18:58 +02:00
Andreas Kling
51b4d3fe5a GHttp: Work on bringing this up. 2019-04-07 19:35:48 +02:00
Andreas Kling
8f30657390 Start working on a Downloader app and backing classes in LibGUI.
LibGUI is slowly becoming LibKitchensink but I'm okay with this for now.
2019-04-07 14:36:10 +02:00
Andreas Kling
c7365a00f8 WindowServer: Add ability to initiate window resize from window edges. 2019-04-06 23:20:06 +02:00
Andreas Kling
0808d5158c WindowServer: Make WSButton a Weakable and stop rawly pointing to it.
We had a crash due to dereferencing a destroyed WSButton after clicking
a window close button. Avoid that problem by using WeakPtr.
2019-04-06 21:17:02 +02:00
Andreas Kling
e74f32ae40 LibGUI: Always invalidate layout on GWidget child removal.
This code can get a bit confused when the child is destroyed before we
handle the ChildRemoved event. In those cases, the GChildEvent::child()
getter will return nullptr as it's backed by a WeakPtr.

To work around this issue, just always invalidate the layout for now.
This can be made a lot tighter in the future.
2019-04-06 21:15:13 +02:00
Andreas Kling
d89d759c36 WindowServer: Pick a new active window when the active window is minimized.
Also use the same logic when the active window is removed.
2019-04-06 20:50:38 +02:00
Andreas Kling
ddba6c1b7f Kernel: Oops, also moved FileDescriptor into FileSystem/, fix Makefile. 2019-04-06 20:34:59 +02:00
Andreas Kling
644c887594 Kernel: Move FIFO into FileSystem/ and Socket+LocalSocket into Net/. 2019-04-06 20:29:48 +02:00
Andreas Kling
f2580dcfeb FontEditor: Remove weird focus rects and optimize repaint while drawing.
I added focus rects to these widgets because I had just started working on
focus support and I was excited but it doesn't really make sense for these
things to have focus rects. :^)

While I was here I also optimized the repaint code to only update the edited
glyph in the glyph map when editing its pixels.
2019-04-06 15:28:06 +02:00
Andreas Kling
ac6c7d3e19 Kernel: Use alloc_fd() more instead of walking fd list manually. 2019-04-06 14:54:32 +02:00
Andreas Kling
a58d7fd8bb Kernel: Get rid of Kernel/types.h, separate LinearAddress/PhysicalAddress. 2019-04-06 14:29:29 +02:00
Andreas Kling
6306cf5c27 GScrollBar: Add the same hover highlight effect as GButton. 2019-04-06 13:55:56 +02:00
Andreas Kling
8bda69e32f WindowServer: Remove some debug spam. 2019-04-06 13:45:42 +02:00
Andreas Kling
f12573cb63 Add a slight hover highlight to GButton and WSButton. :^) 2019-04-06 04:08:09 +02:00
Andreas Kling
22c204af66 Meta: Time for a new screenshot :^)
Also update ReadMe with a link to the build instructions.
2019-04-06 01:31:12 +02:00
Andreas Kling
ef9fbef4c6 Taskbar: Show minimized window titles in [brackets].
Had to plumb the minimization state from WindowServer to Toolbar in order
to implement this.
2019-04-06 00:58:30 +02:00
Andreas Kling
74142d78c1 LibGUI: GButton's caption should be drawn in the foreground color. 2019-04-06 00:57:31 +02:00
Andreas Kling
f6ca94605c WindowServer: Add a window minimization button.
The window is simply ignored in the painting and hit testing traversal
when in minimized state, same as we do for invisible windows.

The WM_SetActiveWindow message (sent by Taskbar) brings it back into the
non-minimized state. :^)
2019-04-05 22:32:00 +02:00
Andreas Kling
0fc3ccaa52 WindowServer: Make WSButton behave more like a normal button.
Previously it would just close the window on MouseDown. Now we do the normal
thing where we require a MouseUp inside the button rect before committing.
2019-04-05 21:53:45 +02:00
Andreas Kling
0d60c56b51 WindowServer: Make WSWindowFrame and WSButton deal in relative coordinates.
This was a bit painful to get right. The code is a lot more pleasant to
deal with now that all coordinates are relative to their local system
instead of being absolute screen coordinates.
2019-04-05 21:33:34 +02:00
Andreas Kling
2ac2d79a8e WindowServer: Simplify two mouse coordinate conversions. 2019-04-05 20:27:12 +02:00
Andreas Kling
3155a2e128 WindowServer: Add a WSButton class and make the window close buttons use it. 2019-04-05 18:40:36 +02:00
Andreas Kling
9fbac66a91 Hack sync.sh script to retry umount after a short delay if it fails.
I keep accumulated unwanted mounts because umount sometimes fails.
2019-04-05 16:26:29 +02:00
Andreas Kling
47d270b577 WindowServer: Factor out window frame logic into a WSWindowFrame class.
The window frame is an object that contains a window, its title bar and
window border. This way WSWindowManager doesn't have to know about all the
different types of window borders, titlebar rects, etc.
2019-04-05 15:54:56 +02:00
Andreas Kling
99b98dc653 WindowServer: Merge WM_WindowAdded and WM_WindowStateChanged.
These events are identical, so it's silly to send both. Just broadcast
window state changes everywhere instead, it doesn't matter when it was
added as clients are learning about this asynchronously anyway.
2019-04-05 15:01:28 +02:00
Andreas Kling
329cc60a92 NetworkTask: Add a combined alarm for the all network adapters.
This way we can go back to snoozing in the receiver task and stop chewing
up the CPU. :^)
2019-04-05 05:14:20 +02:00
Andreas Kling
bcc00857a4 AK: Revert Eternal<T> for now since it doesn't work as intended. 2019-04-05 05:14:20 +02:00
Andreas Kling
fb6dc5350d Meta: Tweak build instructions. 2019-04-05 04:02:36 +02:00
Andreas Kling
89fc5de28d Meta: Give the build instructions a more accurate title. 2019-04-05 04:01:36 +02:00
Andreas Kling
9de7a0daaf AK: Fix problem when building i686-pc-serenity toolchain from scratch. 2019-04-05 03:58:40 +02:00
Andreas Kling
dd966c03c9 Meta: Add build instructions about LibM headers. 2019-04-05 03:58:16 +02:00
Andreas Kling
667b4ad13b Meta: Add build instructions. 2019-04-05 03:54:40 +02:00
Andreas Kling
e19d38e742 LibC: Add some missing stuff in stdint.h for libstdc++. 2019-04-05 03:37:01 +02:00
Andreas Kling
6f5ee79fe1 Meta: Add patches for building binutils and GCC for i686-pc-serenity. 2019-04-05 03:02:52 +02:00
Andreas Kling
6df5e3f51a Kernel: Build with i686-pc-serenity-g++.
This works just fine, and now we only need one cross-compiler. :^)
2019-04-05 02:56:23 +02:00
Andreas Kling
ec7817af37 Kernel: Spawn /bin/Taskbar on startup.
I think it's good enough now to be there by default. :^)
2019-04-04 20:19:07 +02:00
Andreas Kling
6280dee625 Taskbar: Make the window buttons slightly wider. 2019-04-04 20:12:09 +02:00
Andreas Kling
02b523f9cd WindowServer: Clip dirty cursor rects to the screen in compose(). 2019-04-04 17:36:28 +02:00
Andreas Kling
8f38c01600 WindowServer: WM_SetActiveWindow should move the window to front as well. 2019-04-04 16:38:42 +02:00
Andreas Kling
64a5abf8db Taskbar: Only include "Normal" windows in the taskbar window list. 2019-04-04 16:23:23 +02:00
Andreas Kling
82b02ed82b LibGUI: Use TextElision::Right for GButton captions. 2019-04-04 15:20:02 +02:00
Andreas Kling
4533539e8a Painter: Add text elision support (only right-hand side supported.)
Some window titles didn't fit on the taskbar buttons, so I needed a way
to collapse the remaining part of the text into "..."
2019-04-04 15:19:04 +02:00
Andreas Kling
ce7341be87 WindowServer: Add WM_SetActiveWindow client request and use it in Taskbar.
This makes it possible for Taskbar to switch windows. :^)
2019-04-04 14:38:53 +02:00
Andreas Kling
8a50218190 Taskbar: Left-align the text on taskbar window buttons. 2019-04-04 14:16:09 +02:00
Andreas Kling
89c544d97b LibGUI: Allow specifying GButton text alignment. 2019-04-04 14:15:57 +02:00