Add diagonal arrows to ControlLook DrawArrowShape() method
This commit is contained in:
parent
c6b72ad6e4
commit
1b41173c8a
@ -61,7 +61,11 @@ public:
|
||||
B_LEFT_ARROW = 0,
|
||||
B_RIGHT_ARROW = 1,
|
||||
B_UP_ARROW = 2,
|
||||
B_DOWN_ARROW = 3
|
||||
B_DOWN_ARROW = 3,
|
||||
B_LEFT_UP_ARROW = 4,
|
||||
B_RIGHT_UP_ARROW = 5,
|
||||
B_RIGHT_DOWN_ARROW = 6,
|
||||
B_LEFT_DOWN_ARROW = 7
|
||||
};
|
||||
|
||||
enum {
|
||||
|
@ -762,6 +762,26 @@ BControlLook::DrawArrowShape(BView* view, BRect& rect, const BRect& updateRect,
|
||||
rect.top + 1 + rect.Height() / 1.33);
|
||||
tri3.Set(rect.right + 1, rect.top + 1);
|
||||
break;
|
||||
case B_LEFT_UP_ARROW:
|
||||
tri1.Set(rect.left, rect.bottom);
|
||||
tri2.Set(rect.left, rect.top);
|
||||
tri3.Set(rect.right, rect.top);
|
||||
break;
|
||||
case B_RIGHT_UP_ARROW:
|
||||
tri1.Set(rect.left, rect.top);
|
||||
tri2.Set(rect.right, rect.top);
|
||||
tri3.Set(rect.right, rect.bottom);
|
||||
break;
|
||||
case B_RIGHT_DOWN_ARROW:
|
||||
tri1.Set(rect.right, rect.top);
|
||||
tri2.Set(rect.right, rect.bottom);
|
||||
tri3.Set(rect.left, rect.bottom);
|
||||
break;
|
||||
case B_LEFT_DOWN_ARROW:
|
||||
tri1.Set(rect.right, rect.bottom);
|
||||
tri2.Set(rect.left, rect.bottom);
|
||||
tri3.Set(rect.left, rect.top);
|
||||
break;
|
||||
}
|
||||
|
||||
BShape arrowShape;
|
||||
|
Loading…
x
Reference in New Issue
Block a user