mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-07-25 00:04:49 +02:00
Fix line rendering in texmode
This commit is contained in:
@@ -225,10 +225,13 @@ public:
|
||||
|
||||
void Draw(UIContext &dc) override {
|
||||
if (g_Config.bTouchSnapToGrid) {
|
||||
dc.BeginNoTex();
|
||||
for (int x = x1; x < x2; x += g_Config.iTouchSnapGridSize)
|
||||
dc.Draw()->vLine(x, y1, y2, col);
|
||||
for (int y = y1; y < y2; y += g_Config.iTouchSnapGridSize)
|
||||
dc.Draw()->hLine(x1, y, x2, col);
|
||||
dc.Flush();
|
||||
dc.Begin();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -352,6 +355,7 @@ void TouchControlLayoutScreen::CreateViews() {
|
||||
|
||||
root_ = new AnchorLayout(new LayoutParams(FILL_PARENT, FILL_PARENT));
|
||||
|
||||
root_->Add(new SnapGrid(leftColumnWidth+10, bounds.w, 0, bounds.h, 0x3FFFFFFF));
|
||||
Choice *reset = new Choice(di->T("Reset"), "", false, new AnchorLayoutParams(leftColumnWidth, WRAP_CONTENT, 10, NONE, NONE, 84));
|
||||
Choice *back = new Choice(di->T("Back"), "", false, new AnchorLayoutParams(leftColumnWidth, WRAP_CONTENT, 10, NONE, NONE, 10));
|
||||
Choice *visibility = new Choice(co->T("Visibility"), "", false, new AnchorLayoutParams(leftColumnWidth, WRAP_CONTENT, 10, NONE, NONE, 298));
|
||||
@@ -479,7 +483,6 @@ void TouchControlLayoutScreen::CreateViews() {
|
||||
for (size_t i = 0; i < controls_.size(); i++) {
|
||||
root_->Add(controls_[i]);
|
||||
}
|
||||
root_->Add(new SnapGrid(leftColumnWidth+10, bounds.w, 0, bounds.h, 0x7FFFFFFF));
|
||||
}
|
||||
|
||||
// return the control which was picked up by the touchEvent. If a control
|
||||
|
||||
Reference in New Issue
Block a user