Commit Graph

113 Commits

Author SHA1 Message Date
Fredrik Modeen
eb47b26534 Added Todo from #575 and fixed some code guidelines issues.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32601 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-22 13:40:24 +00:00
Axel Dörfler
acc71e7c7c * The feel of a BWindowScreen should actually be kWindowScreenFeel. This makes
the Deskbar behave, and not appear in front of those. However, if auto-raise
  is turned on, the mouse cursor is shown, so it seems to get activated anyway.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32535 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-20 09:02:55 +00:00
Stefano Ceccherini
b4510aa10c Reset the colors before switching the screen mode
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32365 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-14 15:32:45 +00:00
Stefano Ceccherini
08c4703712 Move HideCursor() fom Show() to _Activate(), so it gets called also on workspace change.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32300 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-13 10:29:11 +00:00
Stefano Ceccherini
9620428fdf This part wasn't meant to be committed
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32262 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-11 19:02:30 +00:00
Stefano Ceccherini
c7f89a129d Handle workspace changes gracefully, without crashing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32261 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-11 19:00:00 +00:00
Stefano Ceccherini
bfb5eef88f When setting the palette, the passed array is 0 based, even if the first
index is not 0. Bruno, can you check if this fixes SoundPlay's colors?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32241 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-11 04:47:39 +00:00
Stefano Ceccherini
d0c308a5b6 Accidentally enabled tracing
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32148 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-05 21:31:17 +00:00
Stefano Ceccherini
9a95658ce0 Some cleanups. Shouldn't include any functional changes, except maybe
better cleanup on exiting.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32147 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-05 21:30:39 +00:00
Oliver Tappe
16d5c24e53 * merged 32bit-wchar_t branches of buildtools and haiku back into
the respective trunk

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31443 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-07 10:30:09 +00:00
Stephan Aßmus
914fb50397 * Added a couple TODOs after reading a bit in the source.
* Introduced a lock in GetDefaultDevice() and ReleaseDevice() as a quick
  solution to the race condition in those functions. It could also use
  proper atomic ref counting. Untested.
* Automatic white space cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31060 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-15 15:15:32 +00:00
Stephan Aßmus
3d198cd3ae Do no export unsupported accelerant hooks. Hopefully fixes #3088.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28562 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-11-08 13:15:02 +00:00
Axel Dörfler
33309cb5fc * BWindowScreen::_InitClone() was broken, it called the "get clone info" method
on uninitialized accelerant, but that's what AS_GET_DRIVER_PATH is for.
* This should fix #2847.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28534 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-11-06 12:44:26 +00:00
David McPaul
da9b0b46ed split or combine decoder buffers to match mixer buffer size.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28414 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-31 22:34:56 +00:00
David McPaul
45d40b75b9 uint8 Fillbuffer should use sizeof(uint8) for divisor
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28380 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-30 12:00:57 +00:00
David McPaul
d0b2b559f5 match default buffer size to Mixer default
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28379 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-30 11:59:14 +00:00
David McPaul
593356d280 correct spelling error
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28378 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-30 11:57:43 +00:00
Maurice Kalinowski
3feea27945 whitespace and style cleanup, no functional changes
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28358 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-10-28 19:54:43 +00:00
Stefano Ceccherini
e7d2f0f0e8 fix the problem reported in the TODO by using a reference to pointer
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27724 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-25 06:12:02 +00:00
Stefano Ceccherini
727834785d Added a TODO explaining why BGameSoundDevice::Buffer() is broken. Small style changes
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27720 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-24 12:55:25 +00:00
Stefano Ceccherini
250505c99b more small style changes
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27708 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 15:38:32 +00:00
Stefano Ceccherini
92ed85c9ec use nothrow for allocation
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27707 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 12:41:42 +00:00
Stefano Ceccherini
671fe092d3 Added missing break(s) in switch block in GameSoundBuffer::GetAttributes(). Added missing default case. Avoid double calculation of buffer size
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27706 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 12:28:18 +00:00
Stefano Ceccherini
3beb2f72d7 style changes. Also added a TODO taken from a comment in bug #575
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27705 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 11:02:58 +00:00
Stefano Ceccherini
0e79ce1ebc Style changes. don't use new to allocate a 2-sized buffer, but use the stack
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27704 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 10:43:02 +00:00
Stefano Ceccherini
2d4df7f2fc CID 80. err was checked twice for the same value. Also add more error checks
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27701 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-23 08:33:09 +00:00
Stefano Ceccherini
b56c51bcba set fPanRamp and fGainRamp to NULL after deleting them, otherwise they could be double-freed. Also dont' check for NULL before calling delete. CID 1230 and 1231
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27511 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-15 07:17:27 +00:00
Stefano Ceccherini
746cac055a fixed buffer overrun, CID 649
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27446 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-12 10:10:13 +00:00
Jérôme Duval
fc1ca2da5c style cleanup
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25177 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-26 12:16:53 +00:00
Axel Dörfler
cfc3fa87da * Cleaned up InterfaceDefs.h, added TODO about getting rid of declaring
_init_interface_kit_() in there.
* Moved private get_mode_parameter() into the BPrivate namespace.
* Renamed interface_misc.h to InterfacePrivate.h.
* Minor other cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24869 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-04-09 10:07:35 +00:00
Stefano Ceccherini
28fa064595 Added more conditional debug output, taken from the dw_info test app.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23730 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-01-25 11:54:35 +00:00
Stefano Ceccherini
020cbad9d4 delete the semaphore instead of releasing it, otherwise
DirectConnected() could be called twice with B_DIRECT_STOP when closing 
the BDirectWindow.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23718 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-01-24 13:43:34 +00:00
Ingo Weinhold
6e927a5fc0 malloc.h ain't no standard header. Use stdlib.h instead.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22776 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-10-30 17:32:27 +00:00
Stefano Ceccherini
d9cebac2b7 Rewrote DirectWindow.h, updated DirectWindow.cpp accordingly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22659 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-10-22 10:29:44 +00:00
Stephan Aßmus
ed2254308b * just realized a bug already when reading over the commit log...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21666 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-07-19 17:16:54 +00:00
Stephan Aßmus
582da17386 * complete reimplementation of BRegion and it's backend
I "ported" the region implementation from XOrg to work on BRegion data.

This resulted in pretty much the same code structure as before, with 
RegionSupport.cpp containing the messy details. Only now it _is_ really messy
from a code beauty point of view. I didn't exactly feel like cleaning it
up right now... but I guess I will have to.

So what does this mean - our BRegion implementation was very slow (no offense!),
and on top of that it scaled very badly with more and more rects. The new
implementation seems to be on par with the very fast R5 implementation and
the data looks exactly the same too. BRegion is very performance critical
for the app_server, and I cannot wait to try this on my slow computer...

Some changes are noteworthy: The right and bottom coordinates of
BRegion internal data are now exclusive! I inherited that from the
XOrg implementation and didn't feel like changing the code, seeing it
is probably tested quite well. The conversion is handled transparently.

Secondly, constructing a BRegion with just one rect is not invoking
malloc anymore for the member data, this makes it much more efficient
to use temporary BRegions with just one rect, both externally and internally
in the BRegion implementation.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21665 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-07-19 17:06:28 +00:00
Stefano Ceccherini
80d75f15df Fixed problems with try/catch, hopefully. Thanks Axel for pointing them
out.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21486 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-21 20:25:08 +00:00
Stefano Ceccherini
ffcd67bc82 moved duplicate code to a common location.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21459 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-18 14:30:56 +00:00
Stefano Ceccherini
a24a5156f9 splitted SetActiveState() into 2 methods, since it was very messy
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21454 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-18 13:15:58 +00:00
Stefano Ceccherini
99851ad6db free() the modelist as it's allocated using malloc. A forgotten printf -> fprintf. minor other stuff.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21452 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-18 12:44:58 +00:00
Stefano Ceccherini
6a45488dd9 Used exceptions to handle errors on InitData(). I hope I didn't made
stupid errors, since I don't use exceptions usually. Feel free to beat 
me on this. Moved uninitialization to _DisposeData(). Corrected some 
styling issues pointed out by axel. Used fprintf instead of printf.
Turned off debugging.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21450 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-18 09:53:36 +00:00
Stefano Ceccherini
f09ba8ea46 Call get_clone_info and get_clone_info_size instead of using the
driver's path. More correct. Now we could remove the app_server's 
command to retrieve the driver's path.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21408 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-06-14 10:25:14 +00:00
Jérôme Duval
14e3d1b576 don't try to stop a non inited BFileGameSound
now stops BFileGameSound at the end of the track if not looping
GameSoundDevice now checks the sound_id is valid
added a header include in GSUtility.h 


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21221 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-05-23 19:40:57 +00:00
Stefano Ceccherini
652f187eee finally fixed debug output
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21061 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-05-07 20:49:58 +00:00
Stefano Ceccherini
1560418a27 forgot the \n
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21036 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-05-05 20:41:39 +00:00
Stefano Ceccherini
5115ca0858 Added optional debug output
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21035 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-05-05 20:03:31 +00:00
Jérôme Duval
ea4f253fd6 update license headers, code style
In BPushGameSound, SetParameter and SetStreamHook return B_UNSUPPORTED while Perform calls the parent class.
Moved code to the constructor.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20682 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-14 13:35:39 +00:00
Jérôme Duval
effe53fae9 fixed the wrong test for real
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20671 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-12 20:32:19 +00:00
Jérôme Duval
c7509fce9d improve codestyle
fix bad init in BPushGameSound


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20670 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-12 19:20:45 +00:00
Jérôme Duval
0c93c0a807 change the way FileGameSound works : avoid using a port
code style, some clean up


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20603 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-04-06 22:40:23 +00:00