RemoteDrawingEngine: Reduce RP_READ_BITMAP result timeout.
[haiku.git] / src / preferences / screensaver / ScreenCornerSelector.h
blobe1a72504556e48843709b0641d59db4fafa989ce
1 /*
2 * Copyright 2003-2013 Haiku, Inc. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
5 * Authors:
6 * Michael Phipps
7 * Axel Dörfler, axeld@pinc-software.de
8 */
9 #ifndef SCREEN_CORNER_SELECTOR_H
10 #define SCREEN_CORNER_SELECTOR_H
13 #include <Control.h>
16 #include "ScreenSaverSettings.h"
19 class ScreenCornerSelector : public BControl {
20 public:
21 ScreenCornerSelector(BRect frame,
22 const char *name, BMessage* message,
23 uint32 resizingMode);
25 virtual void Draw(BRect updateRect);
26 virtual void MouseDown(BPoint point);
27 virtual void MouseUp(BPoint point);
28 virtual void MouseMoved(BPoint where, uint32 transit,
29 const BMessage* dragMessage);
30 virtual void KeyDown(const char* bytes, int32 numBytes);
32 virtual void SetValue(int32 value);
33 virtual int32 Value();
35 void SetCorner(screen_corner corner);
36 screen_corner Corner() const;
38 private:
39 BRect _MonitorFrame() const;
40 BRect _InnerFrame(BRect monitorFrame) const;
41 BRect _CenterFrame(BRect innerFrame) const;
42 void _DrawStop(BRect innerFrame);
43 void _DrawArrow(BRect innerFrame);
44 screen_corner _ScreenCorner(BPoint point,
45 screen_corner previous) const;
47 screen_corner fCurrentCorner;
48 int32 fPreviousCorner;
52 #endif // SCREEN_CORNER_SELECTOR_H