Commit Graph

57768 Commits

Author SHA1 Message Date
Michael Lotz 82873c6ece RemoteHWInterface: Fix lost drag bitmap on cursor change.
The drag bitmap was lost because the original, uncombined, cursor was
sent on cursor change.
2017-11-21 22:18:17 +01:00
Michael Lotz 4d9e21b824 Remote{Message|DrawingEngine}: Add some more debug output. 2017-11-21 22:18:17 +01:00
Michael Lotz 5fb27ee2c4 RemoteDrawingEngine: Implement StringWidth.
It doesn't actually seem to be called though.
2017-11-21 22:18:17 +01:00
Michael Lotz df55bcf5a0 RemoteDrawingEngine: Fix position of gradient in FillShape.
It wasn't added at the end.
2017-11-21 22:18:17 +01:00
Michael Lotz 91c1d3dbb3 RemoteDesktop: Implement support for BAffineTransform.
It is currently somewhat broken client side though.
2017-11-21 22:18:17 +01:00
Michael Lotz f7fb4538de RemoteDesktop: Create states for unknown tokens.
This allows to recover from reconnects where creation of some tokens
may have taken place before the client was fully connected.
2017-11-21 22:18:17 +01:00
Michael Lotz f609f4fa64 RemoteHWInterface: Use screen change listener to update mode.
This allows dynamic reconfiguration of the size of the virtual desktop
to the dimensions desired by the client.
2017-11-21 22:18:17 +01:00
Michael Lotz f3e8ed4d48 app_server: Implement screen changed hooks and notifications.
The ScreenOwner interface gets an additional ScreenChanged() hook. It
is implemented in the Desktop class to automatically set the preferred
screen mode on the changed screen.

The HWInterfaceListener, previously only used by the downstream
DrawingEngine, gets an additional ScreenChanged() hook as well to inform
an upstream client of a changed screen.

The ScreenManager ties these two mechanisms together.
2017-11-21 22:18:17 +01:00
Michael Lotz 5ed41cffff RemoteDesktop: Switch connection direction and simplify client.
Instead of the server connecting back to a listening client, make it
into a more traditional setup with the server listening on a port and
the client connecting to it.

The client can now either connect directly, unencrypted and without the
ability to trigger listening and specifying a command, or through SSH,
as before with the possibilty to run a target application and causing
the creation of the listener.

With the direction change, there's only the need for one, local, port
forward with SSH, which simplifies things.
2017-11-21 22:18:17 +01:00
Adrien Destugues b140a1c340 NetworkAddressResolver: cache needs to be locked
It is not a good idea to have a thread get an address from the request
cache, while another thread is deleting said address as the cache has
grown too large. Add a lock around the cache access to make it safe.
2017-11-21 22:15:32 +01:00
Adrien Destugues 4c99992724 Deskbar: update time format when locale changes.
Thanks to Skipp_OSX for reminding me that B_LOCALE_CHANGED was already
handled in Deskbar.
2017-11-21 22:15:31 +01:00
François Revol e96fd79311 ata_adapter: Remove bad casts for ram_address()
We now accept and return a phys_addr_t as we ought to.
2017-11-21 21:44:02 +01:00
François Revol 4dde854c8a silicon_image_3112: Remove bad casts for ram_address()
We now accept and return a phys_addr_t as we ought to.
2017-11-21 21:44:02 +01:00
François Revol aef94baf32 ISA: fix ram_address() to use phys_addr_t for completeness
I don't know of any driver actually making use of it, but some weird
architecture might want to emulate an ISA bus to reuse a driver maybe...
2017-11-21 21:44:02 +01:00
François Revol 16bb99fdac PCI: fix ram_address() to use phys_addr_t
Since it handles physical address it should really be this.

It's not like many drivers actually used it anyway. It shouldn't harm
compatibility, drivers calling it with only 32bit would leave garbage in
the higher bits but since on x86 it's a noop anyway, it would end up in
the MSB register tha's ignored because it expects a 32bit result.
2017-11-21 21:44:01 +01:00
Janus 66672a5fa4 Fix broken convention 2017-11-21 21:32:21 +01:00
Kacper Kasper 2b7297f879 DeskCalc: accept file drops.
* Fixes #9283.
2017-11-21 21:15:16 +01:00
Janus d18b272d3e [PowerStatus] The menu item quit doesn't close the Tracker
* Fixes #13790
2017-11-21 18:13:00 +01:00
Kacper Kasper f4a1f9c06a ICNSTranslator: add missing B_TRANSLATEs. 2017-11-21 20:08:29 +01:00
Kacper Kasper 2c856023e9 DeskCalc: fix cut off buttons.
* Window frame might change based on set size limits.
  Creating view with rectangle used to create the window causes it
  to anchor outside the window.
  To address that pass current frame rectangle to the view.
* Fixes #13167.
2017-11-21 20:08:29 +01:00
Adrien Destugues 6663167b59 pkgman: improve progress bar
- Do not update more than twice a second
- Do not use tabs, so we can reliably compute the string width
- Cleanup and tweak other parts of the code

There is still a glitch when resizing Terminal, but it isn't as bad as
before. Ideally, using the SIGWINCH signal would solve that, but it is
sent to the app only when you release the mouse after a release
operation, so in our case, it is already too late.
2017-11-21 18:24:44 +01:00
Adrien Destugues feabff3ebb TeamMonitor: redo layout
Add several sizing constraints to avoid the window becoming too small.

Fixes #7560.
2017-11-21 16:16:12 +01:00
Augustin Cavalier 3b3688c7a5 fs_shell: Change {set_}real_time_clock to match the new definitions. 2017-11-21 15:18:11 +01:00
Adrien Destugues 8c82d0edd5 DeskBar: cache time and date formats
Creating BDateTimeFormat and BDateFormat objects is a costly operation
(it loads locale data from ICU, etc). So, we should do it only once when
the format changes, instead of doing it each time we format a date
or time.
2017-11-21 15:06:46 +01:00
Janus b06e48bb2b [PowerStatus] Avoid crashes on exit when Info window is opened
* Fixes #10885
2017-11-21 14:26:49 +01:00
Adrien Destugues 950b5664df FirstBootPrompt: fix layout
In some languages, the buttons would end up outside of window bounds, as
changing the BTextView content does not automatically update the window
size (even with B_AUTO_UPDATE_SIZE_LIMITS). So, we need to manually call
ResizeToPreferred after changing the text.

However, this exposed another problem: the view size is computed using
GetHeightForWidth, with a width as small as allowed by layout
constraints. In our cases, there weren't much layout constraints so we
would end up asking the text view to compute its height for a width of
52px, leading to a very high window. Add some explicit sizing
constraints to the text view and language list to make sure we get a
sane size.

Also tweak the layout a little to allow the keymap menu field to be
wider than the language list view, and make the window not resizable as
that makes it much easier to keep things under control and there isn't
really a need to resize it.
2017-11-21 12:19:56 +01:00
Adrien Destugues 24e63de5d3 Style fix: parameters should have a name. 2017-11-21 12:19:56 +01:00
Kacper Kasper 830758ad45 PowerStatus: convert to BTabView.
* Move text inside battery if possible.
* Fix location of the spark.
* Fixes #5422 and #7330.
2017-11-21 10:31:33 +01:00
Kacper Kasper d1929affbb PowerStatus: use layout to draw info strings. 2017-11-21 10:31:32 +01:00
Adrien Destugues 3a2b67b5ae Support for configuring screen backlight
Accelerant interface:
Introduce new hooks B_SET_BRIGHTNESS and B_GET_BRIGHTNESS. Brightness is
a float in the 0..1 range.

App_server:
Forward brightness things between BScreen and the accelerant.

intel_extreme:
Implement the hooks. Note that this only works for laptop panels, but
the driver will pretend to support it in other cases as well.

Screen preferences:
If the accelerant supports the B_GET_BRIGHTNESS hook, allow to set
brightness with a slider. Otherwise, the slidere is hidden and these
changes aren't visible.
2017-11-21 09:12:18 +01:00
Adrien Destugues c5f9934cd8 SerialConnect: optimize drawing
The libvterm implementation was sending characters to app_server one by
one. This made it very slow to update the view and SerialConnect would
have noticeable flickering.

We now look through each line and try to find ranges of characters with
the same attributes. We can then draw each of these with a single
FillRect+DrawString. In the normal case (no special attributes or colors
anywhere), this means just one call per line, plus two for the cursor.
2017-11-20 21:54:30 +01:00
François Revol dd1454bd96 Defer calling arch_debug_console_init_settings
when we can actually read driver settings :-)
2017-11-20 18:16:54 +01:00
François Revol 7c7390c719 work around "cast specifies signature type" from gcc2
...when build by gcc6 or 7 on my Debian Sid.
2017-11-20 17:18:08 +01:00
Alexander von Gluck IV 2dce5eecef build/arm: Correct missing sources in search
* Group into local var to prevent recurrence.
2017-11-20 09:36:56 -06:00
Alexander von Gluck IV a42249db2d arm: Add 8250 omap variant uart driver
* Untested, someone with an omap3,4,5 could though.
2017-11-20 09:16:58 -06:00
François Revol 0835170c80 Actually use the serial port and speed from the kernel settings
Turns out we just reused the already set values, disregarding the new ones.
2017-11-20 11:44:43 +01:00
François Revol 587b70d5cd Add a get_driver_settings debugging tool 2017-11-20 11:23:34 +01:00
Adrien Destugues d1805b9a36 BSecureSocket: use opt-out to select ciphersuites.
We just want to disable known broken ones, rather than opt-in for
working ones. This keeps the list of authentications shorter and is more
future proof.
2017-11-20 09:44:50 +01:00
Adrien Destugues c312da45a8 media_client: print usage in case of missing arguments
Now the obvious "media_client somefile.wav" will tell you what to do.
2017-11-20 09:44:50 +01:00
Jérôme Duval 1f384bf443 atheros813x and attansic_l1: also switch the mii Jamfiles. 2017-11-19 12:45:26 +01:00
Jérôme Duval c6ca84c3a0 attansic_l2: sync with FreeBSD 11.1. 2017-11-19 11:54:19 +01:00
Jérôme Duval c8f44197fe attansic_l1: sync with FreeBSD 11.1. 2017-11-19 11:44:23 +01:00
Jérôme Duval cf42509b42 atheros813x: sync with FreeBSD 11.1. 2017-11-19 10:33:39 +01:00
John Scipione 5c6208cc0c Tracker: Line TitleView up with scroll bar arrow
Make TitleView a few pixels shorter at the default font size so that
it lines up with the scroll bar arrow to its immediate right.

Note the font size used in the title view before and still is 9px
(12px * 3/4)

Make this the minimum TitleView height even for smaller font sizes
so that the title view never is shorter than the height of a
scrollbar button.  Make the minimum font size for TitleView 8px
because 6px (8px * 3/4) was just too small to read.

As font size is made larger it will increase the height of the
titlebar to accomodate the increased font size and consequently no
longer line up with the scrollbar arrow.

The code to scale the bar height via the font height was taken from
BColumnListView. The code to position the title in the middle of the
title bar was also taken from BColumnListView.

Some included style fixes:
* Rename height to fontHeight
* Rename loc to titleLocation
* 80 column limit
2017-11-18 16:25:01 -08:00
Janus 24c9b9df7a [PowerStatus] Fixes some drawing glitches
* Fixes the position of the lightning over the battery
* Fixes the selection in the info Window (Why is the selected color hardcoded?)
* Fixes #13784
2017-11-19 01:05:38 +01:00
Jérôme Duval aafb7e69a9 ipro1000: MSI interrupts use a handler, no check needed.
tested on Qemu with model=e1000e.
2017-11-18 23:10:25 +01:00
Alexander von Gluck IV f6c47144a6 kernel/uart: Refinements to irq and FIFO management 2017-11-18 13:20:53 -06:00
Alexander von Gluck IV dc9cdc37d0 dtb/rpi2: Correct UART base frequency.
* https://github.com/raspberrypi/firmware/issues/643
* Mimics what the RaspberryPi guys adjusted it to in
  the firmware.
* Solves corrupted UART serial on the RaspberryPi 2
* I think linux live-probes this frequency via dt-bindings.
2017-11-18 13:20:52 -06:00
Jérôme Duval dcdad04383 pcnet: Update with the 11.1 release of the le/pcn driver.
* switch compat layer.
* tested on Qemu, model=pcnet.
2017-11-18 18:45:37 +01:00
Jérôme Duval ad7432f214 freebsd11_network: adapt code based on needs of the pcnet R11.1 driver. 2017-11-18 18:44:18 +01:00