Upload via GUI (186 Dateien)
This commit is contained in:
+3
-2
@@ -81,10 +81,11 @@ public static class DesktopIcons
|
||||
return changed;
|
||||
}
|
||||
|
||||
public static bool HitsIcon(int x, int y) => Cached.Any(i =>
|
||||
/// <param name="margin">Zusätzlicher Rand in Pixeln, damit Klicks knapp neben Bild oder Beschriftung auch zählen.</param>
|
||||
public static bool HitsIcon(int x, int y, int margin = 0) => Cached.Any(i =>
|
||||
{
|
||||
var (l, t, w, h) = CellRect(i);
|
||||
return x >= l && x < l + w && y >= t && y < t + h;
|
||||
return x >= l - margin && x < l + w + margin && y >= t - margin && y < t + h + margin;
|
||||
});
|
||||
|
||||
// ---------- Desktop-Ansicht finden ----------
|
||||
|
||||
Reference in New Issue
Block a user