Commit graph

669 commits

Author SHA1 Message Date
Andreas Kling
68abc103f7 ProtocolServer: Report success after stopping a download 2020-05-05 23:56:20 +02:00
Sergey Bugaev
69c23aaedb ProtocolServer: Use unveil() 2020-05-05 11:07:06 +02:00
Andreas Kling
eb6e35a1be ProtocolServer: Pass HTTP response headers to the client
We now store the response headers in a download object on the protocol
server side and pass it to the client when finishing up a download.

Response headers are passed as an IPC::Dictionary. :^)
2020-05-03 23:01:58 +02:00
Andreas Kling
3c0ca04ad3 LookupServer: Only pass A record responses to clients
This works around an issue where we'd try responding to a LookupServer
client with an empty CNAME record.
2020-05-03 14:24:54 +02:00
Andreas Kling
82d83f0fe1 WindowServer: Remove debug spam when creating new windows 2020-05-03 14:24:54 +02:00
AnotherTest
06cf9d3fb7 ProtocolServer: Implement and handle download progress
Also updates `pro` to display download progress and speed on stderr
2020-05-03 12:59:26 +02:00
Linus Groh
751f813f6a WindowServer: Update desktop window rect on resolution change
Fixes #2073.
2020-05-03 00:41:35 +02:00
Andreas Kling
37d1b0c875 WindowServer: Reset double-click timers for back/forward buttons
Thanks for movAX13H for pointing this out!
2020-05-03 00:29:57 +02:00
Andreas Kling
67b92a7d5f WindowServer+LibGUI: Support the 4th and 5th mouse buttons
We'll call the "Back" and "Forward" since that's what they are normally
mapped to in some other systems.
2020-05-02 22:07:43 +02:00
Sergey Bugaev
d5582596a9 SystemServer: Bump the default listening socket backlog to 16
We now have many clients that are trying to connect to the WindowServer
simultaneously on startup. We could make this configurable, but 16 should
be enough for anybody ™.
2020-05-02 15:59:37 +02:00
Andreas Kling
3331098aee WindowServer+LibGUI+Taskbar: Don't include frameless windows in lists
Frameless windows don't need to show up in the taskbar or the switcher.
2020-05-02 12:24:23 +02:00
AnotherTest
7670e5ccf0 LibCore+LibHTTP: Move out the HTTP handler and add HTTPS 2020-05-02 12:24:10 +02:00
Andreas Kling
745b0b27fd WindowServer+LibGUI: Automatically close child windows with parent
If a window has child windows when it's destroyed, WindowServer will
now automatically tear down all of its children as well.

This is communicated to the client program through a vector of window
ID's included with the response to WindowServer::DestroyWindow.

This does feel a little bit awkward, but managing it on the client side
also seems a bit awkward.
2020-05-02 01:29:55 +02:00
Andreas Kling
d847304cb9 WindowServer+LibGUI: Add "frameless" window flag
This allows you to create windows with no title bar or window frame.
2020-05-02 01:29:55 +02:00
Andreas Kling
bb7eb3e104 WindowServer+LibGUI: Remove unused Window::show_titlebar() flag
Nobody was using this flag, so let's stop maintaining it. It's easy to
add it back if we ever want the behavior.
2020-05-02 01:29:55 +02:00
Andreas Kling
2ac1fbef4f WindowServer: Don't allow parent windows to go above their children
Whenever a parent window is moved to front, we now follow up by
immediately moving its children to front as well.
2020-05-02 01:29:55 +02:00
Andreas Kling
c6899b0910 WindowServer: Move child windows together with their parents
When moving a window, we will now move any child windows by the same
position delta as the parent. This makes ComboBox popup list windows
follow the window they were opened by, which looks nice. :^)
2020-05-02 01:29:55 +02:00
Andreas Kling
6228f72b87 LibGUI+WindowServer: Inform WindowServer about parent/child windows
If a window has another window in its Core::Object ancestor chain,
we now communicate that relationship to WindowServer so that it can
act with awareness of parent/child windows.
2020-05-02 01:29:55 +02:00
Andreas Kling
2822b1035f WindowServer: Fix some pixels in menus after window border changes 2020-04-30 22:15:16 +02:00
Andreas Kling
c3a2dffe29 WindowServer: Tweak window icon menu popup location 2020-04-30 22:15:16 +02:00
Andreas Kling
23d99e92b9 WindowServer: Add action icons to the window menus 2020-04-30 12:58:38 +02:00
Andreas Kling
a9f6f862e2 WindowServer: Fix typo (backgound_color => background_color) 2020-04-30 09:04:39 +02:00
Andreas Kling
7dadb75e28 WindowServer: Pop up the window menu at bottom left of window icon
When clicking the window icon, we now pop up the window menu at the
bottom left of the icon, no matter where you clicked it.

Right-clicking the title bar still pops up at the event position.
2020-04-29 12:07:40 +02:00
Andreas Kling
13dcd9a037 WindowServer: Fix build after FBResolution changes 2020-04-29 11:41:34 +02:00
Andres Vieira
8a417c311f WindowServer: Change the desktop background colour on theme change 2020-04-28 17:04:21 +02:00
Andres Vieira
19c744ab82 WindowManager: Allow compositor to have an empty bitmap as a wallpaper
This will make the compositor draw our colour wallpaper, instead
2020-04-28 15:22:22 +02:00
Linus Groh
421b6cd393 WebServer: Add optional positional port agument
This allows us to start WebServer on a port other than 8000, or multiple
instances of it at the same time :^)

Also print out what port was being used in the end.
2020-04-26 14:46:32 +02:00
Andreas Kling
9badcff1ba WindowServer: Don't allow activating disabled menu items with keyboard 2020-04-24 17:29:42 +02:00
Andreas Kling
e786444ffa WindowServer: Fix name typo in descend_into_submenu_at_hovered_item() 2020-04-24 17:26:16 +02:00
Andreas Kling
cbb3c7aade WindowServer: Skip over disabled menu items during keyboard navigation 2020-04-24 17:24:09 +02:00
Andreas Kling
a639172760 WindowServer: Don't allow resize-grabbing window underneath title bar 2020-04-23 19:27:33 +02:00
Andreas Kling
5eb4d0f832 WindowServer: Make vertical segment under title bar 1px thicker 2020-04-23 17:54:57 +02:00
Andreas Kling
81ebc0cfe3 WindowServer: Tweak window frame height 2020-04-23 15:36:00 +02:00
Andreas Kling
f0cac83243 WindowServer+LibGfx: Make window borders 1px thicker 2020-04-23 14:37:13 +02:00
Andreas Kling
5326eebb1b WindowServer+LibGUI: Notify DisplayLinks at 60 fps no matter what
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. :^)
2020-04-22 00:07:48 +02:00
Andreas Kling
0fa7cf70b5 WindowServer+SystemMenu: Check the current system theme on startup 2020-04-21 18:40:52 +02:00
angel
1032ae0140 WindowServer: Allow the system menu to be open when a modal is shown 2020-04-21 16:54:34 +02:00
angel
b9be57a9cd WindowServer: Don't process menu bar events when modal is open
This prevents accesing the parent window menubar when a modal is
currently open, which was not a desired behavior.
2020-04-21 16:27:36 +02:00
angel
5250f4fb90 WindowServer: Don't ignore modal events when showing menus
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.
2020-04-21 16:27:36 +02:00
angel
ae20775fb7
WindowServer: Unset active input window on active window change (#1901)
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.
2020-04-21 15:46:27 +02:00
Andreas Kling
c5730ed6a3 WindowServer: Fix AppletManager build 2020-04-19 20:24:03 +02:00
Andreas Kling
3b434068eb WindowServer: Don't crash when encountering unsorted menu applets
Fixes #1862.
2020-04-19 19:40:04 +02:00
Andreas Kling
1b2d954d47 WindowServer: Remove debug spam in set_active_window() 2020-04-19 13:56:41 +02:00
Andreas Kling
453b678346 WindowServer: Don't automatically focus desktop window when added
Normally we focus any window that's added to the window stack. However,
for WindowType::Desktop this gets annoying since if the desktop manager
comes up after other GUI processes have already started, it steals the
focus from them.

Solve this by only auto-focusing desktop windows if they are the very
first window added.
2020-04-19 12:09:48 +02:00
Linus Groh
3474d7c88e WindowServer/LibGUI: Enforce minimum window size 2020-04-19 02:07:45 +02:00
Andreas Kling
0345fdcb77 WindowServer: Allow WindowType::Desktop windows to become active
This allows us to focus the desktop and interact with it normally. :^)
2020-04-18 22:15:59 +02:00
Andreas Kling
95805c0e56 WindowServer: Give the desktop window the whole exact desktop rect 2020-04-18 21:18:11 +02:00
Andreas Kling
3d31f2e44b WindowServer: Add WindowType::Desktop
This new window type can be used to implement a desktop file manager
for example. :^)
2020-04-18 21:10:16 +02:00
Brendan Coles
0a483cf677 ProtocolServer: did_finish_download: Do not create 0 byte shared buffer
`PSClientConnection::did_finish_download()` no longer tries to create
a zero byte shared buffer when `download.payload().data()` is zero
bytes in length.

Fixes #1821
2020-04-17 13:30:13 +02:00
Andreas Kling
bdc753ebd2 AudioServer: Use NumericLimits<T> 2020-04-15 16:58:46 +02:00