Commit Graph

54434 Commits

Author SHA1 Message Date
Jessica Hamilton
8f3d6d192f Revert "BPrintJob: fixed crash."
This reverts commit 1805bbf29b.
2015-08-30 14:41:16 +12:00
Jessica Hamilton
d7a9cbde91 BAlert: don't center ourselves if we've already been positioned. 2015-08-30 14:39:36 +12:00
Jessica Hamilton
21c3286b62 BAlert: make SetShortcut() work again.
In hrev49481, the call to AddCommonFilter was accidentally
removed, preventing SetShortcut() from working. The filter
has also been updated to enumerate all buttons, rather than
a maximum of the first three.
2015-08-30 14:06:58 +12:00
Jessica Hamilton
a84dc7543a BAlert: move setting default button into AddButton().
This properly fixes the crash in #12271, introduced by
hrev49481.
2015-08-30 14:06:57 +12:00
Adrien Destugues
0717601a7f ffmpeg encoder: do not use deprecatred function
Replace avcodec_encode_audio with avcodec_encode_audio2. The latter
provides us with more information on the encoded data, so we can avoid
guessing things on our own. It also handles memory allocations on its
own, which fix some cases where we would provide a too small buffer.
2015-08-29 23:14:04 +02:00
Adrien Destugues
75d1eb3a59 assert.h: reintroduce headers guard for function declarations.
The POSIX standard requires us to allow assert.h to be included multiple
times with differnt values of NDEBUG. So we can't have a global header
guard on the files. However, we must also make sure that we don't
declare functions multiple times in that case. Re-introduce an header
guard on the part of the file where we declare functions, only.

Fixes lots of warnings when building Netsurf.
2015-08-29 23:14:03 +02:00
Michael Lotz
0a6d595951 Add system_time to the Jamfile, missed in hrev49598. 2015-08-29 19:33:27 +02:00
Michael Lotz
5ce7069d15 Add script that prints the uptime after waiting for all servers.
It waits for the message port of each application to become available
using waitfor and then waits for the application to actually reply
using hey. This establishes the criterion of the boot process being
complete as "all servers (and Tracker & Deskbar) are started and
respond to messages".
2015-08-29 19:15:47 +02:00
Michael Lotz
b11eb89c2d Add system_time bin command which just prints system_time().
This can be used by scripts to do verious performance measurements.
Specifically it can be used to measure the boot time since it represents
the uptime.
2015-08-29 19:15:47 +02:00
Dario Casalinuovo
48b2cb3771 BMediaRoster: Pass unhandled messages to the base class
* While it shouldn't be a big problem, the bebook states
that it's very important to do so.
2015-08-29 16:13:44 +02:00
Stefano Ceccherini
1805bbf29b BPrintJob: fixed crash.
Since hrev49481, BAlert sets its default button in Go(), and not in the
constructor. So DefaultButton() will return NULL if Go() hasn't been called
yet.
Moreover, BAlert now centers itself on screen in Go() and not in the costructor,
so move it away from screen after the Go() call.
Fixes #12271, although there should be a nicer way to implement this.
2015-08-29 15:18:59 +02:00
Stefano Ceccherini
e2eb9b7baf Removed empty line 2015-08-29 15:18:59 +02:00
Michael Lotz
c0c883cf8e BMessage: Fix precedence of KMessage vs. size check.
A KMessage request always needs to be honoured, regardless of the data
size.

KMessage does not currently protect against messages that are too large,
but this needs to be solved in KMessage when it becomes a problem.
2015-08-29 11:25:46 +02:00
Michael Lotz
bc5a7a3749 keystore_server: Fix crash on request window close.
The outside waiting mechanism is responsible for quitting the dialog so
prevent it from quitting itself.
2015-08-29 10:53:28 +02:00
Michael Lotz
515e648d7b keystore_server: Use B_CLOSE_ON_ESCAPE in request dialogs.
Instead of doing it manually.
2015-08-29 10:53:27 +02:00
Michael Lotz
b92e2c086f keystore_server: Resize request windows to preferred size.
Long application signatures and paths could previously take up too much
space, causing the buttons to be cut off or become completely invisible.

Actually fixes #11367.
2015-08-29 10:53:27 +02:00
Humdinger
e10d416e69 Improved warning alert. Spaces were missing. 2015-08-29 08:27:20 +02:00
autonielx
796e1fd04f Update translations from Pootle 2015-08-29 06:37:02 +02:00
Michael Lotz
5cf6c0fd3b launch_daemon: Create/inject ports on launch instead of upfront.
The application is now launched suspended and the ports are created
and transferred to the launched team before its main thread is
resumed.

The ports are therefore owned by the launched team instead of the
launch_daemon. This is important when sending messages by area, as
the port owner is used to determine where the data area needs to be
transferred to. This commit therefore fixes #12285.

Note that it is still possible to get at the ports with find_port()
while they are still owned by the launch_daemon. This should not be a
problem however, as these ports are not supposed to be found this way
but only through BLaunchRoster::GetData(), which is synchronized with
the above process.

Creating the ports in the launch_daemon still has the benefit of
returning valid communication ports earlier, i.e. without having to
wait for the launched application to actually become ready.
2015-08-28 22:52:50 +02:00
Michael Lotz
5b9f6b5485 BRoster: Add launchSuspended option to _LaunchApp().
It allows to launch the app, but keep its main thread suspended instead
of automatically resuming it.

Also add appThread argument which allows to retrieve the main thread of
the launched team.
2015-08-28 22:52:50 +02:00
Axel Dörfler
df5aeb6dda AHCI: fixed constant mixup, minor cleanup.
* TRANSITION_... was incorrectly changed from the original patch.
* Divided it into two constants, and also prefixed the new constants with
  the register fields they are valid for.
* Fixed incorrect usage of |= and removed the corresponding TODO comments.
* Moved some reoccurring code into their own methods.
* Added check for the ST bit in the command register for the interrupt
  hard reset, too.
* This closes ticket #12295, thanks Anarchos!
2015-08-28 19:26:14 +02:00
Sylvian Kerjean
5584c22fdd AHCI: Fix boot failures due to "Port Connect Change" IRQ storm.
Signed-off-by: Axel Dörfler <axeld@pinc-software.de>
2015-08-28 19:26:14 +02:00
Dario Casalinuovo
8a28f84965 Media: Fix restart button alignment 2015-08-28 18:27:16 +02:00
Dario Casalinuovo
5d8765c0af media_server: No need to call Roster() every time 2015-08-28 18:27:16 +02:00
Dario Casalinuovo
1c3d7e0c68 MixerControl: Add more safeness for Roster() errors 2015-08-28 18:27:16 +02:00
Dario Casalinuovo
d15321ff90 BMediaRoster::Roster Use BAutolock 2015-08-28 18:27:16 +02:00
Dario Casalinuovo
be7d9d3f5d BMediaEventLooper: With B_WOULD_BLOCK we may still handle an event 2015-08-27 19:45:11 +02:00
Dario Casalinuovo
90cdf5e42e BMediaNode::WaitForMessage: protect it over negative timeouts 2015-08-27 19:45:10 +02:00
Stefano Ceccherini
d6039d2b23 Midi: Remove some duplicated code
Introduced new private read/write_midi_settings() and used them
in MidiSettingsView and SoftSynth.
2015-08-27 11:51:57 +02:00
Augustin Cavalier
281409fdc0 Revert accidental addition to Jamfile. 2015-08-26 15:54:15 -04:00
Augustin Cavalier
41f43d568f Screen: Rework AlertView to just use BAlert.
Fixes #12330.
2015-08-26 14:42:14 -04:00
Augustin Cavalier
1ea54e567e docs/user: BAlert: Fix incorrect ::TextView() docs.
TextView() returns *the* BTextView the BAlert is using, not a new
TextView with the contents of the BAlert (which is what this seemed to
imply).
2015-08-26 14:42:11 -04:00
Dario Casalinuovo
da18151469 Revert "MediaNode: Wait for 0 time if the absolute timeout is in the past"
This reverts commit ae9cbf9c4e.

* Thanks to Pawel Dziepak for reporting!
2015-08-26 22:54:01 +02:00
Michael Lotz
14156a33ac launch_daemon: Delegate launch data replies to Job.
Previously the LaunchDaemon would send out its own team id when a given
job was not yet launched, leading to invalid BMessengers once the port
owner changed to the actually launched team.

The launch of the target team and the launch data replies were also not
synchronized, which could lead to the launched team getting a reply
pointing to the launch_daemon when requesting data for itself. This is
the case for the BRoster init of the registrar. The fix in hrev49561
therefore didn't always work, because the registrar would sometimes get
the launch_daemon team id instead of the id of itself. It would later
try talking to the launch_daemon, which obviously never replied, leading
to #12237.

The LaunchDaemon now delegates the launch data reply to the Job instead.
The Job either replies directly, in case it has already been launched,
or queues the reply for when the launch completes. This causes launch
data requesters to block until the launch attempt is completed, but
won't block the LaunchDaemon message loop.

This commit introduces the seperate fLaunchStatus to properly handle the
ambiguity of fTeam being < 0, which is the case for both, when no launch
was attempted and when the launch failed. This new field now determines
what IsLaunched() returns and how launch data replies are handled.

The new launch status is additionally protected by the launch status
lock, which will later probably be made broader in scope to protect
against race conditions once service monitoring is implemented.
2015-08-26 22:24:00 +02:00
Michael Lotz
ee5575d9b3 BRoster: Apply no-registrar mode in a few more cases.
Avoids some more attempts at communicating with the registrar if the
no-registrar flag has been set.
2015-08-26 22:23:59 +02:00
Dario Casalinuovo
ae9cbf9c4e MediaNode: Wait for 0 time if the absolute timeout is in the past 2015-08-26 17:22:13 +02:00
Dario Casalinuovo
dfe056fd6a BMediaEventLooper: Continue code improvements. 2015-08-26 17:22:10 +02:00
Dario Casalinuovo
d9971ae7aa Media: Show alert while media services restart 2015-08-26 16:39:42 +02:00
Dario Casalinuovo
9a36e655d7 radeon_hd: Add missing id for Radeon HD 8490 2015-08-25 12:43:53 +02:00
Stefano Ceccherini
c34e5f4dd5 B_BIG_SYNTH_FILE and B_LITTLE_SYNTH_FILE are deprecated.
Small style change in midi headers.
2015-08-24 17:18:26 +02:00
Stefano Ceccherini
3ffaf5c263 MidiSettingsView: renamed box label
Renamed box label from "SoundFont" to "Available SoundFonts", hopefully
improves the user experience by making it clearer that this is a list
of the available soundfonts.
2015-08-24 10:23:28 +02:00
Stefano Ceccherini
2f41383c3b BBitmap: Archive the data also if "deep" is not set
Fixes #12326
2015-08-24 10:21:31 +02:00
Stefano Ceccherini
65b4405ecc BSoftSynth: Fixed auto selection of soundfont.
When no midi settings file was available, BSoftSynth should use the well known
TimGM6mb.sf2 soundfont. This wasn't working, since the code looked in the wrong
path (we have to append "synth" to the path returned by find_directory).
In case this SF is not present, now we try harder not to fail, and look for any
soundfont available in the system and user directories.
Fixes ticket #12325 although the selected soundfont is not written to the
user settings file.
2015-08-24 10:04:17 +02:00
Stefano Ceccherini
a6fb27a3f6 Improved comment. Added TODO 2015-08-24 10:03:54 +02:00
Stefano Ceccherini
7ed2a44376 Fix naming 2015-08-24 09:34:02 +02:00
Jessica Hamilton
579efee783 package server: fix off-by-one error in RemoveLastComponent() 2015-08-24 15:53:56 +12:00
Michael Lotz
f11d686c96 launch_daemon: Remove extra quoting around env variables.
The extra quotes aren't needed and cause problems when not parsed
through a shell. For example LD_PRELOAD which is handled by the
runtime_loader directly failed to work as there was no way to remove
the extra single quotes.

Note that quotes and single quotes can still be added to the variables
through respective quoting in the driver settings syntax.
2015-08-23 15:17:39 +02:00
Michael Lotz
8b9bb054f4 libroot_debug: Replace two more uses of printf in guarded heap.
Use the internal print_stdout() instead as done when printing the
stack traces.
2015-08-23 13:19:12 +02:00
Michael Lotz
5dbea46970 libroot_debug: Track freeing thread in guarded heap separatley.
Previously the thread member was overwritten with the freeing thread
when a page was freed, leading to confusion when hitting unallocated
pages due to the debugger message still stating "allocated by thread".

Track the freeing thread separately as it might be interesting to know
both, which thread initially allocated and which thread eventually freed
an allocation.
2015-08-23 13:10:12 +02:00
Michael Lotz
8074f0b94b launch_daemon: Replace the remaining putenv() calls by setenv(). 2015-08-23 12:36:12 +02:00