Custom icons, improved GPS, history layout, address fixes

- Replace placeholder SVG icons with custom PNG icons (80x80 padded)
- AffineTransform for pixel-perfect icon centering in menu ring
- Colored circles behind icons with icon drawn at 60% size
- GPS: always wait full timeout (30s), keep best quality fix
- History: show address, PLZ+city, coordinates on separate lines
- Geocoding: fall back to "name" field for street-level results,
  include PLZ+city in cached address data
- Address distance threshold raised to 70m

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
EiSiMo 2026-04-13 19:05:17 +02:00
parent 79cdb9f210
commit 216d40c2c5
18 changed files with 108 additions and 101 deletions

View file

@ -67,6 +67,11 @@ class MenuView extends WatchUi.View {
var isSelected = (i == _selectedIndex);
var targetSize = isSelected ? selSize : baseSize;
// Colored circle behind icon.
var color = _items[i][:color] as Number;
dc.setColor(color, Config.COLOR_BG);
dc.fillCircle(x, y, targetSize / 2);
var iconId = _items[i][:icon];
var bmp = _bitmaps[iconId] as BitmapResource;
if (bmp != null) {
@ -91,12 +96,12 @@ class MenuView extends WatchUi.View {
cx as Number, cy as Number,
targetSize as Number) as Void {
var bmpW = bmp.getWidth();
var bmpH = bmp.getHeight();
var scale = targetSize.toFloat() / bmpW.toFloat();
dc.drawBitmap2(
cx - targetSize / 2,
cy - targetSize / 2,
bmp,
{ :scaleX => scale, :scaleY => scale }
);
var tf = new Graphics.AffineTransform();
tf.translate(cx.toFloat(), cy.toFloat());
tf.scale(scale, scale);
tf.translate(-bmpW.toFloat() / 2.0, -bmpH.toFloat() / 2.0);
dc.drawBitmap2(0, 0, bmp, { :transform => tf });
}
}