B_QUIT_REQUESTED is no longer forwarded to the application too early.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15271 a95241bf-73f2-0310-859d-f6bbb57e9c96
which supports ReadLockWithTimeout()
* commented the code in many more places
* understood the problem of making the read/write locking
work: While it would be possible for each window to
remove the processed region from the global dirty region
in read lock mode (since it is guaranteed not remove
a region not intersecting with its own visible region),
multiple window threads can still not do this at the same
time, since BRegion itself is not threadsafe of course.
* I need to figure out a way for the window threads to be
able to access and modify all needed data in read only mode,
I think this means to divide the global dirty region into
each window again, so that each window thread can simply
clear its own dirty region instead of excluding it from
the global region. Yeah, that might work.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15230 a95241bf-73f2-0310-859d-f6bbb57e9c96
color. In BeOS, a view gets a MouseMoved() with B_ENTERED_VIEW when the window is
opened under the mouse cursor (not yet in Haiku).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15227 a95241bf-73f2-0310-859d-f6bbb57e9c96
* views are now correctly clipped when they are
(partly) hidden under their parent(s)
* removed fIsTopView, the top view in a window
simply has no parent
* introduced WindowLayer::CopyContents() which
blits part of the contents to another location,
while moving that part in the dirty regions. Since
this is currently used from the Desktop thread,
messing with the update session dirty regions
requires now to lock the clipping
* that feature is now used for blitting a view to its
new location in ViewLayer::MoveBy(), which
works for right and/or bottom aligned views just fine
* I left the global dirty region in Desktop for now,
moving it into each WindowLayer gave quite a slowdown
and caused all kinds of other problems.
* a view is now cleared to the background color right
before the first drawing command from the client
is executed for that view, this reduces flickering
a lot because the content is drawn much more shortly
after the background is cleared.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15201 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Introduced WindowLayer::Hide/Show/IsHidden()
* Made ViewLayer::IsHidden() more robust.
* Same with ::TopLayer()
* modified a little ViewLayer::MoveBy() - prepared it to work with
hidden/shown code that will come soon; only calculate dirty regions if a
ViewLayer has a parent, otherwise the move action is pointless.
* Did the same thing with ::MoveBy() except for the parent stuff - no need
for a parent on resizing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15193 a95241bf-73f2-0310-859d-f6bbb57e9c96
* adds concept of a current and a pending update session
* marks dirty views being resized or moved
Some aspects of the design are buggy, others are slow, but I'm
approaching a good overview of what's needed and what problems
lurk in the details. In the end I hope to make things work fast
and correctly at all times. Adi or anybody else, feel free to
join the efforts.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15158 a95241bf-73f2-0310-859d-f6bbb57e9c96
an app_server code. It's always up-to-date as it just reads the header
directly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15148 a95241bf-73f2-0310-859d-f6bbb57e9c96
* now with actual view layers inside the windows
* implemented the resize modes (from Adis code)
* windows have resize handles and more correctly
clip the views inside
* bringing windows to front or sending them behind all others
* one active window, the others are inactive
* with and without focus follows mouse mode
* bugs:
- the region marked dirty when views are
resized is not correct yet
* todo:
- move the dirty region from being managed by the
desktop to being managed in each window (and being
local too)
- scrolling
- hiding/showing of windows and views
I plan to extend this to fully simulate asynchronous
drawing from clients, to see any problems before
using this in the real server one day.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15132 a95241bf-73f2-0310-859d-f6bbb57e9c96
Note, I temporarily kept the Utils.h in, because I have other local changes to be
committed soon (sorry for this, but it shouldn't harm).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15043 a95241bf-73f2-0310-859d-f6bbb57e9c96
distribute any messages to the clients yet.
* removed the working thread from RootLayer - for now, its event handlers are
still called using input filters in the new event dispatcher, though (to
get things started).
* ServerApp is now using a BMessenger to identify its client, and no longer
stores the port/token separately.
* the input_server handshake is a bit simpler now, as it can now just reply
to the app_server message, removed unused code from ServerProtocol.h
* calmed down the MultiLocker (it always printed thread statistics on startup,
because it's compiled in debug mode).
* removed the cursor thread stuff from AppServer.cpp
* the new event dispatcher now uses a cursor thread when supported (only in
native mode, not in the test environment), although it improves cursor
movement under Qemu, the effect is not as good as expected - this might
need some more investigations (might just be a thread priority problem).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15012 a95241bf-73f2-0310-859d-f6bbb57e9c96
Notice the doubled key events in case the upper right BTextControl with
B_KEYBOARD_EVENTS has focus in BeOS...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14982 a95241bf-73f2-0310-859d-f6bbb57e9c96
have different token spaces depending on the scope of its objects.
* removed TokenHandler - we're now using BTokenSpace instead.
* removed unused IPoint.cpp - if we ever need it again, it can still easily be
resurrected from the dead.
* some cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14925 a95241bf-73f2-0310-859d-f6bbb57e9c96
environment where I wrote our setjmp() in does work perfectly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14897 a95241bf-73f2-0310-859d-f6bbb57e9c96
* no more libappserver.so - this breaks the "Appearance" application, but that
has to be fixed some day later.
* the drawing stuff is now built in its own directory as libasdrawing.a.
* TEST_MODE defaults to "0" if not defined yet - it's overridden in the test
build now, not in the main build.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14896 a95241bf-73f2-0310-859d-f6bbb57e9c96
categories:
* Missing includes (like <stdlib.h> and <string.h>).
* Linking against $(TARGET_LIBSTDC++) instead of libstdc++.r4.so.
* Local variables shadowing parameters.
* Default parameters in function definitions (as opposed to function
declarations).
* All C++ stuff (nothrow, map, set, vector, min, max,...) must be imported
explicitly from the std:: namespace now.
* "new (sometype)[...]" must read "new sometype[...]", even if sometype is
something like "const char *".
* __FUNCTION__ is no longer a string literal (but a string expression), i.e.
'printf(__FUNCTION__ ": ...\n")' is invalid code.
* A type cast results in a non-lvalue. E.g. "(char *)buffer += bytes"
is an invalid expression.
* "friend class SomeClass" only works when SomeClass is known before.
Otherwise the an inner class with that name is considered as friend.
gcc 4 is much pickier about scopes.
* gcc 4 is generally stricter with respect to type conversions in C.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14878 a95241bf-73f2-0310-859d-f6bbb57e9c96
against libroot.so.
* libtracker.so is now also built for that one, and also removed libroot.so linking.
* MiniTerminal is no longer build for the libbe_test platform.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14854 a95241bf-73f2-0310-859d-f6bbb57e9c96
a few whether they actually work.
New pseudo target "unittests", which builds all unit tests for the currently
set TARGET_PLATFORM. They are placed in generated/tests/<platform>/unittests.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14791 a95241bf-73f2-0310-859d-f6bbb57e9c96
updates.
* Optimized retrieving the font list from the server.
* This greatly simplifies the app_server communication for getting the font
list as well - there are now only 2 commands instead of 6.
* Moved extra font flags creation from ServerApp to FontStyle::Flags().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14751 a95241bf-73f2-0310-859d-f6bbb57e9c96
Library names are now mapped for all targets but "host" (not only for
"haiku") -- added one more level of indirection to achieve that.
(TARGET_LIBRARY_NAME_MAP -> *_LIBRARY_NAME_MAP_*).
* Renamed build/HaikuBuildCompatibility.h to BeOSBuildCompatibility.h
(auto-included when compiling something that uses the Be API for platform
"host" on anon-BeOS platform), and introduced build/HaikuBuildCompatibility.h,
which can be included when compiling something that can be built for both,
Haiku and BeOS compatible platforms.
* Introduced libhaikucompat.a, a library that adds a few functions existing
under Haiku, but not under BeOS.
* New rule AddSubDirSupportedPlatforms.
* Renamed libopenbeos.so to libbe_haiku.so.
* Introduced new target platform "libbe_test", which is basically equivalent
to a BeOS compatible host platform target, with the exception, that instead
of the host platform's libbe.so a special build of Haiku's libbe.so
(libbe_haiku.so (formerly known as libopenbeos.so)) is used. Furthermore
Haiku's public app, interface, storage, and support kit headers are used
when compiling. This replaces the less nice way in which the test app server
and applications for this test environment were built.
When building for platform "libbe_test", the library name "be" is
autotranslated to "libbe_haiku.so". Thus most applications don't need
special fiddling when them building them for the app server test environment;
usually an "AddSubDirSupportedPlatforms libbe_test ;" will suffice.
* Reduced the dependencies of <syscalls.h> and fixed problems caused by this
(e.g. source files not including the needed headers directly).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14749 a95241bf-73f2-0310-859d-f6bbb57e9c96
Removed that ambiguous second copy constructor and moved push state functionality
into a separate PushState() method.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14679 a95241bf-73f2-0310-859d-f6bbb57e9c96
Added a small test application for view states. Right now, it only tests scaling - which
doesn't seem to work yet at all.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14673 a95241bf-73f2-0310-859d-f6bbb57e9c96
It doesn't build though, as SimpleTest doesn't seem to work anymore.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14644 a95241bf-73f2-0310-859d-f6bbb57e9c96
"*** remove ..." error messages when initializing a BFS image via the bfs_shell.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14591 a95241bf-73f2-0310-859d-f6bbb57e9c96
The last log entry was never added to the list (if there were more than one), and
thus, it's blocks were never unlocked nor written back (after some minutes of
makehdimage an empty image would greet you).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14427 a95241bf-73f2-0310-859d-f6bbb57e9c96
though, so it's not really ready to be used in a real file system.
Found an off-by-one/some error in Be's BFS implementation: it doesn't use the log
array to its full extent.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14423 a95241bf-73f2-0310-859d-f6bbb57e9c96
- removed profiles, ppp_up, and some TODOs
- simplified KPPPReportManager and reports API, KPPPInterface::Up()+Down(), and PPPInterfaceListener (also removed some features from the last one)
- KPPPInterface now sends the last PPP_CONNECTION_REPORT message to every newly registered report receiver
- added net_server to the build, but removed old net_server testing-stuff
all changes are completely untested
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14338 a95241bf-73f2-0310-859d-f6bbb57e9c96
in read-only mode, but only wrote to it (which erroneously worked before that change).
Only a white screen appeared, no prompt, nothing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13918 a95241bf-73f2-0310-859d-f6bbb57e9c96
For a comparison see: http://haiku.mlotz.ch/messagespeed.html
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13912 a95241bf-73f2-0310-859d-f6bbb57e9c96
Added libmessagetest.so to test specifically the BMessage implementation.
Fixing some other unit tests along the way - quite many of them are borken.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13911 a95241bf-73f2-0310-859d-f6bbb57e9c96
src/tests/servers/app/Jamfile. This makes the original Jamfile much cleaner.
Note that you now have to maintain two Jamfiles when adding/removing sources.
The test app server is called haiku_app_server, its library
libhaikuappserver.so. I adjusted a few paths in scripts accordingly, but
I may have missed something elsewhere.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13858 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Moved setting the default cursor from ServerScreen to Desktop
* Getting the default cursor is now done using the CursorManager
* Removed outdated setcursor from SysCursor.cpp (we have a new implementation by now)
* Renamed SysCursor.cpp to CursorSet.cpp as that's what it is
* Moved headers/private/app/SysCursor.h to headers/private/servers/app/CursorSet.h
* Removed some unneeded header includes along the way
There remains {set|get}_syscursor now in CursorSet.cpp. Serverside for these are not implemented
and they are obvious hacks. Do we need to keep them?
Also this commit _would_ break Appearance, but 1) all the related code is currently commented out
with the comment "cursor set management belongs in another app" and 2) it is already broken
because of ColorSet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13726 a95241bf-73f2-0310-859d-f6bbb57e9c96
specified via options -l and -s. An arbitrary program can be run in the
terminal instead of a shell.
* Console::fState was never initialized which could cause the terminal to
not print anything.
* stdin, -out, and -err were set in MiniView::Start() and in
MiniView::ExecuteShell(). Thus resetting them in the latter method after
executing the shell had no effect. Removed it in the former method and
now reset them after loading, but before resuming the shell.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13676 a95241bf-73f2-0310-859d-f6bbb57e9c96
user_shutdown_reply reliably crashes the app server when pressing one
of its buttons (during the shutdown process at least).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13540 a95241bf-73f2-0310-859d-f6bbb57e9c96
the registrar no longer depends on the app_server to be running.
Added a "run_haiku_registrar" tool that is now used in the various "run" scripts.
It only start the registrar on demand, ie. if it's not yet running.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13493 a95241bf-73f2-0310-859d-f6bbb57e9c96
the super block was written back. This had a big race condition when all
blocks in the transaction were written back before the super block was
written. In that case, the log info part of the super block got out of
sync and was plain wrong (eventually causing the disk to be unmountable).
Also moved the list code over to the kernel's DoublyLinkedList.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13366 a95241bf-73f2-0310-859d-f6bbb57e9c96
Seems like Be's slider doesn't work that well for B_VERTICAL orientation either.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13341 a95241bf-73f2-0310-859d-f6bbb57e9c96
did not work anymore, and thus, the safemode with the current Bootscript
did not work.
It now does again.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13192 a95241bf-73f2-0310-859d-f6bbb57e9c96
to LinkReceiver, LinkMsgSender to LinkSender, and put everything into the
BPrivate namespace.
Made AppServerLink a cheap object - it will use the applications receiver/sender
and not create its own buffers.
Fixed broken communication stuff here and there (mostly Font.cpp).
Put the newly introduced set|get_system_colors() into the BPrivate namespace -
please don't introduce private functions into the public namespace!!!
Also fixed their broken communication use, as Darkwyrm obviously forgot about
it again: the sequence Flush(); GetNextMessage() without error checking is
purely wrong and can make the app hang and/or crash! :-)
Other minor cleanup.
The input_server used some test mode with the haiku build target which is
probably wrong.
Hopefully I did not forget anything this time.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13128 a95241bf-73f2-0310-859d-f6bbb57e9c96
Added LinkMsgReader::NeedsReply() method.
Completely redone ServerApp messaging: no more "replyport" from BAppServerLink; instead,
the registered client reply port is used. Fixed some more weak messaging stuff.
ServerApp now recognizes if an unknown message needs a reply, and sends it - for example,
the "Screen" preferences app no longer hangs, but crashes on start :)
Made LinkMsgReader::Read() virtual again, since it's needed by RAMLinkMsgReader.cpp.
Renamed BPortLink::GetNextReply() to GetNextMessage().
Some more cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13004 a95241bf-73f2-0310-859d-f6bbb57e9c96
Extended the PortLinkTest application a bit (and updated it).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13003 a95241bf-73f2-0310-859d-f6bbb57e9c96
- by holding the secondary mouse button pressed one can draw random lines
so you can see what regions are invalidated durring a move, resize or
scroll operation
- clicking the third mouse button issues a redraw, WITHOUT a region
rebuild action (this is to force a redraw because the window does not
redraw itself, I've been lazy :-)
- playing with the mouse wheel results in the layer under mouse cursor
being scrolled on the y-axis.
- fixed redraw and copyRegion of this sandbox app. They work correctly
now.
- TODO: fix a clipping bug which appears when moving a layer arround.
--This line, and those below, will be ignored--
M newClipping/MyView.cpp
M newClipping/main.cpp
M newClipping/MyView.h
M newClipping/Layer.cpp
M newClipping/Clipping.proj
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12895 a95241bf-73f2-0310-859d-f6bbb57e9c96
a node was not always correctly determined (or set) - the recent change
of the attribute (directory) modes made these bugs a bit more obtrusive.
This also fixes a drop to the kernel debugger when doing a
"zip -r config.zip config/" in the home directory, as reported by Korli.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12826 a95241bf-73f2-0310-859d-f6bbb57e9c96
* further optimized clipping
* implemented support for B_FULL_UPDATE_ON_RESIZE flag
* added support for hidden layers
* implemented Show()/Hide()
* implemented Invalidate(region)
remains to be done:
* fully redraw center and right alligned layers on a resize operation.
* additional testing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12798 a95241bf-73f2-0310-859d-f6bbb57e9c96
attribute directories, and symlinks.
This reduces the space usage of the image created by makehdimage quite
a bit already (dropped from currently 56 MB to 34 MB).
The core of r10356, the fix for the preallocation memory leak, however,
has not been backported (it would probably save another 5 MB on the final
image).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12797 a95241bf-73f2-0310-859d-f6bbb57e9c96
the S_IFREG flag. The missing flags caused the original BFS to crash
on our files.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12796 a95241bf-73f2-0310-859d-f6bbb57e9c96
for the default button does), but at least, the window itself is updated now :-)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12739 a95241bf-73f2-0310-859d-f6bbb57e9c96
Looks like that, when called with "true" as third parameter,
it "eats" all the input messages like B_MOUSE_UP/B_MOUSE_MOVED. That means our implementation isn't correct.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12699 a95241bf-73f2-0310-859d-f6bbb57e9c96
Can also be run under R5 when TARGET_PLATFORM=r5 for comparison.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12567 a95241bf-73f2-0310-859d-f6bbb57e9c96
If anything is still broken (and was not before :)), please shout.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12361 a95241bf-73f2-0310-859d-f6bbb57e9c96
"consoled" now uses this information to tell the TTY its size.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12355 a95241bf-73f2-0310-859d-f6bbb57e9c96
to compile our libbe.so with RUN_WIHTOUT_APP_SERVER for the image.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12190 a95241bf-73f2-0310-859d-f6bbb57e9c96
with coordinates specified as arguments, but this somehow
(and why ever) does hinder /bin/sh from execution (under R5
at least). If someone could point me to the problem I'd be greatful.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12105 a95241bf-73f2-0310-859d-f6bbb57e9c96
We use Setenv instead of the native setenv to stay binary compatible with
BeOS, as R5 does not have setenv.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12079 a95241bf-73f2-0310-859d-f6bbb57e9c96
This doesn't work under Haiku yet though.
Also made the thread functions into members of MiniView so that we
can have correct private members.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12078 a95241bf-73f2-0310-859d-f6bbb57e9c96
It can be run under R5 and Haiku (binary compatible) and should work
with the Haiku app_server and input_server.
It gives access to a /bin/sh like a normal terminal, but has no fancy features
like different text encoding support and it cannot even redraw itself when
something else overdraws it.
But it's pretty impressiv that it works so well under Haiku.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12068 a95241bf-73f2-0310-859d-f6bbb57e9c96