Rewrote the push/pop state and ViewAttr stuff:

- it now seems to work finally correctly
- renamed ViewAttr to ViewState and put it into the BPrivate namespace
- some refactoring (moved some private BView methods to ViewState)
- renamed AS_LAYER_MOVETO/RESIZETO to *_TO (note the underscore)
- exchanged BView::originX/Y with fParentOffset (BPoint)
- divided AS_LAYER_GET_COLORS into separate ones for high/low/view color
- BView::SetPattern() now actually works as expected (ie. updates
  only if necessary)
- exchanged the ViewAttr::flags with ViewState::valid_flags which inverses
  the previous logic (which wasn't even used consistently)
- fState was initialized twice (incorrectly by the ViewAttr constructor,
  and then again correctly by initCachedState()) - now the ViewState
  constructor does the job alone, but correctly
- BView::PushState() no longer resets the state (it did so only locally
  anyway...)
- cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13325 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2005-06-28 18:56:55 +00:00
parent f479b4974a
commit 80a230b10e
5 changed files with 589 additions and 606 deletions
+5 -3
View File
@@ -265,7 +265,9 @@ enum {
AS_LAYER_SET_HIGH_COLOR,
AS_LAYER_SET_LOW_COLOR,
AS_LAYER_SET_VIEW_COLOR,
AS_LAYER_GET_COLORS,
AS_LAYER_GET_HIGH_COLOR,
AS_LAYER_GET_LOW_COLOR,
AS_LAYER_GET_VIEW_COLOR,
AS_LAYER_PRINT_ALIASING,
AS_LAYER_CLIP_TO_PICTURE,
AS_LAYER_GET_CLIP_REGION,
@@ -287,8 +289,8 @@ enum {
AS_LAYER_INVAL_RECT,
AS_LAYER_INVAL_REGION,
AS_LAYER_INVERT_RECT,
AS_LAYER_MOVETO,
AS_LAYER_RESIZETO,
AS_LAYER_MOVE_TO,
AS_LAYER_RESIZE_TO,
AS_LAYER_SET_STATE,
AS_LAYER_SET_FONT_STATE,
AS_LAYER_GET_STATE,