* small cleanups for more coding style consistency

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23159 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stephan Aßmus 2007-12-26 14:12:12 +00:00
parent 1d4722b73a
commit a4d578c4cb
2 changed files with 19 additions and 23 deletions

View File

@ -1142,16 +1142,17 @@ ViewLayer::SetEventMask(uint32 eventMask, uint32 options)
void
ViewLayer::SetCursor(ServerCursor *cursor)
{
if (cursor != fCursor) {
if (fCursor)
fCursor->Release();
if (cursor == fCursor)
return;
fCursor = cursor;
if (fCursor)
fCursor->Release();
if (fCursor) {
fCursor->Acquire();
fCursor->SetPendingViewCursor(false);
}
fCursor = cursor;
if (fCursor) {
fCursor->Acquire();
fCursor->SetPendingViewCursor(false);
}
}
@ -1163,13 +1164,6 @@ ViewLayer::SetPicture(ServerPicture *picture)
}
ServerPicture *
ViewLayer::Picture() const
{
return fPicture;
}
void
ViewLayer::Draw(DrawingEngine* drawingEngine, BRegion* effectiveClipping,
BRegion* windowContentClipping, bool deep)

View File

@ -37,8 +37,8 @@ class ServerPicture;
class ViewLayer {
public:
ViewLayer(IntRect frame, IntPoint scrollingOffset,
const char* name, int32 token, uint32 resizeMode,
uint32 flags);
const char* name, int32 token,
uint32 resizeMode, uint32 flags);
virtual ~ViewLayer();
@ -164,8 +164,9 @@ class ViewLayer {
ServerBitmap* ViewBitmap() const
{ return fViewBitmap; }
void SetViewBitmap(ServerBitmap* bitmap, IntRect sourceRect,
IntRect destRect, int32 resizingMode, int32 options);
void SetViewBitmap(ServerBitmap* bitmap,
IntRect sourceRect, IntRect destRect,
int32 resizingMode, int32 options);
void PushState();
void PopState();
@ -177,11 +178,12 @@ class ViewLayer {
uint32 EventOptions() const
{ return fEventOptions; }
ServerCursor* Cursor() const { return fCursor; }
void SetCursor(ServerCursor* cursor);
ServerCursor* Cursor() const { return fCursor; }
ServerPicture* Picture() const;
void SetPicture(ServerPicture* picture);
ServerPicture* Picture() const
{ return fPicture; }
// for background clearing
virtual void Draw(DrawingEngine* drawingEngine,
@ -223,7 +225,7 @@ class ViewLayer {
// clipping
void RebuildClipping(bool deep);
BRegion& ScreenClipping(BRegion* windowContentClipping,
bool force = false) const;
bool force = false) const;
void InvalidateScreenClipping();
inline bool IsScreenClippingValid() const
{ return fScreenClippingValid; }
@ -233,7 +235,7 @@ class ViewLayer {
protected:
void _MoveScreenClipping(int32 x, int32 y,
bool deep);
bool deep);
Overlay* _Overlay() const;
void _UpdateOverlayView() const;