Commit Graph

21070 Commits

Author SHA1 Message Date
Axel Dörfler
ffdeb47b94 Imported B_NO_POINTER_HISTORY test app from bug #1415, applied our coding
style, cleaned it up, and made it a bit more evident.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22020 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 22:46:34 +00:00
Stephan Aßmus
22f5a4e492 * fixed broken invalidation on resizing the status view
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22019 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 22:23:18 +00:00
Stephan Aßmus
e583bfc206 patch by Andre Garzia:
* reading/writing interface configuration data is now working properly
* at boot, net_server will overwrite the configuration with settings retrieved
  via DHCP, though
* refactoring/renaming

changes by myself:
* fixed warnings and cleaned up in Settings::ReadConfiguration(), when the
  nameservers are parsed
* fixed warning in EthernetSettingsView::_SaveAdaptersConfiguration(), changed
  the loop to do without "isOpen", I think it was broken in two ways before:
  - it would use the fp pointer after closing the file (isOpen was not
  maintained), and if that would have worked, it would have overwritten the
  interface configuration saved in an earlier loop iteration, now it should
  write all interfaces that are not set to autoconfigure


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22018 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 17:40:48 +00:00
François Revol
e8b3a30edb Fix dano build
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22017 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 15:24:54 +00:00
Axel Dörfler
9d22ffbe84 Fixed bug #1413:
* vm_soft_fault() no longer touches the page source cache in case fault_get_page() failed.
* fault_find_page() now unlocks and releases the cache if reading in a page failed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22016 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 14:27:11 +00:00
Axel Dörfler
d0c290bf09 BAppFileInfo would crash if the resources failed to initialize, but SetInfoLocation()
forced it to use them. Now, it will filter out B_USE_RESOURCES when the resources
are invalid.
Also, _WriteData() and _RemoveData() will now fail if neither source is specified
with B_NO_INIT.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22015 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 14:08:51 +00:00
Stefano Ceccherini
1aa5b467f2 Reverted FPS.cpp to previous version, as Michael's request
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22014 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-20 12:07:13 +00:00
Stefano Ceccherini
be98a6028d Some style cleanups by Fredrik Ekdahl. Thanks!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22013 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-19 20:14:48 +00:00
Stefano Ceccherini
0e5fe45f13 Removed unused DataBuffer class
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22012 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-19 19:59:09 +00:00
Ryan Leavengood
d237672a06 A fix to bug #1154 by Justin O'Dell. Basically the settings for menus
default to having no accelerators, but that setting was not ever read
properly. So in fact the meny pref was correct, but the menus were wrong.
This fixes that.

If the default setting is supposed to be accelerators on then the settings
should be changed.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22011 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-19 19:55:26 +00:00
Ryan Leavengood
c18df4b601 Two fixes:
- One from Justin O'Dell which properly enables and disables the play and stop
	buttons.
- One from me which doesn't crash Sounds if you try to open a file which has no
	MIME type set. It previously assumed the super type would always exist.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22010 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-19 05:23:31 +00:00
Michael Lotz
8b39e73209 Print class, subclass and protocol field as hex numbers. This fits general usage and documentation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22009 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-18 18:45:49 +00:00
Michael Lotz
ff9e2d0cf7 Correct printing generic descriptors (the length includes the two other struct fields). Fixed warnings.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22008 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-18 18:39:29 +00:00
Stephan Aßmus
b60056cdb3 patch by Andre Garzia:
* it gets all the configuration and it saves it back but for some reason,
  the net_server is not noticing the changes yet


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22007 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 16:36:13 +00:00
Stephan Aßmus
ae3a7f4dac * don't leak the rect data in case of failed realloc()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22006 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 16:24:43 +00:00
Stephan Aßmus
15a6a1bd6d * more pleasing insets/offsets and the proportion of the zoom button scales
with the font size


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22005 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 16:24:01 +00:00
Axel Dörfler
871d97a9f5 * Fixed the kernel bug that prevented SIGCONT from working properly: the problem
occured if SIGSTOP was already delivered but not yet handled when SIGCONT was
  sent. Now, SIGCONT will clear all stop signals from the pending signals.
* SIGTSTP, SIGTTIN, and SIGTTOU are supposed to suspend the thread as well, adapted
  the default behaviour to respect that.
* Removed the work-around from r21997 TermParse.cpp for this exact problem.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22004 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 13:08:24 +00:00
Stephan Aßmus
f7e1df7560 * get rid of RGBColor usage where it is not needed, this simplified many things,
possibly making them a little faster too
* mess with decorator button size calculation to make the whole layout scale
  more agreeable with the font size (no more fixed offsets/insets), but it
  is work in progress
* DefaultDecorator no longer allocated the border color array, it is part of
  the object now
* small memory footprint optimizations in ViewLayer, Decorator and WindowLayer


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22003 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 12:56:20 +00:00
Ryan Leavengood
5d19a6e65c Fixed some coding style issues.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22002 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 12:13:32 +00:00
Axel Dörfler
3e5ede51ed * Fixed build under Dano
* Some cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22001 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 12:12:46 +00:00
Stephan Aßmus
f591e3a0f2 * fix weird Shape op/point allocation
* handle out of memory situations
* don't try to copy (and assign op!) in SetData if opCount/ptCount is 0
-> FontDemo doesn't crash anymore eventually when cycling fonts in outline
mode


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22000 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 11:17:29 +00:00
Axel Dörfler
a728651f04 Some more work on the signal code:
* get_signal_stack() checked the wrong sig_action field (index is signal-1), also,
  it had an off-by-one error in the stack range check.
* factored out a restart_syscall() function to avoid code duplication
* arch_setup_signal_frame() relied on the fact that vregs and the signal stack code
  is a multiple of 4 bytes in size.
* Fixed sigaction(): it did return the error code directly instead of setting errno.
* signal() actually had a work-around for the broken sigaction()...
* Replaced the sig_func_t typedef with a sighandler_t typedef - this is non-standard
  anyway, but now we're at least compatible with the GNU world instead of introducing
  our own solution (BSD seems to use sig_t here, BTW).
* Removed now unused sigval structure from the header; it should be added again as
  soon as we start supporting it.
* SA_RESETHAND and SA_ONESHOT are the same thing; the former did not work before.
* Made the non-standard SA_* flags refer to the standard ones instead of the other
  way around.
* Added a test application for various signal features - works fine under Haiku,
  tested also under Linux and BeOS (the latter fails as it does not support SA_RESTART).
  More tests should be added, though.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21999 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 11:01:09 +00:00
Stefano Ceccherini
8906492142 Removed debug leftover
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21998 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 09:57:28 +00:00
Stefano Ceccherini
f3342f281b The Shell destructor was never called. Calling it showed that
the PtyReader thread in TermParse hanged in read(). There's even a 
comment in there (by Axel) that read() is never interrupted. Switched to 
kill_thread() in TermParse::StopPtyReader() until this problem is fixed. 
At least we don't leave running apps around anymore. :)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21997 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 09:54:32 +00:00
Stefano Ceccherini
22e16ac590 call RemoveSelf() on the replicant before deleting them. Fixes bug #1405
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21996 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 08:51:39 +00:00
Michael Pfeiffer
afc8f551f8 Bug in app_server prevents text drawing inside clipping region.
Don't constrain clipping region until bug has been fixed.
Printing to Preview printer driver works now again from StyledEdit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21995 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 08:33:38 +00:00
Michael Pfeiffer
4b05331d1b Added more tests.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21994 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 07:14:15 +00:00
Michael Pfeiffer
1623ec9289 Bug fixes:
* origin is given in "outer" coordinate system therefore if there is a
 previous state it has to be transformed. Please review if this is
 required in OffsetOrigin() too.
* in Transform() we have to scale relative to the view origin not (0 /
  0).

- optimized SetScale: saved one division


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21993 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 07:04:46 +00:00
Ryan Leavengood
3f64fbd011 Committing patch by Justin O'Dell to fix the Defaults buttons on several
preferences apps. This fixes most of bug #254.

This is his first contribution to Haiku, and hopefully the first of many.

Thanks Justin!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21992 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-17 03:45:37 +00:00
Axel Dörfler
9d6482b1fd The vlance driver is apparently broken, and call acquire_sem() from an interrupt routine.
Therefore, I've removed it from the image for now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21991 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 21:37:33 +00:00
Jérôme Duval
2272b5dbbd actually don't send B_SILENT_RELAUNCH for any message in the initial message list
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21990 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 19:03:45 +00:00
Axel Dörfler
0b70ea5992 * Implemented sigaltstack() and set_signal_stack(), thus closing bug #1401.
* On exec() the new function thread_reset_for_exec() is called which clears the signals
  and cancels an eventually set alarm. Both things weren't done before...
* Some minor cleanups.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21989 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 18:01:47 +00:00
Axel Dörfler
f2286d02b9 Reverted back to an older random version that did not yet use thread_yield().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21988 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 18:01:21 +00:00
Jérôme Duval
a3192bf3a7 Tracker seems to launch applications with a B_REFS_RECEIVED message in the initial message list.
Now checks if such a message is present and avoids sending B_SILENT_RELAUNCH in this case, and also in the standard case with a ref.
This fixes bug #1387


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21987 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 17:36:58 +00:00
Axel Dörfler
f1cea0512b Cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21986 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 17:05:14 +00:00
Stefano Ceccherini
8b63673c13 Also use _GetPreferredFonts() in the other place when we read the fonts
from the preferences


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21985 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 15:36:42 +00:00
Stefano Ceccherini
e7f9f277ef Use a try { } catch block in TermWindow::_AddTab(). Note that this
doesn't fix bug #1392, since TermView::_InitObject() use std::nothrow 
for allocations. Added TermWindow::_GetPreferredFonts() and moved some 
code in there.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21984 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 15:32:09 +00:00
Axel Dörfler
a2e2784cf3 * arch_restore_signal_frame() accessed user memory unsafely; it now also copies the (pretty
large) vregs structure to the stack.
* Introduced a get_signal_stack() function that arch_setup_signal_frame() now uses to setup
  the signal frame - it currently only returns the default user thread stack. Also made
  sure arch_setup_signal_frame() is independent from the user stack.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21983 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 15:11:58 +00:00
Stefano Ceccherini
422fadc829 Moved the dummy table local to the PicturePlayer::Play() function since,
as Marcus pointed out, having it outside wasn't thread safe. Moved 
PicturePlayer into the BPrivate namespace.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21982 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 14:40:03 +00:00
Stefano Ceccherini
0f8ae3ead7 Creating a new tab made the app crash since r21979. Use "Terminal" as
tab label instead of "scrollView". Setting Terminal to fullscreen also 
resizes and moves the TermView a bit.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21981 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 14:17:19 +00:00
Stefano Ceccherini
b438035431 Removed leak
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21980 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 13:17:00 +00:00
Stefano Ceccherini
bb4632f1ec Stolen Ingo's Arguments class from Miniterminal and used it in place of
GPL'd code in TermApp (slightly modified, and bugfixed, even :P).
TermView now accepts an argument vector instead of a commandline. Same 
thing for Shell.
Temporarily(?) removed some commandline options.
This also fixes bug #1396 (tested)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21979 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 13:11:00 +00:00
Michael Pfeiffer
c9c4a80aaa Added testSetOriginAndScale as a use case for a rendering bug.
It seems scaling ignores the origin.
The test does not fail, but the rendered image is wrong.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21978 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 11:49:37 +00:00
Jérôme Duval
9f22373bd3 fix gcc4 build
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21977 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 10:56:45 +00:00
Axel Dörfler
491e46858b Shouldn't code before breakfast:
* check against sizeof(void*)-1 instead of hardcoded 3.
* return B_NO_MEMORY instead of NULL if the allocation failed...
Thanks to Marcus and Ingo for proofreading :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21976 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 10:49:19 +00:00
Axel Dörfler
dfd5242e7f Even though Korli beat me, I've updated the posix_memalign() function to be more standards
compliant:
* it now checks the alignment is a multiple of 4 (needs to be changed for 64 bit architectures)
* it no longer sets errno.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21975 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 10:04:44 +00:00
Jérôme Duval
bf7beb500c added posix_memalign()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21974 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 09:19:56 +00:00
Stefano Ceccherini
bd14785126 Debug was enabled by default.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21973 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 09:14:50 +00:00
Stefano Ceccherini
46b4e48998 Added some debug output to PicturePlayer. Since checking the table size for every op is very slow, now we do that only at the beginning, and use a custom op table if needed. The best case (which is the one used when drawing a picture with BView::DrawPicture()) is very fast since it only requires one check.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21972 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-16 09:14:03 +00:00
Axel Dörfler
066a557444 * vm_soft_fault() no longer sets all pages it touches to "active"; instead, it now honours
if the page was already in the "modified" list before. Also, the source page (which is
  either mapped directly or copied to the target page) is no longer marked busy before its
  final destiny is decided (it didn't have any effect, anyway, since we had its cache
  locked for the whole time, but it now preserves the modified state). This fixes bug #1369.
* vm_cache_write_modified() now filters out temporary caches (it's currently called on area
  deletion).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21971 a95241bf-73f2-0310-859d-f6bbb57e9c96
2007-08-15 23:11:15 +00:00