- add keyboard bindings button to options
- hooked keyboard binding panel to button
- WIP bindings drawn in activity
- keyboard binding keys finally appear
- keyboard binding input widget
- reserved keys logic working
- removed debug logs
- pref saved on key release
- more reserved keys
- fixed memory bad alloc error
- modifier bindings
- scroll panel for bindings view
- added sdl id to bindings
- cache sdl scan id into prefs
- function ids are getting picked up
- more keyboard mappings
- more key bindings + reserved keys
- keyboard bindings working
- write keyboard bindings pref on load
- sync new functions to prefs
- final touches
- Keep those include trees flat (see 0179cefc
)
- Fix tabs
- WIP - many to one binding
- WriteDefaultPrefs is now instance method
- model add, remove and save methods
- clear prefs before saving
- added method for checking binding conflict
- notify view on key combo change
- route binding notification to gameview
- view foundations for overhaul
- fixed memory issue + has conflicting key issue
- fixed prefs not being cleared before save
- override text input to do nothing
- fixed many complications due to duplicated hotkeys
- missing index on new model caused problems
- WIP - view adaptation
- WIP - add and remove button layout
- more patches
- fixed empty textboxes problem
- WIP - frontend overhaul
- fixed ordering issue
- binding removal - wip
- function store to hold no shortcut data
- reset to defaults button added
- add from no shortcut works
- error message on conflict
- better summary for PopBindingByFunctionId
- keyboard bindings hooked to gameview keypress
- do not return correcty function id if no shortcut
- flatten include trees
- remove debug comment
- spaces to tabs
37 lines
938 B
C++
37 lines
938 B
C++
#pragma once
|
|
|
|
#include "Panel.h"
|
|
|
|
namespace ui
|
|
{
|
|
class ScrollPanel: public Panel
|
|
{
|
|
protected:
|
|
int scrollBarWidth;
|
|
Point maxOffset;
|
|
float offsetX;
|
|
float offsetY;
|
|
float yScrollVel;
|
|
float xScrollVel;
|
|
bool isMouseInsideScrollbar;
|
|
bool isMouseInsideScrollbarArea;
|
|
bool scrollbarSelected;
|
|
int scrollbarInitialYOffset;
|
|
int scrollbarInitialYClick;
|
|
int scrollbarClickLocation;
|
|
public:
|
|
ScrollPanel(Point position, Point size);
|
|
|
|
int GetScrollLimit();
|
|
void SetScrollPosition(int position);
|
|
inline float GetScrollPositionY() const { return offsetY; }
|
|
|
|
void Draw(const Point& screenPos) override;
|
|
void XTick(float dt) override;
|
|
void XOnMouseWheelInside(int localx, int localy, int d) override;
|
|
void XOnMouseClick(int localx, int localy, unsigned int button) override;
|
|
void XOnMouseUp(int x, int y, unsigned int button) override;
|
|
void XOnMouseMoved(int localx, int localy, int dx, int dy) override;
|
|
};
|
|
}
|