Commit Graph

8731 Commits

Author SHA1 Message Date
Dario Casalinuovo dfecb37aee Introduce new experimental class MediaStreamer 2017-05-04 14:08:07 +02:00
Axel Dörfler e9843da357 KPath: Added LAZY_ALLOC flag.
* This allows KPath to not allocate a buffer when initialized
  without path.
* Added test cases for this.
* Added test for LockBuffer().
* Enhanced tests to allow building them in debug mode.
* Moved calling vfs_normalize_path() into own private method.
* Improved error codes; B_NO_MEMORY is now only returned if the
  allocation actually failed.
* If used with LAZY_ALLOC, Path() and LockBuffer() are now allowed
  to return a NULL path.
2017-04-30 17:14:45 +02:00
Axel Dörfler eac83fb33e KPath: Replaced booleans with flags field.
* No functional change intended; I chose the flags in a way that it
  should still work even if I missed a reference.
2017-04-30 17:13:39 +02:00
Brian Hill b8a6139981 Fix glitch in Screen prefs when changing background color.
When both Backgrounds and Screen are open, if the workspace color is changed
in Backgrounds the monitor preview in Screen will now refresh to the new color.

Also added a BAlert in BackgroundsView.cpp when failing to change the
background image.

Signed-off-by: Adrien Destugues <pulkomandy@pulkomandy.tk>

Fixes #13286.
2017-04-30 10:29:39 +02:00
Axel Dörfler 3582d4fe85 Minor style cleanup. 2017-04-29 14:37:56 +02:00
Dario Casalinuovo a33c8f4c2a MediaClient: Some more consistency in args order 2017-04-28 02:13:51 +02:00
Jérôme Duval 43542cabdd runtime_loader: increase max length for image names.
* was previously 32, which would truncate longer shared object names.
* fixed #13436.
2017-04-20 18:23:36 +02:00
Jérôme Duval 41458d977a limits.h: define PIPE_BUF. 2017-04-19 17:52:28 +02:00
Jérôme Duval 00796434c6 limits.h: bump _POSIX_SEM_NSEMS_MAX to 256.
128 was too low for Python3.
2017-04-16 13:49:41 +02:00
Dario Casalinuovo 0cc5ecb8ca MediaClient: IDs should be signed integers
* It's very important to use a negative value to identify
non valid or uninitialized connections. Additionally, it's preferred
to don't interfere with media_kit types as long as the framework use
it in the backend.
2017-04-14 17:28:35 +02:00
Adrien Destugues 56403b6373 limits.h: define PAGE_SIZE only if XSI is requested
limits.h is part of the C standard, but POSIX and XSI extend it with
various defines. We should not add these unless the application requests
support for them.

In this case, PAGE_SIZE should only be defined if XSI support is
requested by defining _XOPEN_SOURCE. Note that PAGESIZE (plain POSIX for
the same thing) and B_PAGE_SIZE are alternatives that remain available.
2017-04-13 21:14:41 +02:00
Adrien Destugues b68cf9d6f6 elf.h: add more architectures.
Mostly I need EM_AVR to build avrdude on Haiku.
2017-04-11 18:59:06 +02:00
Alexander von Gluck IV 6516aed58b network preflet: Make InterfaceListItem dumber
* Allows us to use InterfaceListItem for non-physical
  interface things (like a VPN connection)
2017-04-05 18:46:10 +00:00
Fredrik Holmqvist e5c95a01ff Use 64 bit addressing for ACPI on 32 bit builds.
32 bit builds with PAE are so much fun. It's like
64 bit without all the extra registers...
2017-03-28 21:34:42 +02:00
Alexander von Gluck IV 8cc5325ad5 agg: Pull in updated scanline + basics header from 2.4
* Resolves #13382
2017-03-18 18:59:30 -05:00
Augustin Cavalier ad05d1f087 libs/agg: Remove GPC.
It was licensed with a "no commercial usage allowed" license, which if
we were using it would be a gray area at best. We weren't using it at all,
and AGG seems to have disabled building it by default, so just remove it
from the tree entirely.

Briefly discussed on IRC.
2017-03-18 19:27:45 -04:00
Alexander von Gluck IV 63863c9849 cpu_type.h: Fix missing ;, sorry for spam 2017-03-12 15:11:02 -05:00
Alexander von Gluck IV 54066ddbb7 OS.h: Add AMD Ryzen CPU name identification.
* Update cpuidtool.c to new post-smp rework name
  calculation
2017-03-12 14:46:02 -05:00
Dario Casalinuovo 5854fc4a7a MediaClient: Add remaining wiring for input/output functionality
* BufferReceived is renamed HandleBuffer.
* Update doc.
* Implement buffer production private methods.
2017-03-10 01:02:15 +01:00
Jim Barry d47434c2ec Added "explicit" specifier to constructors that would otherwise allow undesirable implicit conversion from integer types.
Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>
2017-03-08 15:59:46 -05:00
John Horigan 3c69a2e24d Add agg_renderer_base::fill(color&) method for blending a color. Complements the clear(color&) method, which copies the color.
Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>
2017-03-08 14:59:40 -05:00
John Horigan cb743deb19 Add const qualifier to multiply and divide operators for agg_trans_affine/perspective
Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>
2017-03-08 14:52:10 -05:00
Murai Takashi 58916d4a36 agg_scanline_u.h: fix wrong base_type
As pointed out at https://sourceforge.net/p/agg/svn/37

Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>
2017-03-08 13:26:56 -05:00
Julian Harnath 6ced92452c FUSE compat: add MIME type faking
* Add special handling for reading the BEOS:TYPE attribute to supply
  on-the-fly fake MIME types for FUSE module filesystems, the same
  way it's done in our FAT and NTFS FS modules

* Reuse the mime_ext_table which we already have and put it into a
  shared location so we don't get further extra copies of it
2017-02-27 19:58:22 +00:00
Julian Harnath 1263be8fc4 FUSE compat: add Haiku extension
* Add a way for a FUSE module to supply Haiku-specific extensions.
  This allows it to integrate better with Haiku while only requiring
  minimal changes on the FUSE module itself.

* For now, there is only one extension: another function pointer for
  "get_fs_info", which lets the FUSE module fill in an fs_info struct.
  FUSE provides no good way to otherwise communicate extra information,
  such as the volume flags (e.g. B_FS_IS_SHARED).

* A FUSE module can signal that it supports the Haiku extensions by
    a) defining HAS_HAIKU_FUSE_EXTENSIONS before including the fuse
       headers
    b) setting the global variable gHasHaikuFuseExtensions to 1 in
       its initialization
  Otherwise, the Haiku extensions are completely invisible to the
  FUSE module.
2017-02-27 19:58:13 +00:00
John Scipione 388ac82baa BString: Add IStartsWith() and IEndsWith() methods
Case-insensitive version of StartsWith() and EndsWith()
2017-02-21 18:03:03 -08:00
Jérôme Duval 85566e032d posix: add _POSIX_SEM_NSEMS_MAX.
* have _SC__SEM_NSEMS_MAX return _POSIX_SEM_NSEMS_MAX, a per team limit
instead of the global limit.
2017-02-21 20:17:16 +01:00
Jérôme Duval 0bec83a85a pthread: add const for pthread_mutex*_get*()
according to the spec. Fixes #13324.
* code style clean up.
2017-02-21 20:05:02 +01:00
PulkoMandy 100775b790 Fix build on Linux
Stub out some translation macros for host build, so the now localized
package solver can be built there.
2017-02-11 14:15:38 +01:00
Augustin Cavalier b6f76ebe71 s/OpenBeOS License/MIT License/ universally, as they're the same thing.
Fixes #8681.
2017-02-09 22:09:56 -05:00
Augustin Cavalier 6c9415e3ca BJson: Use the normal "input, output" argument ordering instead of the reverse.
Update all in-tree consumers of the BJson API to match. Also added
const-qualifiers to the BString versions of the API, and added the leading
"_" to the header guards.
2017-02-09 13:43:26 -05:00
Jérôme Duval d0a92cb653 x86: added a MSR definition. 2017-02-01 16:57:03 +01:00
Adrien Destugues f9e1854f19 libbnetapi: fix access to HTTP headers
The asynchronous listener had no reliable way to access HTTP result and
headers from the callbacks. As the callbacks are triggered
asynchronously, they can be run after the request has carried on and,
for example, followed an HTTP redirect, clearing its internal state.

The HeadersReceived callback now passes a reference to BUrlResult for
the request. There are two cases:
- Synchronous listener: passes a reference to the request's results
directly
- Asynchronous listener: archives a copy of the result into the
notification message, and passes a reference to the unarchived copy.

Unfortunately this comes with several ABI and API breakages:
- Change to the prototype of HeadersReceived()
- Change to the class hierarchy of BUrlResult (implements BArchivable)

All users of HTTP requests will need to be updated if they implemented
in HeadersReceived or used BUrlResult.
2017-01-30 20:27:52 +01:00
Kacper Kasper 2332ebfd52 ControlLook: Add side parameter to tab drawing functions.
* This allows drawing tabs on any side of the view.

Signed-off-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2017-01-22 09:36:38 +01:00
Andrew Aldridge a735975461 Sync atheros813x with FreeBSD
Signed-off-by: Adrien Destugues <pulkomandy@pulkomandy.tk>

Fixes #12328.
Fixed a style error (2 lines between functions).
2017-01-22 09:20:01 +01:00
Dario Casalinuovo 991d9dbf6d MediaConnection: Implement auto release 2017-01-18 20:19:02 +01:00
Dario Casalinuovo 0844ddf4d9 MediaClient: Polish destructors
* Make Release() the only public way to destroy a connection.
2017-01-18 20:19:02 +01:00
Dario Casalinuovo d64dd7beea MediaClient: Fix style for private methods and other cleanup
* Cleaned up some unneeded callbacks.
2017-01-18 20:19:02 +01:00
Dario Casalinuovo 7561d9ac5d Populate media/experimental with future media_kit classes
* Node implementations headers are move into src/kits/media.
2017-01-16 23:04:14 +01:00
Dario Casalinuovo 41acdd1d90 media_kit: Move some files and headers under docs/develop/media 2017-01-16 22:53:44 +01:00
Dario Casalinuovo 550e05af20 MediaClient: Start/Stop force argument doesn't make sense 2017-01-15 19:28:14 +01:00
Dario Casalinuovo 2c9fa0f278 MediaClientNode: Schedule outgoing connections on start
* Add preliminary binding support.
2017-01-15 14:45:24 +01:00
John Scipione 3705d40cd9 BSpinner: Set min value then max value
... reverse this to avoid confusion, you'll see why in next commit.

No functional change intended in this commit, functional change is in the
next commit.
2017-01-12 14:15:44 -08:00
Adrien Destugues bdd02e0d9d BString: rename SetCharAt to SetByteAt
Makes it clear that it operates on bytes, not unicode codepoints.
Thanks to mmlr for remembering me of this subtlety.
2017-01-12 22:03:51 +01:00
Jérôme Duval 0c5219a1d6 Restore missing symbol _ZN7BStringixEi on x86 and x86_64.
* Vision and others were broken after 3eac8208df.
* this adds BStringRef in the backward compatibility section.
* fixes #13199.
2017-01-12 21:23:50 +01:00
Adrien Destugues 3eac8208df Remove BStringRef and users.
As discussed in 2008
(http://www.freelists.org/post/haiku-development/BString-on-GCC4,1),
this class was not efficient because of lack of inlining. Implement the
suggested solution of a SetCharAt method instead. Also add a CompareAt
which covers a specific use case in KeyboardLayout.cpp.

Adjust all places which were using this feature to safer APIs.

Also fixes a copypaste error in FormattingConventions.cpp.
2017-01-11 20:50:41 +01:00
Dario Casalinuovo e6004b7729 MediaClient: Move WIP min/max functions into BMediaConnection 2017-01-10 22:54:53 +01:00
Dario Casalinuovo 3ef4b20086 Make BMediaRecorder public
* Fills a functionality lack of the classic media_kit.
2017-01-10 21:34:20 +01:00
John Scipione e1304871bb Revert "BWindow: CenterOnScreen a bit above center"
This reverts commit a5be1832cc.
2017-01-01 12:25:05 -08:00
John Scipione a5be1832cc BWindow: CenterOnScreen a bit above center
BWindow docs: Document changes to CenterOnScreen()

https://68.media.tumblr.com/d8dff7a17b9d90b41e32c5a2a0312513/tumblr_oj2wg1tmKs1r0f0hfo1_1280.png

Will revert if not appreciated.
2016-12-31 18:06:55 -08:00