History log of /haiku/src/servers/app/Layer.h
Revision Date Author Comments
# 551438b9 25-Jul-2015 Julian Harnath <julian.harnath@rwth-aachen.de>

app_server: add new BView layers API

* Add new methods
BView::BeginLayer(uint8 opacity)
BView::EndLayer()

* All drawing between begin and end of a layer is redirected onto an
intermediate bitmap. When ending the layer, this bitmap is
composited onto the view with the opacity given when the layer was
started.

* Layers can be nested arbitrarily and will be blended onto each
other in order. There can also be any arbitrary interleaving of
layer begin/end and drawing operations.

* Internally, drawing commands are redirected into a BPicture between
BeginLayer and EndLayer (but client code need not know or care
about this). Client code can also start/end other BPictures while
inside a layer.

* Uses the PictureBoundingBoxPlayer to determine the size of the
layer bitmap before allocating and drawing into it, so it does not
allocate more memory than necessary and -- more importantly -- it
will not alpha-composite more pixels than necessary.

* Drawing mode is always set to B_OP_ALPHA, blend mode to
(B_PIXEL_ALPHA, B_ALPHA_COMPOSITE) while inside layers. This is
necessary for (a) correct compositing output and (b) for
redirection of drawing into the intermediate bitmap, which uses the
renderer_region offset (in B_OP_COPY, the Painter does not use the
AGG renderer methods, it directly accesses the pixel data. This
would access out-of-bounds without the offset, so B_OP_COPY cannot
be allowed.)
To ensure these modes aren't changed, BView::SetDrawingMode()
and BView::SetBlendingMode() are ignored while inside a layer.

* The main motivation behind this new API is WebKit, which internally
expects such a layers functionality to be present. A performant and
reusable implementation of this functionality can only be done
server-side in app_server.


# e83820ed5720395d39a1ff809991b4fd76326548 07-Dec-2005 Axel Dörfler <axeld@pinc-software.de>

Merged app_server_new_clipping branch changes r15290 to 15418 back into trunk.
Also fixed Jamfile for the test environment.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15419 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f89b4c9a23a12a1bae426cc920dccfb6b0d022db 29-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Have I said input event handling is done?
* didn't realize that mouse events always go to the view under the mouse, not
only if its the focus window (FFM can really do harm, after all :-)).
* removed a TODO from the list: EventDispatcher::Target is now a public
class EventTarget, and every ServerWindow has one.
* as a result, EventDispatcher no longer manages targets itself, it
just maintains a list of them. You no longer set messengers, you
only set targets.
* customization of the message filters, they no longer inherit from
BMessageFilter (but EventFilter).
* a message target is no longer set explicetly anywhere, it's only
changed in the message filters if needed.
* therefore, no more locking mess in the EventDispatcher needed.
* this also made the EventDispatcher::fLastFocus stuff superfluous.
* moved the RootLayer::MouseEventHandler() into the message filter.
* Replaced RootLayer::_ChildAt() with WindowAt().
* WindowLayer now has an idea if it has focus or not, it no longer needs
to query the RootLayer for this - maybe we should rename "focus" to
"active", though (as far as layers are concerned).
* the "_view_token" data is now added from the EventDispatcher, not
the (Window)Layer class anymore.
* removed Layer::MouseWheelChanged() as we currently don't need it
(if the need arises, we can add it back later again)
* there is still no mouse moved message sent when opening a window
under the cursor, though...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15228 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8fc80f17d97550b5da5ee6ec72d525bd2661af1d 28-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

refactored a _AddChildToList() and a _RemoveChildFromList() out of AddChild() and
RemoveChild() (very similar to what BView does).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15206 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1863b5b6a41fb94ca20b2cd8fba33063bfa6a6cb 24-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Removed the "owner" stuff from Layer - it already knows its window.
Layer no longer knows anything about its subclass WindowLayer.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15131 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 14e1abfe7d3e264bd7d93d8db6b9273f133a3e10 24-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Made Layer::_AllRedraw() virtual so that it doesn't need this ugly hack to
send _UPDATE_ messages (WindowLayer now overrides that method).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15129 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4b813bf2670024494ff699a4a2ccb87ca3bccd61 24-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed WinBorder to WindowLayer, and OffscreenWinBorder to OffscreenWindowLayer.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15128 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bde8b9c6e0e93228febce69548748d26d62cb254 24-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* Layers are now put into an application wide token space that mirrors the
client's token space.
* finding layers by token is now O(1) instead of O(n) (as they are looked
up in the token space).
* removed Layer::FindView() as it's no longer needed (or should be used).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15113 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 343e4ff465e53564507679045cd5f20b475079e7 23-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Got rid of fAdFlags whatever that was meant to be.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15109 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5ed055623689cfd25cbf637f10339db204fcbc93 23-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* Got rid of the frightening Layer::fCurrent/RootLayer::fWinBorderIndex as well as
NextChild() and PreviousChild() - the current WinBorder list is now rebuilt on every
change; this is not perfect, and only a temporary solution (but cleaner than the
previous one).
* Introduced Layer::PreviousLayer()/NextLayer() methods that return the previous resp.
the next sibling.
* Moved {show|hide}_winBorder() into {Show|Hide}WinBorder() and got rid of the former.
* Renamed Layer::fServerWin to fWindow.
* removed some unused stuff, minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15108 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5a67ef66341c8c34b716b4ff37b39ff55b8c7617 23-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Removed broken Layer::LayerAt() semantics (for recursive == false),
and introduced a RootLayer::_ChildAt() that is used instead.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15097 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a8d44b6feabf366f4c686b4db9924fe498462ea9 23-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Quick fix for the broken focus changing I introduced earlier.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15096 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6450b76dd4cef8cf04e8d31471517b40a35fa09a 23-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Next big step in the event handling:
* RootLayer's mouse event processing is now at its minimum - the
EventDispatcher handles them now. As a result, a window will now
get only one message per event.
* RootLayer adds "_view_token" to mouse moved messages that specify
the view currently under the cursor.
* There is now a mouse event layer in RootLayer that gets preferred
when it's set - this is now used for the window moving instead of
the previous mechanism.
* changed the previous DistributeMessage() to an UnpackMessage()
method following Adi's suggestion.
* caveat: some things might be functionally broken in RootLayer now
because of removing the mouse notification stuff.
* "be:transit" handling is now done completely client side by
BWindow::_SanitizeMessage(() (similar to what the input_server does).
This should also make the mechanism pretty robust, since every
B_MOUSE_MOVED message can now trigger the view transit (in case a
message is lost). B_WINDOW_ACTIVATED messages should be generated
client side as well.
* renamed AS_LAYER_GET_MOUSE_COORDS to AS_GET_MOUSE as it's not a
layer specific command, and also gets the mouse buttons.
* B_MOUSE_* messages from the up server now contain only a "screen_where"
field; "where" (in window's coordinates) and "be:view_where" are
added in BMessage::_SanitizeMessage().
* messages that don't have a valid target in the looper are now
dropped instead of being sent to the looper - this should be done
in BLooper as well, though.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15087 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b223f7804125d5a1cc0f397085125930a7a93a22 20-Nov-2005 Stephan Aßmus <superstippi@gmx.de>

fixes origin and scale handling, it behaves mostly like R5 now (it is used for drawing only, yes not mouse coords or anything else). Also fixes offscreen layers clipping rebuilding when the user defined clipping is added or changed

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15040 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2899b880f6c1e9ba92bbd4e78f4dc63c720a5e24 19-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Uncommented a correct piece of code. B_FRAME_RESIZED/MOVED are sent more accurately. Renamed AddToViewsWithInvalidCoords, SendViewCoordUpdateMsg into _AddToViewsWithInvalidCoords, _SendViewCoordUpdateMsg.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15036 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8e81fc491916285e25c042081c5db22586033f89 19-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Some cleanup. Removed do_Hide, do_Show and do_CopyBits

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15034 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 55d6d70ee59eb2e2473c2195b5e6b26ee29380d3 18-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* EventDispatcher::AddListener() now honors the BView semantics and will only
update the options in case the specified eventMask was zero.
* Added missing EventDispatcher::RemoveTemporaryTarget().
* Layers setting their event mask are now added to the EventDispatcher.
* The RootLayer is no longer contacted for SetEventMask() - it still handles
SetMouseEventMask(), tough - as a result, SetEventMask() temporarily doesn't
work anymore.
* Added Layer::ViewToken() method.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15023 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fa26723bb29d97b4bcb3437a60da21d59cd266b1 18-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* Moved workspace keyboard switch and dump screen capability from RootLayer
into a Desktop keyboard filter.
* Removed keyboard handling code from RootLayer and Layer.
* Renamed Desktop::ActiveRootLayer() to RootLayer() as there is only one
root layer per desktop.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15018 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8d8f5950d0c28592beaef5196091ef2a5ce92901 17-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Some cleanup, mostly GetHWInterface() to HWInterface().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15016 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a436bab2dab4a997d5bda383da62472c4f91f1ba 14-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Renamed fVisible2 and fFullVisible2 to fVisible and fFullVisible.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14921 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5df853ea79b44c49eb0722c8e95f422cd2c19b38 14-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* Renamed Layer::GetWantedRegion() to GetOnScreenRegion().
* minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14920 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 618c515c4c100842178d66ab54c04450376429a8 14-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

* pruned Layer::PruneTree()
* the Layer destructor now deletes all of the layer's children
* WinBorder no longer has to delete its top layer, as it's also its child.
* minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14919 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c5522d81d844105096d3a23fd790acc1a943240d 10-Nov-2005 Stephan Aßmus <superstippi@gmx.de>

* added SetUserClipping() and DrawingRegion(), which is used for
handling client defined clipping. The client clipping stays in local coords,
which greatly simplyfies things. We ought to find a way to reduce the number
of regions needed per Layer. I just added another one...
* renamed a few "lay"s to "child".
* used the new client added clipping in ServerWindow


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14847 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 76d68e8ad8aa86c83c94423c14623e84a6ac3ded 09-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

More cleanup.
* moved code from Layer::do_MoveBy/do_ResizeBy/do_ScrollBy into
Layer::MoveBy/ResizeBy/ScrollBy()
* removed do_Move/Resize/ScrollBy()
* removed WinBorder::_ResizeBy()




git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14810 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 02414ebd4eb68af9e481ed7a8ed7900044451322 08-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Cleanup.
* removed old Convert{To|From}{Parent|Top} methods. They were replaced by
Convert{To|From}{Parent|Screen}(type *data)
* removed some unused methods from Layer class.
* re-aranged Layer's class declaration - grouped methods
* made all Layer's members private.
* renamed a few private methods from method_name _MethodName




git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14778 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d4e4f29a420718c8ec346f37c84377c5638195bb 07-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Cleanup after the old clipping code. Removed a few methods as others took their place. More cleanup to follow on tomorrow. :-)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14764 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2c8cfe2dfcfc090dd49ff4d2a9e4d1bf36b29e83 07-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Bye-bye old clipping codesvn update Some cleanup to follow.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14760 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ac4f06c5c62815850056e5cba836e2676ffc761f 06-Nov-2005 Adi Oanca <adioanca@nowhere.fake>

Fixed invalidation with new clipping code. Only what's needed is
redrawn/invalidated now, with a single exception which I am working
on(when changing the front window the whole window area is invalidated
not just the region that became visible). The old Clipping code is broken
now. I will remove it in the next days.

Actual changes:
* removed Layer::GetWantedRegion() - was badly implemented.
* made Layer::_GetWantedRegion public and renamed it to: you guessed! :-)

* introduced Layer::MarkForRebuild(), TriggerRebuild(). You want to
calculate the new clipping regions, mark an area and then call
TRiggerRebuild() which will rebuild the visible regions for the current
Layer and all its descendants.

* for a Layer to redraw some parts of it, use
RootLayer::MarkForRedraw() to mark a region and then
RootLayer::TriggerRedraw() to see the changes (or send _UPDATE_ message in
case of a WinBorder).






git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14719 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d79939116c2f2ddbe765331fe31118307ed13969 04-Nov-2005 Stephan Aßmus <superstippi@gmx.de>

fixed build for old clipping

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14708 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 58468dfed0b7013c600aecb0a714194bc98eeecc 04-Nov-2005 Stephan Aßmus <superstippi@gmx.de>

first step of geting rid of abstract DisplayDriver base class for less development overhead, DisplayDriverPainter is renamed to DrawingEngine

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14694 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 55e764c7f63520daad64c9b5519a043158ffc89e 04-Nov-2005 Stephan Aßmus <superstippi@gmx.de>

update license

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14690 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cb24f13bb05dfd2a6c92ec8198c4c7a811728767 03-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

The current graphics state of a Layer can now be retrieved by the new CurrentState() method.
ServerWindow is now using that method instead of directly accessing a Layer member.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14684 a95241bf-73f2-0310-859d-f6bbb57e9c96


# aca4f50d1eefef8bf137cc16f5b707d223494377 04-Nov-2005 Axel Dörfler <axeld@pinc-software.de>

Merged DrawData and LayerData to one class DrawState.
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


# 31ec092be1241fbaaae055a4463cd44a50f86cdf 29-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Introduced Layer::Activated() hook function. Moved some functionality from RootLayer to WinBorder

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14565 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fc9c02aa4f8c68f1e2535e9a4665c75abaa145aa 28-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Made the new clipping code to use a single message to update client frame/bounds. ACTIVATED new clipping code! If someone notices problems please write to any list

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14558 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 28d42d6e7597e89b30fb2f3890e2d9f6477c3d96 25-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

RootLayer thread receives BMessages only. Changed ViewHWInterface to send BMessages for input events

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14520 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3b19c4531df23c1c5e4ea162eaae97dc83d8cfda 24-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Introduced Layer::KeyDown/KeyUp/UnmappedKeyDown/UnmappedKeyUp/ModifiersChanged hooks. Simplified a bit RootLayer::KeyboardEventHandler().

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14494 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9e5c5747036adc5103c3ff8851ebfac8b47b59ab 24-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Layer::SendUpdateMsg() will tell us if sending _UPDATE_ message succeded. We'll use that information to clear WinBorder::fCumulativeRegion(server per-window dirty region) only on success.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14493 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 182db85c0c66d7a260844e6b63e5925bfd465cd6 24-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Introduced Layer::MouseWheelChanged(). Cleaned up RootLayer::MouseEventHandler::case B_MOUSE_WHEEL_CHANGED.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14490 a95241bf-73f2-0310-859d-f6bbb57e9c96


# eead807371cff0824982470ccadd962370603763 24-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

removed Layer::fClassID

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14487 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 33691ce0acf7a04ad8dea37ffa304a537fabd586 11-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

Removed NEW_INPUT_HANDLING define and the old code

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14351 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b961b59696ca4e9db3c0f92cda795a080cef0b55 07-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

- replaced Layer::get_user_regions with _GetWantedRegion()
- replaced Layer::alter_visible_for_children with _ReserveRegions()
- simplified a bit Layer::rebuild_visible_regions()

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14335 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 88ef6ce8febf3fae94b1387408bb63aec76dd413 06-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

- fixed build for NEW_CLIPPING define
- implemented RootLayer::SetActive(WinBorder*).
- added support for BWindow::Activate(). I realize now that I only added support for Activate(true). :-D In the next days I will add support for Activate(false).
- removed a few cases from ServerWindow as they are not needed.
- addapted WinBorder::MouseDown() to work with the new RootLayer::SetActive() implementation.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14318 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bbf8c95b5a306580f4303ea8771c00287a6cf397 01-Oct-2005 Adi Oanca <adioanca@nowhere.fake>

* added Layer/WinBorder::WorkspaceChanged() hook.
* make RootLayer::SetWinBorderWorkspaces() work under NEW_INPUT_HANDLING
define. Soon I think I'll move this method under WinBorder's hood.
* RootLayer::change_winBorder_feel() is also working under this define

** NEW_INPUT_HANDLING define is active.
If someone discovers something bad happening after this checkin please
notify me on app_server list. If in one week no major problems appear,
I'll remove this define and the old code.
Thanks.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14288 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8285d6b3c0e19b94803b48340ad12286a528b65d 28-Sep-2005 Adi Oanca <adioanca@nowhere.fake>

* implemented/fixed RootLayer::SetActiveWorkspace() under
NEW_INPUT_HANDLING define.
* added Layer/WinBorder::WorkspaceActivated()



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14270 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1b65556d662b8ffbc251791433c58112eac398b4 18-Sep-2005 Adi Oanca <adioanca@nowhere.fake>

more work on the input handling. I let Layer/WinBorder handle the MouseDown/Moved/Up instead of doing this in RootLayer::MouseEventHandler(). I did this because I felt it's more clean and in the near future RootLayer may have other children than WinBorders, for example simple Layers representing tooltips/bubbles/etc.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14198 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8b94d5ecdd346ade922feda81dc6588ae4ef243d 15-Sep-2005 Adi Oanca <adioanca@nowhere.fake>

Work in progress for the new input handling stuff...

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14191 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2138d632a6ea8a98434e9b207d8f3adb421326d7 08-Sep-2005 Adi Oanca <adioanca@nowhere.fake>

In adding support for BView input events I got to rework/refractor the mouse input handling. This should be ready in a few days, so don't worry about the code being #ifdef-ed :-)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14131 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ffd509fd9b4ae16fa1d210921a7071f394566ffd 05-Sep-2005 Adi Oanca <adioanca@nowhere.fake>

more code for input events. refractored some code in RootLayer class

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14119 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 642467d0771f3c0c025dfcc847197d36e3e3703f 10-Jul-2005 Stephan Aßmus <superstippi@gmx.de>

renamed the tree parsing/child iteration functions, I think it is much clearer now what they do, more likely to find bugs too

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13572 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 359c905c57c9d43ce84badcaef859fa94322897c 05-Jul-2005 Stephan Aßmus <superstippi@gmx.de>

offscreen bitmaps work, tested on Haiku as well, supports all colorspaces that BBitmap::ImportBits() supports. It uses a fallback for non-B_RGB(A)32 bitmaps. Added support for B_SUB_PIXEL_PRECISION view flags, though it is a bit hacky, since I had to add it to LayerData, even though it is not a true part of stack data. Added Layer::SetFlags() to enforce code path and update fLayerData. Cleaned up DisplayDriverPainter and DisplayDriver API (changed some const BRect& rect to simply BRect rect in order to be able to reuse it in the code), moved Painter.h, the test environment only draws the changed part of the frame buffer again - this causes a lot less CPU overhead, Painter special cases stroke width of 1.0 to use square caps, which is similar to R5 implementation and removes a lot of problems with non-straight line drawing, ServerWindow uses the DisplayDriver from it's WinBorder instead of the one from the Desktop (needed for offscreen windows, which have their own DisplayDriverPainter), it also checks for GetRootLayer() == NULL, because offscreen layers are not attached to a RootLayer, there was a fix for scrolling which worked at least in the test environment, it is now defunced, because Adi moved _CopyBits to Layer... I need to reenable it later, LayerData has no more fEscapementDelta, also fixed fFontAliasing (which was thought to overriding the font flags, and now works as such again), Desktop initialises the menu_info and scroll_bar_info stuff, which makes ScrollBars work actually... hope I didn't forget something.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13448 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b72bef86301914a115580047c52122bff9ce8f52 02-Jul-2005 Adi Oanca <adioanca@nowhere.fake>

Added Flags(), ResizeMode(), made virtuals be prototypes only.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13397 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f97b5cb5864f348b7f4160d2031e35ff21054983 28-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

Moved CopyBits from ServerWindow to Layer. Also, made CopyBits code execute in RootLayer's thread

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13321 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 13029492045d186efa6d8960875b65cd352348cf 28-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

Layer::Show/Hide now works. Improved some invalidating calls. fixed some potential problems

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13317 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ecf3bc3eb477fe375e52446ba01e1cbcc523265c 27-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

moving and resizing windows works with the new clipping code. scrolling BViews also works.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13311 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e3fbc7752f92b6549e6be14934fcbc5514471f7c 25-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

integration of the new clipping code continues

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13277 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e603410b82dea0c0cf4a474dfa055b4bc87de5e6 25-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

- simplified a little the update code/process.
- moved part of the update code from Layer to WinBorder. Fits better
there.
- renamed a couple members.
- some cleanup.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13273 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a38e46a046cbb27fef680a1c9f93b000663d70c9 23-Jun-2005 Axel Dörfler <axeld@pinc-software.de>

ServerApp now maintains a list of all windows, ServerWindow's AS_DELETE_WINDOW
will update it automatically.
Renamed ServerWindow::fName to fTitle, made it a pointer - it will now just
adopt the title pointer that came from AS_CREATE_WINDOW.
Just another cleanup round: renamed Layer::GetName() to Name(), no
more layer->fName->String() accesses.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13239 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3df649ecb33bb25aeb4ecb3cee6184eef4451081 21-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

managed to show/hide empty windows with the new clipping code

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13221 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5fcce1f54ba464dfb7339cdaafe1ac6349f1fe2c 16-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

renamed a few members so that I don't have problems later. removed more methods/members

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13190 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e0911bbb29bc283db0ee3e0737bcddeb87137944 16-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

yes, yes... removing unneeded methods/members.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13188 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 83265d84dbb1e02ea9cccca6d1746ef5444024cc 16-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

More work for integrating the new clipping code.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13186 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d41a1e80b8bab52b8cb07aba5320399970d37cd3 15-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

Integrated the new clipping code. It compiles but it does not work yet. Do not worry, it's guarded by a #define :-)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13161 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0f0232c767bdcd3a37520ef3cfdf15ea984334ee 15-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

Started adding new clipping code - not active ATM. Removed Virtual prefix

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13159 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 524c020956f0ff69fc25d83933e25638498c93fb 15-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

Bounds() takes into account previous pushed states

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13157 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b81c5513c575d21f43b15bc8660968b9e0e703fe 10-Jun-2005 Adi Oanca <adioanca@nowhere.fake>

addapted code as a result of removing viewColor, background and overlay bitmap members from LayerData

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13051 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e1bc5f2def8279236805363b5dd1ca88ac94a6dd 10-Jun-2005 Stefano Ceccherini <stefano.ceccherini@gmail.com>

Added Layer::Push/PopState() and moved their implementation from ServerWindow.cpp. We definitely need more encapsulation

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13043 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 45ca1c948cba0471b3107e037489e54500215c50 03-Jun-2005 Stefano Ceccherini <stefano.ceccherini@gmail.com>

Simplified code for BView::ClipToPicture() a lot (both server side and client side). Regions passed with that method should take the place of regions passed with BView::ConstrainClippingRegion(). Note that the needed server support hasn't yet been implemented.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12939 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ad6b480400e921f46a444359fc92be5251ab6ac4 16-May-2005 Stephan Aßmus <superstippi@gmx.de>

Work in Progress. The server keeps the client window up to date on layer movement/resizing. This fixes quite a few problems and brings support for FrameMoved and Resized hooks. But implementing it this way has its own set of problem, most importantly: When a BView calles Window()->CurrentMessage() in its FrameMoved/Resized hooks, it will see something very different from what it would see in R5. This needs to be fixed, but I have not had a good idea how to do this other than faking the current message in BWindow, which I didn't look into.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12689 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1596a167c0c7cd591f8817db58c6ef0d02f9375e 28-Apr-2005 Stephan Aßmus <superstippi@gmx.de>

work around for layers not being moved that have not yet been added to the tree. See WinBorder::MoveTo for the explaination. The same problem should be at other places and most likely for normal views as well. This fixes BWindow::MoveXX() when it is not yet Show()n

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12500 a95241bf-73f2-0310-859d-f6bbb57e9c96


# db7226db9d3de3be44b52085559b68ef6ad69514 27-Apr-2005 Stephan Aßmus <superstippi@gmx.de>

work in progress to get scrolling working, so Adi can have a look, no changes to existing functionality, cleanup in Layer.cpp

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12481 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d53639ce2e27b02b8fd5f6b320495f6361314cce 21-Apr-2005 Adi Oanca <adioanca@nowhere.fake>

Implemented support for BWindow::SetFeel()

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12456 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d137bc62e8b80f581524a50a730dfe47dbd82b91 10-Apr-2005 Adi Oanca <adioanca@nowhere.fake>

Removed a friend, a printf and a blank line. :-)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12280 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0cb3fdda9344257562d51672eea63f0977e294a3 05-Apr-2005 Adi Oanca <adioanca@nowhere.fake>

Nothing special. Just some cleanup to the update code. There is still a problem with layers not being properly updated sometimes when you move windows arround. The same problem occurs a lot more often when resizing windows. I'm traking it... :-)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12259 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 33bbe223914093509b4bc56bea8a90c81af80a37 24-Mar-2005 Axel Dörfler <axeld@pinc-software.de>

Moved app_server files to app/.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@11972 a95241bf-73f2-0310-859d-f6bbb57e9c96