this (seems to be what R5 BStatusBar does):
* combine the "trailing text" with the "trailing label" and truncate the
resulting string on the left side according to the width of the entire
control
* combine the "label" with the "text" and truncate that on the right side
according to the space left by the right hand text.
-> No more overlaps (theoretically, in practise there are still overlaps
because our BFont::TruncateString() does not respect the width in some
situations.)
* Changed _SetTextData() accordingly, it is not used anymore for the
label and trailing label, and could therefor be simplified a little.
* fixed _BarFrame() to not return fractional coords, which could sometimes
leave a dirty line of pixels.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25244 a95241bf-73f2-0310-859d-f6bbb57e9c96
* cache paranoia was always enabled.
* Changed from paranoia on/off to levels. Adjusted the macros to take a
level argument.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25215 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added "mode" parameter to set_paranoia_check(), which specifies
whether the check is supposed to already exist/not exist yet. This
allows for, as it turns out, very useful additional tests. Added
{ADD,UPDATE}_PARANOIA_CHECK macros that imply the used "mode"
parameter.
* PARANOIA_SLOT_COUNT was accidentally redefined in the source file.
* Fixed remove_paranoia_check(). It didn't remove anything.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25207 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added capture_tracing_stack_trace() which allocates space in the
tracing buffer and captures the stack trace according to the given
parameters.
* Added TraceOutput::PrintStackTrace() to print a stack trace thus
created.
* Added TraceEntry::DumpStackTrace() callback which is supposed to print
a stack trace for the entry, if it can do that.
* Added "--stacktrace" switch to the "traced" command, which causes the
stack traces for all entries that have one to be printed as well.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25205 a95241bf-73f2-0310-859d-f6bbb57e9c96
- use the dano version by default
- s/ddraquire/ddaquire/
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25203 a95241bf-73f2-0310-859d-f6bbb57e9c96
- the dano version is exposed as v1.1 so drivers can use select with a simple ifdef
- add copyrights from the tty driver as I'll be copying code from it.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25201 a95241bf-73f2-0310-859d-f6bbb57e9c96
or connect() that passed sizeof(sockaddr_un) would always fail.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25138 a95241bf-73f2-0310-859d-f6bbb57e9c96
unlockpt(), which provide a portable way of opening a pty.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25134 a95241bf-73f2-0310-859d-f6bbb57e9c96
again.
* Publish /dev/ptmx. Opening it will open a fresh pty master. In
principle /dev/pt/ is obsolete now, but I guess we keep it around for
compatibility with BeOS. Though there shouldn't be many applications
opening a pty, that we might be interested in...
* New ioctls B_IOCTL_GET_TTY_INDEX (returns the tty index) and
B_IOCTL_GRANT_TTY (grants tty slave access rights).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25133 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added support for non-published condition variables. One has to call
Init() on those, and add entries directly with the
ConditionVariable::Add() method.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25110 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Made the object pointer passed to thread_prepare_to_block() const, so
that strings can be passed without casting. Passing a string could
maybe be made a convention for THREAD_BLOCK_TYPE_OTHER.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25109 a95241bf-73f2-0310-859d-f6bbb57e9c96
respective Private* base class.
* Changed sigwait() and sigsuspend() to use thread_block() instead of a
condition variable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25100 a95241bf-73f2-0310-859d-f6bbb57e9c96
thread_block(), thread_unblock(),...) that allow a thread to wait for
something without needing a semaphore or condition variable. It can
simply block and another thread can unblock it. Supports timeouts and
interrupting. Both semaphores and condition variables use this
common mechanism, now.
* Semaphores:
- Some simplifications due to the thread blocking mechanism.
- Changed locking order to sem -> thread. It was the other way around
before and when introducing the wait_for_objects() support I had
also introduced a situation where the locking was reverse, which
could potentially cause a dead lock on SMP systems.
- Instead of queueing thread structures, a semaphore queues
queued_thread entries now, which are created on the stack. The
thread::sem structure could thus be removed.
- Added sem_entry::net_count, which is sem_entry::count plus the
acquisition count of all waiting threads. This number is needed in
remove_thread_from_sem() and instead of computing it there we
maintain it.
- Fixed remove_thread_from_sem(). It would not unblock threads, if
the sem count was <= 0.
- Made sem::last_acquirer unconditional. It is actually needed for
sem_info::latest_holder. Fixed fill_sem_info() accordingly.
- Added some optional tracing output, though only via ktrace_printf().
* Condition variables:
- Could be simplified significantly through the use of the thread
blocking mechanism. Removed a good deal of unnecessary code.
- Moved the ConditionVariableEntry "flags" parameter from Wait() to
Add(), and adjusted all places where condition variables are used
accordingly.
* snooze() uses thread_block_with_timeout() instead of a semaphore.
* Simplified thread interrupting in the signal and user debugger code.
Instead of separate functions for threads waiting on a semaphore or
condititon variable, we only have a single thread_interrupt(), now.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25099 a95241bf-73f2-0310-859d-f6bbb57e9c96
- If the hook of the timer we're cancelling is currently being
executed, we do now wait till it is finished. This is how the BeBook
specifies the function to behave.
- Periodic timers would not be cancelled, if their hook was being
invoked at the same time, since they weren't in the queue during
that time.
- Since we know the CPU on which the timer is scheduled (timer::cpu),
we don't have to look through any other CPU queue to find it.
- Fixed the return value. It should report whether the timer had
already fired, and was not always doing that.
* Added private add_timer() flag B_TIMER_ACQUIRE_THREAD_LOCK. It causes
the thread spinlock to be acquired before the event hook is called.
cancel_timer() doesn't wait for timers with the flag set. Instead we
check in the timer interrupt function after acquiring the thread
spinlock whether the timer was cancelled in the meantime. Calling
cancel_timer() with the thread spinlock being held does thus avoid any
race conditions and won't deadlock, if the event hook needs to acquire
the thread spinlock, too. This feature proves handy for some kernel
internal needs.
* The scheduler uses a B_TIMER_ACQUIRE_THREAD_LOCK timer now and
cancel_timer() instead of the no longer needed
_local_timer_cancel_event().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25098 a95241bf-73f2-0310-859d-f6bbb57e9c96
kernel and added a WrapperTraceFilter* parameter, which allows for
additional filtering. This way other commands can print tracing output
with special filtering.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25094 a95241bf-73f2-0310-859d-f6bbb57e9c96
keyword, so this stupid python should really be fixed instead.
* Enforced the 80 column limit.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25090 a95241bf-73f2-0310-859d-f6bbb57e9c96
variable at once. It wasn't used anymore, and the code gets simpler.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25080 a95241bf-73f2-0310-859d-f6bbb57e9c96
ones) for wait_for_child(), which is notified when any job control
condition (child dead, stopped, continued) occurs. These events are
relatively rare anyway, and it simplifies the code.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25079 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Also removed the header files that belong to those files.
* Only kept the userland_ipc.h header for now, to remember us about the
former userland server driver (that I also removed - it can always be
resurrected from SVN if needed).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25045 a95241bf-73f2-0310-859d-f6bbb57e9c96
<libroot_private.h> to <user_group.h>.
* Added support in the registrar for adding and modifying users.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25040 a95241bf-73f2-0310-859d-f6bbb57e9c96
to port_buffer_size_etc(), but returns the info through a structure,
which also identifies the sender (uid, gid, team ID) of the message.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25003 a95241bf-73f2-0310-859d-f6bbb57e9c96
registrar provides access to the DBs via a port message based
protocol. The functions in libroot just ask the registrar now.
* Added Linuxish shadow passwd support. No putspent() though -- we'll
provide private functions.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25002 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added virtual destructor to BRefFilter in case the GCC version is 3 or newer
(can't do it for GCC 2.95.3, since that would break binary compatibility
AFAIKT)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24986 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Renamed BView::Alignment() to LayoutAlignment() which fixes a ton of warnings
and some conflicts with BControls.
* Added virtual destructor to BRefFilter in case the GCC version is 3 or newer
(can't do it for GCC 2.95.3, since that would break binary compatibility
AFAIKT)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24983 a95241bf-73f2-0310-859d-f6bbb57e9c96
- Updated code so Processor IDs for older processor do not have to be
modified.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24979 a95241bf-73f2-0310-859d-f6bbb57e9c96
and defines the macros needed by them.
* Renamed syscall sys_vm_map_file() to _kern_map_file() and changed the
path to an FD parameter. Changed vm_map_file() accordingly and
adjusted the kernel ELF loader and the runtime loader.
* Added syscall _kern_unmap_memory().
* Added bool unmapAddressRange parameter to vm_create_anonymous_area()
and map_backing_store(). If true and the address specification is
B_EXACT_ADDRESS, all areas in the specified address range will be
deleted (unless an area is covered only partially).
* Introduced B_SHARED_AREA flag, which is set on areas that have been
created by {vm,_user}_map_file() with REGION_NO_PRIVATE_MAP. When
fork()ing those areas won't be copied CoW, but rather be cloned. This
is needed for mmap() MAP_SHARED.
* {vm,_user}_map_file() also accept an FD argument < 0, in which case an
anonymous area is created.
* Implemented mmap() and munmap(). Currently there's the restriction
that we can't partially unmap areas. Otherwise the functions should be
rather compliant. We also support the non-POSIX extension
MAP_ANONYMOUS.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24964 a95241bf-73f2-0310-859d-f6bbb57e9c96
- Updated Intel processor IDs.
- Only take extended family/model into account on Intel processors.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24958 a95241bf-73f2-0310-859d-f6bbb57e9c96