Switch TouchInputFlags to enum class, fix some minor UI issues

Scroll views now only wheel-scroll if the mouse is hovering over them.
This commit is contained in:
Henrik Rydgård
2025-12-19 11:38:21 +01:00
parent dd112491db
commit 481d0fd18c
84 changed files with 265 additions and 186 deletions
+4 -4
View File
@@ -19,7 +19,7 @@ TouchInput GestureDetector::Update(const TouchInput &touch, const Bounds &bounds
}
// Mouse / 1-finger-touch control.
Pointer &p = pointers[touch.id];
if ((touch.flags & TOUCH_DOWN) && bounds.Contains(touch.x, touch.y)) {
if ((touch.flags & TouchInputFlags::DOWN) && bounds.Contains(touch.x, touch.y)) {
p.down = true;
p.downTime = time_now_d();
p.downX = touch.x;
@@ -30,7 +30,7 @@ TouchInput GestureDetector::Update(const TouchInput &touch, const Bounds &bounds
p.distanceY = 0.0f;
p.estimatedInertiaX = 0.0f;
p.estimatedInertiaY = 0.0f;
} else if (touch.flags & TOUCH_UP) {
} else if (touch.flags & TouchInputFlags::UP) {
p.down = false;
} else {
p.distanceX += fabsf(touch.x - p.lastX);
@@ -52,7 +52,7 @@ TouchInput GestureDetector::Update(const TouchInput &touch, const Bounds &bounds
p.active |= GESTURE_DRAG_VERTICAL;
// Kill the drag. TODO: Only cancel the drag in one direction.
TouchInput inp2 = touch;
inp2.flags = TOUCH_UP | TOUCH_CANCEL;
inp2.flags = TouchInputFlags::UP | TouchInputFlags::CANCEL;
return inp2;
}
} else {
@@ -67,7 +67,7 @@ TouchInput GestureDetector::Update(const TouchInput &touch, const Bounds &bounds
p.active |= GESTURE_DRAG_HORIZONTAL;
// Kill the drag. TODO: Only cancel the drag in one direction.
TouchInput inp2 = touch;
inp2.flags = TOUCH_UP | TOUCH_CANCEL;
inp2.flags = TouchInputFlags::UP | TouchInputFlags::CANCEL;
return inp2;
}
} else {
+24 -20
View File
@@ -7,6 +7,7 @@
#include <vector>
#include <string>
#include "Common/Common.h"
#include "Common/Input/KeyCodes.h"
#include "Common/Log.h"
@@ -128,43 +129,45 @@ public:
void FormatDebug(char *buffer, size_t bufSize) const;
};
enum {
TOUCH_MOVE = 1 << 0,
TOUCH_DOWN = 1 << 1,
TOUCH_UP = 1 << 2,
TOUCH_CANCEL = 1 << 3, // Sent by scrollviews to their children when they detect a scroll
TOUCH_WHEEL = 1 << 4, // Scrollwheel event. Usually only affects Y but can potentially affect X.
TOUCH_MOUSE = 1 << 5, // Identifies that this touch event came from a mouse. Id is now set to the mouse button for DOWN/UP commands.
TOUCH_RELEASE_ALL = 1 << 6, // Useful for app focus switches when events may be lost.
TOUCH_HOVER = 1 << 7,
enum class TouchInputFlags {
MOVE = 1 << 0,
DOWN = 1 << 1,
UP = 1 << 2,
CANCEL = 1 << 3, // Sent by scrollviews to their children when they detect a scroll
WHEEL = 1 << 4, // Scrollwheel event. Usually only affects Y but can potentially affect X.
MOUSE = 1 << 5, // Identifies that this touch event came from a mouse. Id is now set to the mouse button for DOWN/UP commands.
RELEASE_ALL = 1 << 6, // Useful for app focus switches when events may be lost.
HOVER = 1 << 7,
// These are the Android getToolType() codes, shifted by 10. Unused currently.
TOUCH_TOOL_MASK = 7 << 10,
TOUCH_TOOL_UNKNOWN = 0 << 10,
TOUCH_TOOL_FINGER = 1 << 10,
TOUCH_TOOL_STYLUS = 2 << 10,
TOUCH_TOOL_MOUSE = 3 << 10,
TOUCH_TOOL_ERASER = 4 << 10,
TOUCH_MAX_POINTERS = 10,
// TOOL_MASK = 7 << 10,
// TOOL_UNKNOWN = 0 << 10,
// TOOL_FINGER = 1 << 10,
// TOOL_STYLUS = 2 << 10,
// TOOL_MOUSE = 3 << 10,
// TOOL_ERASER = 4 << 10,
};
ENUM_CLASS_BITOPS(TouchInputFlags);
constexpr int TOUCH_MAX_POINTERS = 10;
// Used for asynchronous touch input.
// DOWN is always on its own.
// MOVE and UP can be combined.
// TODO: As this handles both mouse and touch, should probably rename to PointerInput or something.
struct TouchInput {
float x;
float y;
int id; // Needs to be <= GestureDetector::MAX_PTRS (10.)
int buttons; // bit mask
int flags;
TouchInputFlags flags;
double timestamp;
};
#undef KEY_DOWN
#undef KEY_UP
enum {
enum KeyInputFlags {
KEY_DOWN = 1 << 0,
KEY_UP = 1 << 1,
KEY_HASWHEELDELTA = 1 << 2,
@@ -184,8 +187,9 @@ struct KeyInput {
int flags;
// Used by mousewheel events. The delta is packed in the upper 16 bits of flags.
// TODO: Move mousewheel events to TouchInput?
int Delta() const {
return flags >> 16;
return (s32)flags >> 16;
}
};
+1 -1
View File
@@ -29,7 +29,7 @@ PopupScreen::PopupScreen(std::string_view title, std::string_view button1, std::
}
void PopupScreen::touch(const TouchInput &touch) {
if (!box_ || (touch.flags & TOUCH_DOWN) == 0) {
if (!box_ || (touch.flags & TouchInputFlags::DOWN) == 0) {
// Handle down-presses here.
UIDialogScreen::touch(touch);
return;
+1 -1
View File
@@ -249,7 +249,7 @@ bool KeyEvent(const KeyInput &key, ViewGroup *root) {
void TouchEvent(const TouchInput &touch, ViewGroup *root) {
focusForced = false;
root->Touch(touch);
if ((touch.flags & TOUCH_DOWN) && !focusForced) {
if ((touch.flags & TouchInputFlags::DOWN) && !focusForced) {
EnableFocusMovement(false);
}
}
+4 -4
View File
@@ -148,7 +148,7 @@ void ScreenManager::switchToNext() {
void ScreenManager::touch(const TouchInput &touch) {
std::lock_guard<std::recursive_mutex> guard(inputLock_);
// Send release all events to every screen layer.
if (touch.flags & TOUCH_RELEASE_ALL) {
if (touch.flags & TouchInputFlags::RELEASE_ALL) {
for (auto &layer : stack_) {
Screen *screen = layer.screen;
layer.screen->UnsyncTouch(screen->transformTouch(touch));
@@ -156,7 +156,7 @@ void ScreenManager::touch(const TouchInput &touch) {
} else if (!stack_.empty()) {
// Let the overlay know about touch-downs, to be able to dismiss popups.
bool skip = false;
if (overlayScreen_ && (touch.flags & TOUCH_DOWN)) {
if (overlayScreen_ && (touch.flags & TouchInputFlags::DOWN)) {
skip = overlayScreen_->UnsyncTouch(overlayScreen_->transformTouch(touch));
}
if (!skip) {
@@ -300,7 +300,7 @@ void ScreenManager::sendMessage(UIMessage message, const char *value) {
TouchInput input{};
input.x = -50000.0f;
input.y = -50000.0f;
input.flags = TOUCH_RELEASE_ALL;
input.flags = TouchInputFlags::RELEASE_ALL;
input.timestamp = time_now_d();
input.id = 0;
touch(input);
@@ -345,7 +345,7 @@ void ScreenManager::push(Screen *screen, int layerFlags) {
TouchInput input{};
input.x = -50000.0f;
input.y = -50000.0f;
input.flags = TOUCH_RELEASE_ALL;
input.flags = TouchInputFlags::RELEASE_ALL;
input.timestamp = time_now_d();
input.id = 0;
touch(input);
+20 -15
View File
@@ -16,16 +16,20 @@ ScrollView::~ScrollView() {
lastScrollPosY = 0;
}
void ScrollView::Measure(const UIContext &dc, MeasureSpec horiz, MeasureSpec vert) {
// Respect margins
Margins margins;
Margins ScrollView::GetMargins() const {
if (views_.size()) {
const LinearLayoutParams *linLayoutParams = views_[0]->GetLayoutParams()->As<LinearLayoutParams>();
if (linLayoutParams) {
margins = linLayoutParams->margins;
return linLayoutParams->margins;
}
}
return Margins(0);
}
void ScrollView::Measure(const UIContext &dc, MeasureSpec horiz, MeasureSpec vert) {
// Respect margins
const Margins margins = GetMargins();
// The scroll view itself simply obeys its parent - but also tries to fit the child if possible.
MeasureBySpec(layoutParams_->width, horiz.size, horiz, &measuredWidth_);
MeasureBySpec(layoutParams_->height, vert.size, vert, &measuredHeight_);
@@ -68,11 +72,7 @@ void ScrollView::Layout() {
Bounds scrolled;
// Respect margins
Margins margins;
const LinearLayoutParams *linLayoutParams = views_[0]->GetLayoutParams()->As<LinearLayoutParams>();
if (linLayoutParams) {
margins = linLayoutParams->margins;
}
const Margins margins = GetMargins();
scrolled.w = views_[0]->GetMeasuredWidth() - margins.horiz();
scrolled.h = views_[0]->GetMeasuredHeight() - margins.vert();
@@ -118,7 +118,7 @@ bool ScrollView::Key(const KeyInput &input) {
break;
}
if (input.flags & KEY_DOWN) {
if ((input.flags & KEY_DOWN) && mouseHover_) {
if ((input.keyCode == NKCODE_EXT_MOUSEWHEEL_UP || input.keyCode == NKCODE_EXT_MOUSEWHEEL_DOWN) &&
(input.flags & KEY_HASWHEELDELTA)) {
scrollSpeed = (float)(short)(input.flags >> 16) * 1.25f; // Fudge factor. TODO: Should be moved to the backends.
@@ -142,7 +142,7 @@ const float friction = 0.92f;
const float stop_threshold = 0.1f;
bool ScrollView::Touch(const TouchInput &input) {
if ((input.flags & TOUCH_DOWN) && scrollTouchId_ == -1 && bounds_.Contains(input.x, input.y)) {
if ((input.flags & TouchInputFlags::DOWN) && scrollTouchId_ == -1 && bounds_.Contains(input.x, input.y)) {
if (orientation_ == ORIENT_VERTICAL) {
Bob bob = ComputeBob();
float internalY = input.y - bounds_.y;
@@ -159,7 +159,7 @@ bool ScrollView::Touch(const TouchInput &input) {
Gesture gesture = orientation_ == ORIENT_VERTICAL ? GESTURE_DRAG_VERTICAL : GESTURE_DRAG_HORIZONTAL;
if ((input.flags & TOUCH_UP) && input.id == scrollTouchId_) {
if ((input.flags & TouchInputFlags::UP) && input.id == scrollTouchId_) {
float info[4];
if (gesture_.GetGestureInfo(gesture, input.id, info)) {
inertia_ = info[1];
@@ -168,12 +168,17 @@ bool ScrollView::Touch(const TouchInput &input) {
draggingBob_ = false;
}
if (input.flags & TouchInputFlags::MOUSE) {
// Kinda hacky, we should make a proper hover mechanism.
mouseHover_ = bounds_.Contains(input.x, input.y);
}
// We modify the input2 we send to children, so we can cancel drags if we start scrolling, and stuff like that.
TouchInput input2;
if (CanScroll()) {
if (draggingBob_) {
// Cancel any drags/holds on the children instantly to avoid accidental click-throughs.
input2.flags = TOUCH_UP | TOUCH_CANCEL;
input2.flags = TouchInputFlags::UP | TouchInputFlags::CANCEL;
// Skip the gesture manager, do calculations directly.
// Might switch to the gesture later.
Bob bob = ComputeBob();
@@ -190,7 +195,7 @@ bool ScrollView::Touch(const TouchInput &input) {
} else {
input2 = gesture_.Update(input, bounds_);
float info[4];
if (input.id == scrollTouchId_ && gesture_.GetGestureInfo(gesture, input.id, info) && !(input.flags & TOUCH_DOWN)) {
if (input.id == scrollTouchId_ && gesture_.GetGestureInfo(gesture, input.id, info) && !(input.flags & TouchInputFlags::DOWN)) {
float pos = scrollStart_ - info[0];
scrollPos_ = pos;
scrollTarget_ = pos;
@@ -203,7 +208,7 @@ bool ScrollView::Touch(const TouchInput &input) {
scrollToTarget_ = false;
}
if (!(input.flags & TOUCH_DOWN) || bounds_.Contains(input.x, input.y)) {
if (!(input.flags & TouchInputFlags::DOWN) || bounds_.Contains(input.x, input.y)) {
return ViewGroup::Touch(input2);
} else {
return false;
+2
View File
@@ -47,6 +47,7 @@ public:
NeighborResult FindScrollNeighbor(View *view, const Point2D &target, FocusDirection direction, NeighborResult best) override;
private:
Margins GetMargins() const;
float ChildSize() const; // in the scrolled direction
float ScrollMax() const;
float HardClampedScrollPos(float pos) const;
@@ -79,6 +80,7 @@ private:
float *rememberPos_ = nullptr;
bool alignOpposite_ = false;
bool draggingBob_ = false;
bool mouseHover_ = false;
float barDragStart_ = 0.0f;
float barDragOffset_ = 0.0f;
+2 -2
View File
@@ -87,7 +87,7 @@ bool UIScreen::key(const KeyInput &key) {
}
bool UIScreen::UnsyncTouch(const TouchInput &touch) {
if (ClickDebug && root_ && (touch.flags & TOUCH_DOWN)) {
if (ClickDebug && root_ && (touch.flags & TouchInputFlags::DOWN)) {
INFO_LOG(Log::System, "Touch down!");
std::vector<UI::View *> views;
root_->Query(touch.x, touch.y, views);
@@ -173,7 +173,7 @@ void UIScreen::update() {
key(ev.key);
break;
case QueuedEventType::TOUCH:
if (ClickDebug && (ev.touch.flags & TOUCH_DOWN)) {
if (ClickDebug && (ev.touch.flags & TouchInputFlags::DOWN)) {
INFO_LOG(Log::System, "Touch down!");
std::vector<UI::View *> views;
root_->Query(ev.touch.x, ev.touch.y, views);
+15 -15
View File
@@ -244,11 +244,11 @@ bool Clickable::Touch(const TouchInput &input) {
}
// Ignore buttons other than the left one.
if ((input.flags & TOUCH_MOUSE) && (input.buttons & 1) == 0) {
if ((input.flags & TouchInputFlags::MOUSE) && (input.buttons & 1) == 0) {
return contains;
}
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
if (bounds_.Contains(input.x, input.y)) {
if (IsFocusMovementEnabled())
SetFocusedView(this);
@@ -258,12 +258,12 @@ bool Clickable::Touch(const TouchInput &input) {
down_ = false;
dragging_ = false;
}
} else if (input.flags & TOUCH_MOVE) {
} else if (input.flags & TouchInputFlags::MOVE) {
if (dragging_)
down_ = bounds_.Contains(input.x, input.y);
}
if (input.flags & TOUCH_UP) {
if ((input.flags & TOUCH_CANCEL) == 0 && dragging_ && bounds_.Contains(input.x, input.y)) {
if (input.flags & TouchInputFlags::UP) {
if ((input.flags & TouchInputFlags::CANCEL) == 0 && dragging_ && bounds_.Contains(input.x, input.y)) {
ClickInternal();
}
down_ = false;
@@ -389,7 +389,7 @@ bool StickyChoice::Touch(const TouchInput &touch) {
return contains;
}
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
if (contains) {
if (IsFocusMovementEnabled())
SetFocusedView(this);
@@ -1163,11 +1163,11 @@ bool ClickableTextView::Touch(const TouchInput &input) {
bool contains = bounds_.Contains(input.x, input.y);
// Ignore buttons other than the left one.
if ((input.flags & TOUCH_MOUSE) && (input.buttons & 1) == 0) {
if ((input.flags & TouchInputFlags::MOUSE) && (input.buttons & 1) == 0) {
return contains;
}
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
if (bounds_.Contains(input.x, input.y)) {
if (IsFocusMovementEnabled())
SetFocusedView(this);
@@ -1177,12 +1177,12 @@ bool ClickableTextView::Touch(const TouchInput &input) {
down_ = false;
dragging_ = false;
}
} else if (input.flags & TOUCH_MOVE) {
} else if (input.flags & TouchInputFlags::MOVE) {
if (dragging_)
down_ = bounds_.Contains(input.x, input.y);
}
if (input.flags & TOUCH_UP) {
if ((input.flags & TOUCH_CANCEL) == 0 && dragging_ && bounds_.Contains(input.x, input.y)) {
if (input.flags & TouchInputFlags::UP) {
if ((input.flags & TouchInputFlags::CANCEL) == 0 && dragging_ && bounds_.Contains(input.x, input.y)) {
EventParams e{};
e.v = this;
OnClick.Trigger(e);
@@ -1279,7 +1279,7 @@ static std::string FirstLine(const std::string &text) {
}
bool TextEdit::Touch(const TouchInput &touch) {
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
if (bounds_.Contains(touch.x, touch.y)) {
SetFocusedView(this, true);
return true;
@@ -1485,20 +1485,20 @@ void Spinner::Draw(UIContext &dc) {
bool TriggerButton::Touch(const TouchInput &input) {
bool contains = bounds_.Contains(input.x, input.y);
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
if (contains) {
down_ |= 1 << input.id;
}
}
if (input.flags & TOUCH_MOVE) {
if (input.flags & TouchInputFlags::MOVE) {
if (contains)
down_ |= 1 << input.id;
else
down_ &= ~(1 << input.id);
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
down_ &= ~(1 << input.id);
}
+1 -1
View File
@@ -109,7 +109,7 @@ bool ViewGroup::Touch(const TouchInput &input) {
if (view->GetVisibility() == V_VISIBLE) {
bool touch = view->Touch(input);
any = any || touch;
if (exclusiveTouch_ && touch && (input.flags & TOUCH_DOWN)) {
if (exclusiveTouch_ && touch && (input.flags & TouchInputFlags::DOWN)) {
break;
}
}
+2 -2
View File
@@ -332,9 +332,9 @@ void UpdateVRInput(bool haptics, float dp_xscale, float dp_yscale) {
bool pressed = IN_VRGetButtonState(mouseController) & ovrButton_Trigger;
if (mousePressed != pressed) {
if (pressed) {
touch.flags = TOUCH_DOWN;
touch.flags = TouchInputFlags::DOWN;
cbNativeTouch(touch);
touch.flags = TOUCH_UP;
touch.flags = TouchInputFlags::UP;
cbNativeTouch(touch);
}
mousePressed = pressed;
+4 -4
View File
@@ -599,14 +599,14 @@ bool MainUI::event(QEvent *e) {
case Qt::TouchPointReleased:
input.x = touchPoint.pos().x() * g_display.dpi_scale_x * xscale;
input.y = touchPoint.pos().y() * g_display.dpi_scale_y * yscale;
input.flags = (touchPoint.state() == Qt::TouchPointPressed) ? TOUCH_DOWN : TOUCH_UP;
input.flags = (touchPoint.state() == Qt::TouchPointPressed) ? TouchInputFlags::DOWN : TouchInputFlags::UP;
input.id = touchPoint.id();
NativeTouch(input);
break;
case Qt::TouchPointMoved:
input.x = touchPoint.pos().x() * g_display.dpi_scale_x * xscale;
input.y = touchPoint.pos().y() * g_display.dpi_scale_y * yscale;
input.flags = TOUCH_MOVE;
input.flags = TouchInputFlags::MOVE;
input.id = touchPoint.id();
NativeTouch(input);
break;
@@ -625,7 +625,7 @@ bool MainUI::event(QEvent *e) {
case Qt::LeftButton:
input.x = ((QMouseEvent*)e)->pos().x() * g_display.dpi_scale_x * xscale;
input.y = ((QMouseEvent*)e)->pos().y() * g_display.dpi_scale_y * yscale;
input.flags = ((e->type() == QEvent::MouseButtonPress) ? TOUCH_DOWN : TOUCH_UP) | TOUCH_MOUSE;
input.flags = ((e->type() == QEvent::MouseButtonPress) ? TouchInputFlags::DOWN : TouchInputFlags::UP) | TouchInputFlags::MOUSE;
input.id = 0;
NativeTouch(input);
break;
@@ -648,7 +648,7 @@ bool MainUI::event(QEvent *e) {
case QEvent::MouseMove:
input.x = ((QMouseEvent*)e)->pos().x() * g_display.dpi_scale_x * xscale;
input.y = ((QMouseEvent*)e)->pos().y() * g_display.dpi_scale_y * yscale;
input.flags = TOUCH_MOVE | TOUCH_MOUSE;
input.flags = TouchInputFlags::MOVE | TouchInputFlags::MOUSE;
input.id = 0;
NativeTouch(input);
break;
+8 -8
View File
@@ -1096,7 +1096,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
input.id = event.tfinger.fingerId;
input.x = event.tfinger.x * w * g_DesktopDPI * g_display.dpi_scale_x;
input.y = event.tfinger.y * h * g_DesktopDPI * g_display.dpi_scale_x;
input.flags = TOUCH_MOVE;
input.flags = TouchInputFlags::MOVE;
input.timestamp = event.tfinger.timestamp;
NativeTouch(input);
break;
@@ -1109,7 +1109,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
input.id = event.tfinger.fingerId;
input.x = event.tfinger.x * w * g_DesktopDPI * g_display.dpi_scale_x;
input.y = event.tfinger.y * h * g_DesktopDPI * g_display.dpi_scale_x;
input.flags = TOUCH_DOWN;
input.flags = TouchInputFlags::DOWN;
input.timestamp = event.tfinger.timestamp;
NativeTouch(input);
@@ -1128,7 +1128,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
input.id = event.tfinger.fingerId;
input.x = event.tfinger.x * w * g_DesktopDPI * g_display.dpi_scale_x;
input.y = event.tfinger.y * h * g_DesktopDPI * g_display.dpi_scale_x;
input.flags = TOUCH_UP;
input.flags = TouchInputFlags::UP;
input.timestamp = event.tfinger.timestamp;
NativeTouch(input);
@@ -1148,7 +1148,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
TouchInput input{};
input.x = mx;
input.y = my;
input.flags = TOUCH_DOWN | TOUCH_MOUSE;
input.flags = TouchInputFlags::DOWN | TouchInputFlags::MOUSE;
input.buttons = 1;
input.id = 0;
NativeTouch(input);
@@ -1162,7 +1162,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
TouchInput input{};
input.x = mx;
input.y = my;
input.flags = TOUCH_DOWN | TOUCH_MOUSE;
input.flags = TouchInputFlags::DOWN | TouchInputFlags::MOUSE;
input.buttons = 2;
input.id = 0;
NativeTouch(input);
@@ -1224,7 +1224,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
TouchInput input{};
input.x = mx;
input.y = my;
input.flags = TOUCH_MOVE | TOUCH_MOUSE;
input.flags = TouchInputFlags::MOVE | TouchInputFlags::MOUSE;
input.buttons = inputTracker->mouseDown;
input.id = 0;
NativeTouch(input);
@@ -1241,7 +1241,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
TouchInput input{};
input.x = mx;
input.y = my;
input.flags = TOUCH_UP | TOUCH_MOUSE;
input.flags = TouchInputFlags::UP | TouchInputFlags::MOUSE;
input.buttons = 1;
NativeTouch(input);
KeyInput key(DEVICE_ID_MOUSE, NKCODE_EXT_MOUSEBUTTON_1, KEY_UP);
@@ -1256,7 +1256,7 @@ static void ProcessSDLEvent(SDL_Window *window, const SDL_Event &event, InputSta
TouchInput input{};
input.x = mx;
input.y = my;
input.flags = TOUCH_UP | TOUCH_MOUSE;
input.flags = TouchInputFlags::UP | TouchInputFlags::MOUSE;
input.buttons = 2;
NativeTouch(input);
KeyInput key(DEVICE_ID_MOUSE, NKCODE_EXT_MOUSEBUTTON_2, KEY_UP);
+10 -10
View File
@@ -96,9 +96,9 @@ checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a"
[[package]]
name = "bumpalo"
version = "3.19.0"
version = "3.19.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "46c5e41b57b8bba42a04676d81cb89e9ee8e859a1a66f80a5a72e1cb76b34d43"
checksum = "5dd9dc738b7a8311c7ade152424974d8115f2cdad61e8dab8dac9f2362298510"
[[package]]
name = "bytes"
@@ -998,9 +998,9 @@ checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f"
[[package]]
name = "reqwest"
version = "0.12.25"
version = "0.12.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b6eff9328d40131d43bd911d42d79eb6a47312002a4daefc9e37f17e74a7701a"
checksum = "3b4c14b2d9afca6a60277086b0cc6a6ae0b568f6f7916c943a8cdc79f8be240f"
dependencies = [
"base64",
"bytes",
@@ -1080,9 +1080,9 @@ dependencies = [
[[package]]
name = "rustls-pki-types"
version = "1.13.1"
version = "1.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "708c0f9d5f54ba0272468c1d306a52c495b31fa155e91bc25371e6df7996908c"
checksum = "21e6f2ab2928ca4291b86736a8bd920a277a399bba1589409d72154ff87c1282"
dependencies = [
"zeroize",
]
@@ -1449,9 +1449,9 @@ checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3"
[[package]]
name = "tracing"
version = "0.1.43"
version = "0.1.44"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2d15d90a0b5c19378952d479dc858407149d7bb45a14de0142f6c534b16fc647"
checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100"
dependencies = [
"pin-project-lite",
"tracing-core",
@@ -1459,9 +1459,9 @@ dependencies = [
[[package]]
name = "tracing-core"
version = "0.1.35"
version = "0.1.36"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7a04e24fab5c89c6a36eb8558c9656f30d81de51dfa4d3b45f26b21d61fa0a6c"
checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a"
dependencies = [
"once_cell",
]
+8 -8
View File
@@ -57,8 +57,8 @@ enum Command {
key: String,
},
CopyKey {
old: String,
new: String,
old_section: String,
new_section: String,
key: String,
},
DupeKey {
@@ -789,11 +789,11 @@ fn execute_command(cmd: Command, ai: Option<&ChatGPT>, dry_run: bool, verbose: b
}
Command::CopyKey {
// Copies between sections
ref old,
ref new,
ref old_section,
ref new_section,
ref key,
} => {
copy_key(&mut target_ini, old, new, key).unwrap();
copy_key(&mut target_ini, old_section, new_section, key).unwrap();
}
Command::DupeKey {
ref section,
@@ -904,11 +904,11 @@ fn execute_command(cmd: Command, ai: Option<&ChatGPT>, dry_run: bool, verbose: b
}
Command::CopyKey {
// between sections
ref old,
ref new,
ref old_section,
ref new_section,
ref key,
} => {
copy_key(&mut reference_ini, old, new, key).unwrap();
copy_key(&mut reference_ini, old_section, new_section, key).unwrap();
}
Command::DupeKey {
// Inside a section, preserving a value
+3 -3
View File
@@ -605,7 +605,7 @@ void FrameDumpTestScreen::update() {
void TouchTestScreen::touch(const TouchInput &touch) {
UIBaseDialogScreen::touch(touch);
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
bool found = false;
for (int i = 0; i < MAX_TOUCH_POINTS; i++) {
if (touches_[i].id == touch.id) {
@@ -626,7 +626,7 @@ void TouchTestScreen::touch(const TouchInput &touch) {
}
}
}
if (touch.flags & TOUCH_MOVE) {
if (touch.flags & TouchInputFlags::MOVE) {
bool found = false;
for (int i = 0; i < MAX_TOUCH_POINTS; i++) {
if (touches_[i].id == touch.id) {
@@ -639,7 +639,7 @@ void TouchTestScreen::touch(const TouchInput &touch) {
WARN_LOG(Log::System, "Move with buttons %d without touch down: %d", touch.buttons, touch.id);
}
}
if (touch.flags & TOUCH_UP) {
if (touch.flags & TouchInputFlags::UP) {
bool found = false;
for (int i = 0; i < MAX_TOUCH_POINTS; i++) {
if (touches_[i].id == touch.id) {
+3 -3
View File
@@ -68,7 +68,7 @@ public:
DisplayLayoutConfig &config = g_Config.GetDisplayLayoutConfig(orientation_);
if ((touch.flags & TOUCH_MOVE) != 0 && dragging_) {
if ((touch.flags & TouchInputFlags::MOVE) != 0 && dragging_) {
float relativeTouchX = touch.x - startX_;
float relativeTouchY = touch.y - startY_;
@@ -87,7 +87,7 @@ public:
}
}
if ((touch.flags & TOUCH_DOWN) != 0 && !dragging_) {
if ((touch.flags & TouchInputFlags::DOWN) != 0 && !dragging_) {
// Check that we're in the central 80% of the screen.
// If outside, it may be a drag from displaying the back button on phones
// where you have to drag from the side, etc.
@@ -102,7 +102,7 @@ public:
}
}
if ((touch.flags & TOUCH_UP) != 0 && dragging_) {
if ((touch.flags & TouchInputFlags::UP) != 0 && dragging_) {
dragging_ = false;
}
+3 -3
View File
@@ -680,7 +680,7 @@ bool EmuScreen::UnsyncTouch(const TouchInput &touch) {
}
}
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
if (!(g_Config.bShowImDebugger && imguiInited_) && !ignoreGamepad) {
// This just prevents the gamepad from timing out.
GamepadTouch();
@@ -1166,7 +1166,7 @@ void EmuScreen::touch(const TouchInput &touch) {
if (!ImGui::GetIO().WantCaptureMouse) {
UIScreen::touch(touch);
}
} else if (g_Config.bMouseControl && !(touch.flags & TOUCH_UP) && (touch.flags & TOUCH_MOUSE)) {
} else if (g_Config.bMouseControl && !(touch.flags & TouchInputFlags::UP) && (touch.flags & TouchInputFlags::MOUSE)) {
// don't do anything as the mouse pointer is hidden in this case.
// But we let touch-up events through to avoid getting stuck if the user toggles mouse control.
} else {
@@ -1174,7 +1174,7 @@ void EmuScreen::touch(const TouchInput &touch) {
if (chatMenu_ && chatMenu_->GetVisibility() == UI::V_VISIBLE) {
// Avoid pressing touch button behind the chat
if (!chatMenu_->Contains(touch.x, touch.y)) {
if ((touch.flags & TOUCH_DOWN) != 0) {
if ((touch.flags & TouchInputFlags::DOWN) != 0) {
chatMenu_->Close();
if (chatButton_)
chatButton_->SetVisibility(UI::V_VISIBLE);
+21 -21
View File
@@ -111,14 +111,14 @@ bool MultiTouchButton::Touch(const TouchInput &input) {
_dbg_assert_(input.id >= 0 && input.id < TOUCH_MAX_POINTERS);
bool retval = GamepadView::Touch(input);
if ((input.flags & TOUCH_DOWN) && bounds_.Contains(input.x, input.y)) {
if ((input.flags & TouchInputFlags::DOWN) && bounds_.Contains(input.x, input.y)) {
pointerDownMask_ |= 1 << input.id;
usedPointerMask |= 1 << input.id;
if (CanGlide() && !primaryButton[input.id])
primaryButton[input.id] = this;
}
if (input.flags & TOUCH_MOVE) {
if (!(input.flags & TOUCH_MOUSE) || input.buttons) {
if (input.flags & TouchInputFlags::MOVE) {
if (!(input.flags & TouchInputFlags::MOUSE) || input.buttons) {
if (bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id))) {
if (CanGlide() && !primaryButton[input.id]) {
primaryButton[input.id] = this;
@@ -129,12 +129,12 @@ bool MultiTouchButton::Touch(const TouchInput &input) {
}
}
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
pointerDownMask_ &= ~(1 << input.id);
usedPointerMask &= ~(1 << input.id);
primaryButton[input.id] = nullptr;
}
if (input.flags & TOUCH_RELEASE_ALL) {
if (input.flags & TouchInputFlags::RELEASE_ALL) {
pointerDownMask_ = 0;
usedPointerMask = 0;
}
@@ -304,15 +304,15 @@ void PSPDpad::GetContentDimensions(const UIContext &dc, float &w, float &h) cons
bool PSPDpad::Touch(const TouchInput &input) {
bool retval = GamepadView::Touch(input);
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
if (dragPointerId_ == -1 && bounds_.Contains(input.x, input.y)) {
dragPointerId_ = input.id;
usedPointerMask |= 1 << input.id;
ProcessTouch(input.x, input.y, true);
}
}
if (input.flags & TOUCH_MOVE) {
if (!(input.flags & TOUCH_MOUSE) || input.buttons) {
if (input.flags & TouchInputFlags::MOVE) {
if (!(input.flags & TouchInputFlags::MOUSE) || input.buttons) {
if (dragPointerId_ == -1 && bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id))) {
dragPointerId_ = input.id;
}
@@ -321,7 +321,7 @@ bool PSPDpad::Touch(const TouchInput &input) {
}
}
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
if (input.id == dragPointerId_) {
dragPointerId_ = -1;
usedPointerMask &= ~(1 << input.id);
@@ -475,7 +475,7 @@ void PSPStick::Draw(UIContext &dc) {
bool PSPStick::Touch(const TouchInput &input) {
bool retval = GamepadView::Touch(input);
if (input.flags & TOUCH_RELEASE_ALL) {
if (input.flags & TouchInputFlags::RELEASE_ALL) {
dragPointerId_ = -1;
centerX_ = bounds_.centerX();
centerY_ = bounds_.centerY();
@@ -484,7 +484,7 @@ bool PSPStick::Touch(const TouchInput &input) {
analogPointerMask = 0;
return retval;
}
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
const TouchControlConfig &config = g_Config.GetTouchControlsConfig(g_display.GetDeviceOrientation());
float fac = 0.5f * (stick_ ? config.fRightStickHeadScale : config.fLeftStickHeadScale)-0.5f;
if (dragPointerId_ == -1 && bounds_.Expand(bounds_.w*fac, bounds_.h*fac).Contains(input.x, input.y)) {
@@ -502,13 +502,13 @@ bool PSPStick::Touch(const TouchInput &input) {
retval = true;
}
}
if (input.flags & TOUCH_MOVE) {
if (input.flags & TouchInputFlags::MOVE) {
if (input.id == dragPointerId_) {
ProcessTouch(input.x, input.y, true);
retval = true;
}
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
if (input.id == dragPointerId_) {
dragPointerId_ = -1;
centerX_ = bounds_.centerX();
@@ -586,7 +586,7 @@ void PSPCustomStick::Draw(UIContext &dc) {
bool PSPCustomStick::Touch(const TouchInput &input) {
bool retval = GamepadView::Touch(input);
if (input.flags & TOUCH_RELEASE_ALL) {
if (input.flags & TouchInputFlags::RELEASE_ALL) {
dragPointerId_ = -1;
centerX_ = bounds_.centerX();
centerY_ = bounds_.centerY();
@@ -596,7 +596,7 @@ bool PSPCustomStick::Touch(const TouchInput &input) {
analogPointerMask = 0;
return false;
}
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
const TouchControlConfig &config = g_Config.GetTouchControlsConfig(g_display.GetDeviceOrientation());
float fac = 0.5f * config.fRightStickHeadScale - 0.5f;
if (dragPointerId_ == -1 && bounds_.Expand(bounds_.w*fac, bounds_.h*fac).Contains(input.x, input.y)) {
@@ -614,13 +614,13 @@ bool PSPCustomStick::Touch(const TouchInput &input) {
retval = true;
}
}
if (input.flags & TOUCH_MOVE) {
if (input.flags & TouchInputFlags::MOVE) {
if (input.id == dragPointerId_) {
ProcessTouch(input.x, input.y, true);
retval = true;
}
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
if (input.id == dragPointerId_) {
dragPointerId_ = -1;
centerX_ = bounds_.centerX();
@@ -1034,12 +1034,12 @@ bool GestureGamepad::Touch(const TouchInput &input) {
return false;
}
if (input.flags & TOUCH_RELEASE_ALL) {
if (input.flags & TouchInputFlags::RELEASE_ALL) {
dragPointerId_ = -1;
return false;
}
if (input.flags & TOUCH_DOWN) {
if (input.flags & TouchInputFlags::DOWN) {
if (dragPointerId_ == -1) {
dragPointerId_ = input.id;
lastX_ = input.x;
@@ -1056,7 +1056,7 @@ bool GestureGamepad::Touch(const TouchInput &input) {
lastTouchDown_ = now;
}
}
if (input.flags & TOUCH_MOVE) {
if (input.flags & TouchInputFlags::MOVE) {
if (input.id == dragPointerId_) {
deltaX_ += input.x - lastX_;
deltaY_ += input.y - lastY_;
@@ -1073,7 +1073,7 @@ bool GestureGamepad::Touch(const TouchInput &input) {
}
}
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
if (input.id == dragPointerId_) {
dragPointerId_ = -1;
if (time_now_d() - lastTouchDown_ < 0.3f)
+2 -2
View File
@@ -139,10 +139,10 @@ public:
bool Touch(const TouchInput &input) override {
bool retval = UI::Clickable::Touch(input);
hovering_ = bounds_.Contains(input.x, input.y);
if (hovering_ && (input.flags & TOUCH_DOWN)) {
if (hovering_ && (input.flags & TouchInputFlags::DOWN)) {
holdStart_ = time_now_d();
}
if (input.flags & TOUCH_UP) {
if (input.flags & TouchInputFlags::UP) {
holdStart_ = 0;
}
return retval;
+4 -4
View File
@@ -417,7 +417,7 @@ bool LogoScreen::key(const KeyInput &key) {
}
void LogoScreen::touch(const TouchInput &touch) {
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
Next();
}
}
@@ -482,14 +482,14 @@ public:
bool Touch(const TouchInput &touch) override {
if (touch.id != 0)
return false;
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
dragYStart_ = touch.y;
dragYOffsetStart_ = dragOffset_;
}
if (touch.flags & TOUCH_UP) {
if (touch.flags & TouchInputFlags::UP) {
dragYStart_ = -1.0f;
}
if (touch.flags & TOUCH_MOVE) {
if (touch.flags & TouchInputFlags::MOVE) {
if (dragYStart_ >= 0.0f) {
dragOffset_ = dragYOffsetStart_ + (touch.y - dragYStart_);
}
+1 -1
View File
@@ -153,7 +153,7 @@ PaneTitleBar::PaneTitleBar(const Path &gamePath, std::string_view title, const s
} else {
settingsUrl = join("https://www.ppsspp.org/docs/settings/", settingsCategory);
}
Choice *helpButton = Add(new Choice(ImageID("I_INFO"), new LinearLayoutParams()));
Choice *helpButton = Add(new Choice(ImageID("I_LINK_OUT_QUESTION"), new LinearLayoutParams()));
helpButton->OnClick.Add([settingsUrl](UI::EventParams &) {
System_LaunchUrl(LaunchUrlType::BROWSER_URL, settingsUrl);
});
+1 -1
View File
@@ -544,7 +544,7 @@ bool OnScreenMessagesView::Dismiss(float x, float y) {
bool OSDOverlayScreen::UnsyncTouch(const TouchInput &touch) {
// Don't really need to forward.
// UIScreen::UnsyncTouch(touch);
if ((touch.flags & TOUCH_DOWN) && osmView_) {
if ((touch.flags & TouchInputFlags::DOWN) && osmView_) {
return osmView_->Dismiss(touch.x, touch.y);
} else {
return false;
+20 -6
View File
@@ -13,11 +13,25 @@ void UISimpleBaseDialogScreen::CreateViews() {
const bool portrait = GetDeviceOrientation() == DeviceOrientation::Portrait;
root_ = new LinearLayout(ORIENT_VERTICAL, new LayoutParams(FILL_PARENT, FILL_PARENT));
root_->Add(new TopBar(*screenManager()->getUIContext(), portrait ? TopBarFlags::Portrait : TopBarFlags::Default, GetTitle()));
TopBarFlags topBarFlags = portrait ? TopBarFlags::Portrait : TopBarFlags::Default;
if (flags_ & SimpleDialogFlags::CustomContextMenu) {
topBarFlags |= TopBarFlags::ContextMenuButton;
}
TopBar *topBar = root_->Add(new TopBar(*screenManager()->getUIContext(), topBarFlags, GetTitle()));
if (flags_ & SimpleDialogFlags::CustomContextMenu) {
View *menuButton = topBar->GetContextMenuButton();
topBar->OnContextMenuClick.Add([this, menuButton](UI::EventParams &e) {
this->screenManager()->push(new PopupCallbackScreen([this](UI::ViewGroup *parent) {
CreateContextMenu(parent);
}, menuButton));
});
}
if (canScroll) {
ScrollView *scroll = new ScrollView(ORIENT_VERTICAL, new LinearLayoutParams(FILL_PARENT, FILL_PARENT, 1.0f));
LinearLayout *contents = new LinearLayoutList(ORIENT_VERTICAL);
LinearLayout *contents = new LinearLayoutList(ORIENT_VERTICAL, new LinearLayoutParams(Margins(0, 0, 8, 0)));
contents->SetSpacing(0);
CreateDialogViews(contents);
scroll->Add(contents);
@@ -120,12 +134,12 @@ void UITwoPaneBaseDialogScreen::CreateViews() {
root->Add(columns);
// root_->Add(new TopBar(*screenManager()->getUIContext(), portrait, GetTitle(), new LayoutParams(FILL_PARENT, FILL_PARENT)));
ScrollView *settingsScroll = new ScrollView(ORIENT_VERTICAL, new LinearLayoutParams(SettingsWidth(), FILL_PARENT, 0.0f, Margins(8)));
LinearLayout *settingsPane = new LinearLayout(ORIENT_VERTICAL, new LinearLayoutParams(FILL_PARENT));
ScrollView *settingsScroll = new ScrollView(ORIENT_VERTICAL, new LinearLayoutParams(SettingsWidth(), FILL_PARENT, 0.0f, Margins(0, 8, 0, 0)));
LinearLayout *settingsPane = new LinearLayout(ORIENT_VERTICAL, new LinearLayoutParams(FILL_PARENT, Margins(0, 8, 0, 0)));
settingsPane->SetSpacing(0.0f);
CreateSettingsViews(settingsPane);
settingsPane->Add(new BorderView(BORDER_BOTTOM, BorderStyle::HEADER_FG, 2.0f, new LayoutParams(FILL_PARENT, 40.0f)));
settingsPane->Add(new Choice(di->T("Back"), ImageID("I_NAVIGATE_BACK")))->OnClick.Handle<UIScreen>(this, &UIScreen::OnBack);
// settingsPane->Add(new BorderView(BORDER_BOTTOM, BorderStyle::HEADER_FG, 2.0f, new LayoutParams(FILL_PARENT, 40.0f)));
// settingsPane->Add(new Choice(di->T("Back"), ImageID("I_NAVIGATE_BACK")))->OnClick.Handle<UIScreen>(this, &UIScreen::OnBack);
settingsScroll->Add(settingsPane);
if (flags_ & TwoPaneFlags::SettingsToTheRight) {
+2
View File
@@ -7,6 +7,7 @@
enum class SimpleDialogFlags {
Default = 0,
CustomContextMenu = 1,
ContentsCanScroll = 8,
};
ENUM_CLASS_BITOPS(SimpleDialogFlags);
@@ -22,6 +23,7 @@ public:
// Override this, don't override CreateViews. And don't touch root_ directly.
virtual void CreateDialogViews(UI::ViewGroup *parent) = 0;
virtual void CreateContextMenu(UI::ViewGroup *parent) {} // only called if CustomContextMenu is set in flags.
virtual std::string_view GetTitle() const { return ""; }
private:
+12 -9
View File
@@ -24,6 +24,7 @@
#include "UI/SystemInfoScreen.h"
#include "UI/IconCache.h"
#include "UI/BaseScreens.h"
#include "UI/MiscViews.h"
#include "UI/OnScreenDisplay.h"
#include "android/jni/app-android.h"
@@ -110,6 +111,8 @@ void SystemInfoScreen::CreateDeviceInfoTab(UI::LinearLayout *deviceSpecs) {
auto si = GetI18NCategory(I18NCat::SYSINFO);
auto gr = GetI18NCategory(I18NCat::GRAPHICS);
deviceSpecs->Add(new TopBar(*screenManager()->getUIContext(), TopBarFlags::Default, si->T("Device Info")));
UI::CollapsibleSection *systemInfo = deviceSpecs->Add(new UI::CollapsibleSection(si->T("System Information")));
systemInfo->Add(new Choice(si->T("Copy summary to clipboard"), ImageID("I_FILE_COPY")))->OnClick.Handle(this, &SystemInfoScreen::CopySummaryToClipboard);
@@ -411,12 +414,12 @@ void SystemInfoScreen::CreateDriverBugsTab(UI::LinearLayout *driverBugs) {
for (int i = 0; i < (int)draw->GetBugs().MaxBugIndex(); i++) {
if (draw->GetBugs().Has(i)) {
anyDriverBugs = true;
driverBugs->Add(new TextView(draw->GetBugs().GetBugName(i), new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
driverBugs->Add(new InfoItem(draw->GetBugs().GetBugName(i), "", new LayoutParams(FILL_PARENT, WRAP_CONTENT)));
}
}
if (!anyDriverBugs) {
driverBugs->Add(new TextView(si->T("No GPU driver bugs detected"), new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
driverBugs->Add(new InfoItem(si->T("No GPU driver bugs detected"), "", new LayoutParams(FILL_PARENT, WRAP_CONTENT)));
}
}
@@ -463,38 +466,38 @@ void SystemInfoScreen::CreateVulkanExtsTab(UI::LinearLayout *gpuExtensions) {
CollapsibleSection *vulkanFeatures = gpuExtensions->Add(new CollapsibleSection(si->T("Vulkan Features")));
std::vector<std::string> features = draw->GetFeatureList();
for (const auto &feature : features) {
vulkanFeatures->Add(new TextView(feature, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
vulkanFeatures->Add(new TextView(feature, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
CollapsibleSection *presentModes = gpuExtensions->Add(new CollapsibleSection(si->T("Present modes")));
for (const auto &mode : draw->GetPresentModeList(di->T("Current"))) {
presentModes->Add(new TextView(mode, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
presentModes->Add(new TextView(mode, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
CollapsibleSection *colorFormats = gpuExtensions->Add(new CollapsibleSection(si->T("Display Color Formats")));
for (const auto &format : draw->GetSurfaceFormatList()) {
colorFormats->Add(new TextView(format, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
colorFormats->Add(new TextView(format, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
CollapsibleSection *enabledExtensions = gpuExtensions->Add(new CollapsibleSection(std::string(si->T("Vulkan Extensions")) + " (" + std::string(di->T("Enabled")) + ")"));
std::vector<std::string> extensions = draw->GetExtensionList(true, true);
std::sort(extensions.begin(), extensions.end());
for (auto &extension : extensions) {
enabledExtensions->Add(new TextView(extension, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
enabledExtensions->Add(new TextView(extension, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
// Also get instance extensions
enabledExtensions->Add(new ItemHeader(si->T("Instance")));
extensions = draw->GetExtensionList(false, true);
std::sort(extensions.begin(), extensions.end());
for (auto &extension : extensions) {
enabledExtensions->Add(new TextView(extension, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
enabledExtensions->Add(new TextView(extension, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
CollapsibleSection *vulkanExtensions = gpuExtensions->Add(new CollapsibleSection(si->T("Vulkan Extensions")));
extensions = draw->GetExtensionList(true, false);
std::sort(extensions.begin(), extensions.end());
for (auto &extension : extensions) {
vulkanExtensions->Add(new TextView(extension, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
vulkanExtensions->Add(new TextView(extension, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
vulkanExtensions->Add(new ItemHeader(si->T("Instance")));
@@ -502,6 +505,6 @@ void SystemInfoScreen::CreateVulkanExtsTab(UI::LinearLayout *gpuExtensions) {
extensions = draw->GetExtensionList(false, false);
std::sort(extensions.begin(), extensions.end());
for (auto &extension : extensions) {
vulkanExtensions->Add(new TextView(extension, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
vulkanExtensions->Add(new TextView(extension, FLAG_DYNAMIC_ASCII, true, new LayoutParams(FILL_PARENT, WRAP_CONTENT)))->SetFocusable(true);
}
}
+2 -2
View File
@@ -26,7 +26,7 @@ void UITabbedBaseDialogScreen::AddTab(const char *tag, std::string_view title, I
scroll = new ScrollView(ORIENT_VERTICAL, new LinearLayoutParams(FILL_PARENT, FILL_PARENT));
scroll->SetTag(tag);
}
LinearLayout *contents = new LinearLayoutList(ORIENT_VERTICAL);
LinearLayout *contents = new LinearLayoutList(ORIENT_VERTICAL, new LinearLayoutParams(Margins(0, 0, 8, 0)));
contents->SetSpacing(0);
if (dialogFlags & TabDialogFlags::AddAutoTitles) {
@@ -87,7 +87,7 @@ void UITabbedBaseDialogScreen::CreateViews() {
if (flags_ & TabDialogFlags::VerticalShowIcons) {
tabHolderFlags |= TabHolderFlags::VerticalShowIcons;
}
tabHolder_ = new TabHolder(ORIENT_VERTICAL, 300, tabHolderFlags, filterNotice_, nullptr, new AnchorLayoutParams(10, 0, 10, 0));
tabHolder_ = new TabHolder(ORIENT_VERTICAL, 300, tabHolderFlags, filterNotice_, nullptr, new AnchorLayoutParams(10, 0, 0, 0));
CreateExtraButtons(tabHolder_->Container(), 10);
tabHolder_->AddBack(this);
root_->Add(tabHolder_);
+3 -3
View File
@@ -386,7 +386,7 @@ static Point2D ClampTo(const Point2D &p, const Bounds &b) {
bool ControlLayoutView::Touch(const TouchInput &touch) {
using namespace UI;
if ((touch.flags & TOUCH_MOVE) && pickedControl_ != nullptr) {
if ((touch.flags & TouchInputFlags::MOVE) && pickedControl_ != nullptr) {
if (mode_ == 0) {
// Allow placing the control halfway outside the play area.
@@ -435,7 +435,7 @@ bool ControlLayoutView::Touch(const TouchInput &touch) {
pickedControl_->SetScale(newScale);
}
}
if ((touch.flags & TOUCH_DOWN) && pickedControl_ == 0) {
if ((touch.flags & TouchInputFlags::DOWN) && pickedControl_ == 0) {
pickedControl_ = getPickedControl(touch.x, touch.y);
if (pickedControl_) {
startDragX_ = touch.x;
@@ -448,7 +448,7 @@ bool ControlLayoutView::Touch(const TouchInput &touch) {
startScale_ = pickedControl_->GetScale();
}
}
if ((touch.flags & TOUCH_UP) && pickedControl_ != 0) {
if ((touch.flags & TouchInputFlags::UP) && pickedControl_ != 0) {
pickedControl_->SavePosition();
pickedControl_ = 0;
}
+2 -2
View File
@@ -51,7 +51,7 @@ std::string_view TouchControlVisibilityScreen::GetTitle() const {
return co->T("Touch Control Visibility");
}
void TouchControlVisibilityScreen::CreateSettingsViews(UI::ViewGroup *parent) {
void TouchControlVisibilityScreen::CreateContextMenu(UI::ViewGroup *parent) {
using namespace UI;
auto di = GetI18NCategory(I18NCat::DIALOG);
@@ -66,7 +66,7 @@ void TouchControlVisibilityScreen::CreateSettingsViews(UI::ViewGroup *parent) {
});
}
void TouchControlVisibilityScreen::CreateContentViews(UI::ViewGroup *parent) {
void TouchControlVisibilityScreen::CreateDialogViews(UI::ViewGroup *parent) {
using namespace UI;
using namespace CustomKeyData;
+4 -4
View File
@@ -34,11 +34,11 @@ struct TouchButtonToggle {
std::function<void(UI::EventParams&)> handle;
};
class TouchControlVisibilityScreen : public UITwoPaneBaseDialogScreen {
class TouchControlVisibilityScreen : public UISimpleBaseDialogScreen {
public:
TouchControlVisibilityScreen(const Path &gamePath) : UITwoPaneBaseDialogScreen(gamePath, TwoPaneFlags::SettingsInContextMenu | TwoPaneFlags::ContentsCanScroll) {}
void CreateContentViews(UI::ViewGroup *parent) override;
void CreateSettingsViews(UI::ViewGroup *parent) override;
TouchControlVisibilityScreen(const Path &gamePath) : UISimpleBaseDialogScreen(gamePath, SimpleDialogFlags::ContentsCanScroll | SimpleDialogFlags::CustomContextMenu) {}
void CreateDialogViews(UI::ViewGroup *parent) override;
void CreateContextMenu(UI::ViewGroup *parent) override;
void onFinish(DialogResult result) override;
const char *tag() const override { return "TouchControlVisibility"; }
+1
View File
@@ -171,6 +171,7 @@ static const ImageMeta imageIDs[] = {
{"I_DEVICE_ROTATION_PORTRAIT", false},
{"I_MOVE", false},
{"I_RESIZE", false},
{"I_LINK_OUT_QUESTION", false},
};
static std::string PNGNameFromID(std::string_view id) {
+3 -3
View File
@@ -203,7 +203,7 @@ void App::OnPointerMoved(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Cor
float X = args->CurrentPoint->Position.X;
float Y = args->CurrentPoint->Position.Y;
int64_t timestamp = args->CurrentPoint->Timestamp;
m_main->OnTouchEvent(TOUCH_MOVE, pointerId, X, Y, (double)timestamp);
m_main->OnTouchEvent(TouchInputFlags::MOVE, pointerId, X, Y, (double)timestamp);
}
void App::OnPointerEntered(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::PointerEventArgs^ args) {
@@ -220,7 +220,7 @@ void App::OnPointerPressed(Windows::UI::Core::CoreWindow^ sender, Windows::UI::C
float X = args->CurrentPoint->Position.X;
float Y = args->CurrentPoint->Position.Y;
int64_t timestamp = args->CurrentPoint->Timestamp;
m_main->OnTouchEvent(TOUCH_DOWN|TOUCH_MOVE, pointerId, X, Y, (double)timestamp);
m_main->OnTouchEvent(TouchInputFlags::DOWN|TouchInputFlags::MOVE, pointerId, X, Y, (double)timestamp);
if (!m_isPhone) {
sender->SetPointerCapture();
}
@@ -233,7 +233,7 @@ void App::OnPointerReleased(Windows::UI::Core::CoreWindow^ sender, Windows::UI::
float X = args->CurrentPoint->Position.X;
float Y = args->CurrentPoint->Position.Y;
int64_t timestamp = args->CurrentPoint->Timestamp;
m_main->OnTouchEvent(TOUCH_UP|TOUCH_MOVE, pointerId, X, Y, (double)timestamp);
m_main->OnTouchEvent(TouchInputFlags::UP|TouchInputFlags::MOVE, pointerId, X, Y, (double)timestamp);
if (!m_isPhone) {
sender->ReleasePointerCapture();
}
+2 -2
View File
@@ -282,12 +282,12 @@ void PPSSPP_UWPMain::OnTouchEvent(int touchEvent, int touchId, float x, float y,
KeyInput key{};
key.deviceId = DEVICE_ID_MOUSE;
if (touchEvent & TOUCH_DOWN) {
if (touchEvent & TouchInputFlags::DOWN) {
key.keyCode = NKCODE_EXT_MOUSEBUTTON_1;
key.flags = KEY_DOWN;
NativeKey(key);
}
if (touchEvent & TOUCH_UP) {
if (touchEvent & TouchInputFlags::UP) {
key.keyCode = NKCODE_EXT_MOUSEBUTTON_1;
key.flags = KEY_UP;
NativeKey(key);
+5 -5
View File
@@ -1142,7 +1142,7 @@ namespace MainWindow
WindowsRawInput::SetMousePos(x, y);
TouchInput touch{};
touch.flags = TOUCH_DOWN | TOUCH_MOUSE;
touch.flags = TouchInputFlags::DOWN | TouchInputFlags::MOUSE;
touch.buttons = 1;
touch.x = x;
touch.y = y;
@@ -1191,7 +1191,7 @@ namespace MainWindow
// Mouse moves now happen also when no button is pressed.
TouchInput touch{};
touch.flags = TOUCH_MOVE | TOUCH_MOUSE;
touch.flags = TouchInputFlags::MOVE | TouchInputFlags::MOUSE;
if (wParam & MK_LBUTTON) {
touch.buttons |= 1;
}
@@ -1217,7 +1217,7 @@ namespace MainWindow
TouchInput touch{};
touch.buttons = 1;
touch.flags = TOUCH_UP | TOUCH_MOUSE;
touch.flags = TouchInputFlags::UP | TouchInputFlags::MOUSE;
touch.x = x;
touch.y = y;
NativeTouch(touch);
@@ -1236,7 +1236,7 @@ namespace MainWindow
TouchInput touch{};
touch.buttons = 2;
touch.flags = TOUCH_DOWN | TOUCH_MOUSE;
touch.flags = TouchInputFlags::DOWN | TouchInputFlags::MOUSE;
touch.x = x;
touch.y = y;
NativeTouch(touch);
@@ -1250,7 +1250,7 @@ namespace MainWindow
TouchInput touch{};
touch.buttons = 2;
touch.flags = TOUCH_UP | TOUCH_MOUSE;
touch.flags = TouchInputFlags::UP | TouchInputFlags::MOUSE;
touch.x = x;
touch.y = y;
NativeTouch(touch);
+1 -1
View File
@@ -308,7 +308,7 @@ namespace WindowsRawInput {
TouchInput touch;
touch.id = 0;
touch.flags = TOUCH_MOVE;
touch.flags = TouchInputFlags::MOVE;
touch.x = mouseX;
touch.y = mouseY;
+3 -3
View File
@@ -116,7 +116,7 @@ void TouchInputHandler::touchUp(int id, float x, float y){
touchevent.id = id;
touchevent.x = x;
touchevent.y = y;
touchevent.flags = TOUCH_UP;
touchevent.flags = TouchInputFlags::UP;
NativeTouch(touchevent);
}
@@ -125,7 +125,7 @@ void TouchInputHandler::touchDown(int id, float x, float y){
touchevent.id = id;
touchevent.x = x;
touchevent.y = y;
touchevent.flags = TOUCH_DOWN;
touchevent.flags = TouchInputFlags::DOWN;
NativeTouch(touchevent);
}
@@ -134,7 +134,7 @@ void TouchInputHandler::touchMove(int id, float x, float y){
touchevent.id = id;
touchevent.x = x;
touchevent.y = y;
touchevent.flags = TOUCH_MOVE;
touchevent.flags = TouchInputFlags::MOVE;
NativeTouch(touchevent);
}
+3 -3
View File
@@ -1319,7 +1319,7 @@ extern "C" jboolean Java_org_ppsspp_ppsspp_NativeApp_mouse(
if (button == 0) {
// It's a pure mouse move.
input.flags = TOUCH_MOUSE | TOUCH_MOVE;
input.flags = TouchInputFlags::MOUSE | TouchInputFlags::MOVE;
input.x = x;
input.y = y;
input.id = 0;
@@ -1329,10 +1329,10 @@ extern "C" jboolean Java_org_ppsspp_ppsspp_NativeApp_mouse(
input.y = y;
switch (action) {
case 1:
input.flags = TOUCH_MOUSE | TOUCH_DOWN;
input.flags = TouchInputFlags::MOUSE | TouchInputFlags::DOWN;
break;
case 2:
input.flags = TOUCH_MOUSE | TOUCH_UP;
input.flags = TouchInputFlags::MOUSE | TouchInputFlags::UP;
break;
}
input.id = 0;
+1
View File
@@ -408,6 +408,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = إفتراضي
Delete = ‎مسح
Delete all = ‎مسح الكل
Delete completed = ‎المسح إكتمل.
+1
View File
@@ -404,6 +404,7 @@ ConnectionName = Qoşulma adı
Copied to clipboard: %1 = Kəsintiliyə köçürüldü: %1
Copy to clipboard = Kəsintiliyə köçürt
Corrupted Data = Korlanmış verilən
Default = Varsayılan
Delete = Sil
Delete all = Hamısını sil
Delete completed = Siliniş tamamlandı
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Па змаўчанні
Delete = Delete
Delete all = Delete all
Delete completed = Delete completed.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Копиране в клипборда
Corrupted Data = Повредени данни
Default = По подразбиране
Delete = Изтрий
Delete all = Изтрий всички
Delete completed = Изтриването завършето.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Nom de la connexió
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Dades corruptes
Default = Per defecte
Delete = Eliminar
Delete all = Eliminar tot
Delete completed = Esborrat completat
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Smazat
Delete all = Smazat vše
Delete completed = Mazání dokončeno.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Slet
Delete all = Slet alt
Delete completed = Slettet.
+1
View File
@@ -392,6 +392,7 @@ ConnectionName = Verbindungsname
Copied to clipboard: %1 = In Zwischenablage kopiert: %1
Copy to clipboard = In Zwischenablage kopieren
Corrupted Data = Beschädigte Daten
Default = Vorgabe
Delete = Löschen
Delete all = Alle löschen
Delete completed = Löschen abgeschlossen
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Hapusi
Delete all = Delete all
Delete completed = Terhapusmi.
+1
View File
@@ -424,6 +424,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Delete
Delete all = Delete all
Delete completed = Delete completed.
+1
View File
@@ -401,6 +401,7 @@ ConnectionName = Nombre de la conexión
Copied to clipboard: %1 = Copiado a portapapeles: %1
Copy to clipboard = Copiar a portapapeles
Corrupted Data = Datos corruptos
Default = Por defecto
Delete = Eliminar
Delete all = Eliminar todo
Delete completed = Eliminado completado.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Nombre de conexión
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Datos dañados
Default = Por defecto
Delete = Borrar
Delete all = Borrar todos
Delete completed = Borrado terminado.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = نام اتصال
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = داده‌ها خراب شده
Default = پیشفرض
Delete = ‎حذف
Delete all = حذف همه
Delete completed = .حذف شد
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Yhteyden nimi
Copied to clipboard: %1 = Kopioitu leikepöydälle: %1
Copy to clipboard = Kopioi leikepöydälle
Corrupted Data = Vioittuneet tiedot
Default = Oletus
Delete = Poista
Delete all = Poista kaikki
Delete completed = Poisto onnistui.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Nom de la connexion
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Données corrompues
Default = Default
Delete = Supprimer
Delete all = Tout supprimer
Delete completed = Suppression terminée.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Borrar
Delete all = Borrar todo
Delete completed = Borrado completado.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = ΔΙΑΓΡΑΦΗ
Delete all = ΔΙΑΓΡΑΦΗ ΟΛΩΝ
Delete completed = ΔΙΑΓΡΑΦΗ ΟΛΟΚΛΗΡΩΘΗΚΕ
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = קחמ
Delete all = Delete all
Delete completed = .המלשוה הקיחמ
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = קחמ
Delete all = Delete all
Delete completed = .המלשוה הקיחמ
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Izbriši
Delete all = Izbriši sve
Delete completed = Brisanje dovršeno.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Vágolapra másolás
Corrupted Data = Sérült adat
Default = Alapértelmezett
Delete = Töröl
Delete all = Mindet töröl
Delete completed = Törölve.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Nama koneksi
Copied to clipboard: %1 = Disalin ke papan klip: %1
Copy to clipboard = Salin ke papan klip
Corrupted Data = Data rusak
Default = Bawaan
Delete = Hapus
Delete all = Hapus semua
Delete completed = Selesai menghapus.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Nome connessione
Copied to clipboard: %1 = Copiato negli appunti: %1
Copy to clipboard = Copia negli appunti
Corrupted Data = Dati corrotti
Default = Predefinito
Delete = Elimina
Delete all = Elimina tutto
Delete completed = Eliminazione completata.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = 接続名
Copied to clipboard: %1 = クリップボードへコピー: %1
Copy to clipboard = クリップボードへコピー
Corrupted Data = 破損したデータ
Default = デフォルト
Delete = 削除
Delete all = 全て削除
Delete completed = 削除が完了しました。
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Mbusek
Delete all = Mbusek Kabeh
Delete completed = Mbusek rampung.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = 연결 이름
Copied to clipboard: %1 = 클립보드에 복사됨: %1
Copy to clipboard = 클립보드에 복사
Corrupted Data = 손상된 데이터
Default = 기본
Delete = 삭제
Delete all = 모두 삭제
Delete completed = 삭제가 완료되었습니다.
+1
View File
@@ -414,6 +414,7 @@ ConnectionName = ناوی پەیوەندی
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = زانیاریەکە تێکچووە
Default = Default
Delete = سڕینەوە
Delete all = سڕینەوەی هەمووی
Delete completed = سڕینەوەکە سەرکەووتوو بوو
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = ລຶບ
Delete all = ລຶບທັງໝົດ
Delete completed = ລຶບຂໍ້ມູນສຳເລັດ
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Ištrinti
Delete all = Ištrinti viską
Delete completed = Ištrinimas baigtas.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Padam
Delete all = Padam semua
Delete completed = Pemadaman selesai.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Wissen
Delete all = Alles wissen
Delete completed = Het verwijderen is voltooid.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Standard
Delete = Slett
Delete all = Delete all
Delete completed = Slettet!!
+1
View File
@@ -399,6 +399,7 @@ ConnectionName = Nazwa Połączenia
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Uszkodzone dane
Default = Domyślny
Delete = Usuń
Delete all = Usuń wszystko
Delete completed = Usuwanie zakończone.
+1
View File
@@ -423,6 +423,7 @@ ConnectionName = Nome da conexão
Copied to clipboard: %1 = Copiou para a área de transferência: %1
Copy to clipboard = Copiar para a área de transferência
Corrupted Data = Dados corrompidos
Default = Padrão
Delete = Apagar
Delete all = Apagar tudo
Delete completed = Exclusão completada.
+1
View File
@@ -424,6 +424,7 @@ ConnectionName = Nome da conexão
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Dados Corrompidos
Default = Padrão
Delete = Eliminar
Delete all = Eliminar tudo
Delete completed = Eliminação completa.
+1
View File
@@ -401,6 +401,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Șterge
Delete all = Șterge tot
Delete completed = Ștergere completă
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Имя повреждено
Copied to clipboard: %1 = Скопировано в буфер обмена: %1
Copy to clipboard = Копировать в буфер обмена
Corrupted Data = Данные повреждены
Default = По умолчанию
Delete = Удалить
Delete all = Удалить всё
Delete completed = Удаление завершено
+1
View File
@@ -401,6 +401,7 @@ Copied to clipboard: %1 = Kopierat till urklipp: %1
Copy to clipboard = Kopiera till urklipp
Corrupted Data = Korrupt data
#Default = Standard
Default = Standard
Delete = Radera
Delete all = Radera allt
Delete completed = Borttaget.
+1
View File
@@ -401,6 +401,7 @@ ConnectionName = Pangalan ng Koneksyon
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted ang data
Default = Default
Delete = Burahin
Delete all = Burahin Lahat
Delete completed = Burado na.
+1
View File
@@ -416,6 +416,7 @@ ConnectionName = ชื่อเครือข่าย
Copied to clipboard: %1 = คัดลอกไปยังคลิปบอร์ด: %1
Copy to clipboard = คัดลอกไปยังคลิปบอร์ด
Corrupted Data = ข้อมูลเสียหาย
Default = ค่าดั้งเดิม
Delete = ลบ
Delete all = ลบทั้งหมด
Delete completed = ลบข้อมูลสำเร็จ
+1
View File
@@ -402,6 +402,7 @@ ConnectionName = Bağlantı adı
Copied to clipboard: %1 = Panoya kopyalandı: %1
Copy to clipboard = Panoya kopyala
Corrupted Data = Bozuk veri
Default = Varsayılan
Delete = Sil
Delete all = Tümünü sil
Delete completed = Silme işlemi tamamlandı.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Назва підключення
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Копіювати в буфер обміну
Corrupted Data = Пошкоджені дані
Default = Звичайна
Delete = Видалити
Delete all = Видалити все
Delete completed = Видалення завершено
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = Connection name
Copied to clipboard: %1 = Copied to clipboard: %1
Copy to clipboard = Copy to clipboard
Corrupted Data = Corrupted data
Default = Default
Delete = Xóa
Delete all = Xóa tất cả
Delete completed = Đã xóa xong.
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = 连接名称
Copied to clipboard: %1 = 已复制到剪贴板: %1
Copy to clipboard = 复制到剪贴板
Corrupted Data = 数据损坏
Default = 默认主题
Delete = 删除
Delete all = 清除
Delete completed = 已删除。
+1
View File
@@ -400,6 +400,7 @@ ConnectionName = 連線名稱
Copied to clipboard: %1 = 已複製到剪貼簿:%1
Copy to clipboard = 複製到剪貼簿
Corrupted Data = 已損毀的資料
Default = 預設
Delete = 刪除
Delete all = 全部刪除
Delete completed = 刪除完成
+8 -5
View File
@@ -7,7 +7,7 @@
viewBox="0 0 158.74998 185.20831"
version="1.1"
id="svg1"
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
inkscape:version="1.4.2 (f4327f4, 2025-05-13)"
sodipodi:docname="images.svg"
xml:space="preserve"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
@@ -24,9 +24,9 @@
inkscape:pagecheckerboard="true"
inkscape:deskcolor="#d1d1d1"
inkscape:document-units="px"
inkscape:zoom="5.656855"
inkscape:cx="250.49255"
inkscape:cy="560.11689"
inkscape:zoom="16.000002"
inkscape:cx="338.78121"
inkscape:cy="626.46867"
inkscape:window-width="3840"
inkscape:window-height="2071"
inkscape:window-x="-9"
@@ -4426,7 +4426,10 @@
style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.553509" /><path
id="I_RESIZE"
style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.645958"
d="m 73.353766,158.91621 v 2.9068 h 0.968933 v -1.25315 l 1.513086,1.51308 0.685229,-0.68523 -1.513086,-1.51257 h 1.252637 v -0.96893 z m 5.412589,0 v 0.96893 h 1.252636 l -1.551843,1.55185 0.68523,0.68471 1.551843,-1.55184 v 1.25315 h 0.968933 v -2.9068 z m -2.896981,5.11803 -1.546675,1.54668 v -1.25264 h -0.968933 v 2.9068 h 2.906799 v -0.96893 h -1.252637 l 1.547193,-1.54668 z m 3.303674,0.0155 -0.685229,0.68523 1.531172,1.53117 h -1.252636 v 0.96893 h 2.906799 v -2.9068 h -0.968933 v 1.25264 z" /></g><path
d="m 73.353766,158.91621 v 2.9068 h 0.968933 v -1.25315 l 1.513086,1.51308 0.685229,-0.68523 -1.513086,-1.51257 h 1.252637 v -0.96893 z m 5.412589,0 v 0.96893 h 1.252636 l -1.551843,1.55185 0.68523,0.68471 1.551843,-1.55184 v 1.25315 h 0.968933 v -2.9068 z m -2.896981,5.11803 -1.546675,1.54668 v -1.25264 h -0.968933 v 2.9068 h 2.906799 v -0.96893 h -1.252637 l 1.547193,-1.54668 z m 3.303674,0.0155 -0.685229,0.68523 1.531172,1.53117 h -1.252636 v 0.96893 h 2.906799 v -2.9068 h -0.968933 v 1.25264 z" /><path
id="I_LINK_OUT_QUESTION"
style="color:#000000;baseline-shift:baseline;display:inline;overflow:visible;visibility:visible;vector-effect:none;fill:#ffffff;stroke:none;stroke-width:0.70526;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate;stop-color:#000000"
d="M 95.057752 156.71186 L 90.723133 156.84622 L 92.339055 158.49211 L 91.223361 159.6631 L 92.174724 160.61447 L 93.289901 159.44296 L 94.924943 161.04751 L 95.057752 156.71186 z M 85.100738 157.98414 L 85.100738 166.83166 L 93.86816 166.83166 L 93.86816 161.78907 L 93.082679 161.78907 L 93.082679 166.04617 L 85.88622 166.04617 L 85.88622 158.76962 L 90.041521 158.76962 L 90.041521 157.98414 L 85.100738 157.98414 z M 89.34699 160.23671 C 89.143515 160.23671 88.946182 160.26034 88.755295 160.30854 C 88.564405 160.35684 88.38765 160.4291 88.226128 160.52558 L 88.226128 161.47333 C 88.383454 161.33492 88.550669 161.23198 88.726873 161.16482 C 88.903078 161.09562 89.072783 161.06095 89.236402 161.06095 C 89.311912 161.06095 89.380206 161.07237 89.441041 161.09557 C 89.503971 161.11857 89.556185 161.14972 89.598137 161.18962 C 89.642187 161.22952 89.675323 161.27825 89.69839 161.33483 C 89.72146 161.38923 89.73353 161.44909 89.73353 161.51415 C 89.73353 161.58965 89.722987 161.65899 89.702007 161.72189 C 89.681027 161.78279 89.649389 161.84249 89.607439 161.90121 C 89.565479 161.95791 89.514283 162.0151 89.453443 162.07381 C 89.394703 162.13041 89.325417 162.19218 89.245704 162.25933 C 89.170184 162.32223 89.103904 162.38651 89.047267 162.45156 C 88.990627 162.51456 88.943433 162.58177 88.905673 162.6531 C 88.867913 162.7223 88.839784 162.79663 88.820924 162.87634 C 88.802044 162.95604 88.792502 163.04391 88.792502 163.14041 C 88.792502 163.20131 88.797942 163.26653 88.808522 163.33575 C 88.821102 163.40285 88.837668 163.46364 88.858648 163.51816 L 89.685987 163.51816 C 89.662917 163.48246 89.64435 163.43879 89.62966 163.38639 C 89.61708 163.33399 89.611056 163.28274 89.611056 163.23239 C 89.611056 163.15899 89.620152 163.09368 89.638962 163.03706 C 89.657842 162.97836 89.68495 162.92359 89.72061 162.87324 C 89.75837 162.82084 89.804573 162.76807 89.859103 162.71563 C 89.915743 162.66313 89.981021 162.60693 90.05444 162.54613 C 90.16352 162.45593 90.25992 162.36855 90.343828 162.28465 C 90.427728 162.19865 90.49803 162.10978 90.554668 162.01748 C 90.611308 161.92518 90.654489 161.82777 90.683859 161.72499 C 90.713229 161.6201 90.727784 161.50361 90.727784 161.37566 C 90.727784 161.17428 90.692656 161.00205 90.621331 160.85941 C 90.552101 160.71467 90.453668 160.59618 90.327808 160.50388 C 90.204044 160.41168 90.058441 160.34431 89.890626 160.30234 C 89.722812 160.25834 89.542074 160.23671 89.34699 160.23671 z M 89.318568 163.85819 C 89.150754 163.85819 89.011166 163.90732 88.899989 164.00599 C 88.788812 164.10459 88.733074 164.22761 88.733074 164.37444 C 88.733074 164.51709 88.788816 164.64061 88.899989 164.74548 C 89.011166 164.84622 89.150754 164.89637 89.318568 164.89637 C 89.486383 164.89637 89.62445 164.84715 89.73353 164.74858 C 89.840512 164.64998 89.893726 164.52548 89.893726 164.37444 C 89.893726 164.22551 89.838996 164.10248 89.729912 164.00599 C 89.620833 163.90739 89.484284 163.85819 89.318568 163.85819 z " /></g><path
id="I_GEAR"
style="fill:#ececec;fill-opacity:1;stroke-width:0.019487"
class="st0"

Before

Width:  |  Height:  |  Size: 232 KiB

After

Width:  |  Height:  |  Size: 235 KiB

+5 -5
View File
@@ -59,12 +59,12 @@ void ImGui_ImplPlatform_TouchEvent(const TouchInput &touch) {
float x = touch.x / g_display.dpi_scale_x;
float y = touch.y / g_display.dpi_scale_y;
if (touch.flags & TOUCH_MOVE) {
if (touch.flags & TouchInputFlags::MOVE) {
io.AddMousePosEvent(x, y);
}
if (touch.flags & TOUCH_DOWN) {
if (touch.flags & TouchInputFlags::DOWN) {
io.AddMousePosEvent(x, y);
if (touch.flags & TOUCH_MOUSE) {
if (touch.flags & TouchInputFlags::MOUSE) {
if (touch.buttons & 1)
io.AddMouseButtonEvent(0, true);
if (touch.buttons & 2)
@@ -73,9 +73,9 @@ void ImGui_ImplPlatform_TouchEvent(const TouchInput &touch) {
io.AddMouseButtonEvent(0, true);
}
}
if (touch.flags & TOUCH_UP) {
if (touch.flags & TouchInputFlags::UP) {
io.AddMousePosEvent(x, y);
if (touch.flags & TOUCH_MOUSE) {
if (touch.flags & TouchInputFlags::MOUSE) {
if (touch.buttons & 1)
io.AddMouseButtonEvent(0, false);
if (touch.buttons & 2)