blob: fa49eca31f9425d58f7c4d7206636542b01904fe (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
#include "Component.hpp"
#include <algorithm> // std::max
#include <cmath>
namespace cgeditor {
class Scrollbar : public Component {
/// @brief Set to true if it is the horizontal scrollbar
bool IsHorizontal;
Element bg,bar;
double DragY,DragX;
bool Trigger;
public:
Scrollbar(Status* s,bool IsHorizontal);
void Refresh();
/// @brief Goto a given graphical coordinate (if possible using current scroll range)
void Focus(double XorY);
};
} // namespace cgeditor
|