diff --git a/CLAUDE.md b/CLAUDE.md index 5f0874e..75d2617 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -33,17 +33,21 @@ Permissions: Location services + SYSTEM_ALERT_WINDOW for overlay functionality ## Recent Updates (v2.1.0) -### ✅ Completed Features +### ✅ Completed Features (Master Branch - Stable) - [x] **Split Decimal Display**: Main speed prominent with smaller, faded decimal fraction for better readability - [x] **Optimized Content Sizing**: Maximized readability with improved responsive layout and flex ratios +- [x] **Basic Floating Window**: Simple overlay with "GPS SPEEDO" text and close button (stable implementation) +- [x] **Navigation Icon Trigger**: Tap compass/navigation area to launch floating window overlay +- [x] **Multiple Close Options**: Overlay close button and long-press navigation area for easy dismissal +- [x] **Android System Integration**: SYSTEM_ALERT_WINDOW permissions and foreground service configuration -### 🚧 Work in Progress Features (Seriously WIP - Dev Branch) -- [ ] **Floating Window Overlay**: System-level overlay window - basic functionality works but seriously buggy +### 🚧 Work in Progress Features (dev/floating-window-wip Branch - Seriously Buggy) +- [ ] **Advanced Floating Window Overlay**: System-level overlay with live GPS data - basic functionality works but seriously buggy - GPS data synchronization implemented but unreliable - Theme/unit sync between main app and overlay works partially - Proportional sizing and positioning needs major refinement - Close button functionality works but overlay behavior inconsistent - - Android SYSTEM_ALERT_WINDOW permissions configured + - Performance may impact main app, needs optimization ### Previous Updates (v1.1) - [x] **Portrait/Landscape Support**: Automatic orientation detection implemented @@ -52,17 +56,19 @@ Permissions: Location services + SYSTEM_ALERT_WINDOW for overlay functionality ## TODO - Future Improvements -### Known Issues (Dev Branch - Floating Window WIP) +### Known Issues + +**Master Branch (v2.1.0 - Stable):** +- [ ] **Dependency Updates**: Update packages to latest compatible versions +- [ ] **Orientation Override**: Fix auto-rotate to work regardless of system toggle status + +**Dev Branch (floating-window-wip - Seriously Buggy):** - [ ] **Floating Window Reliability**: Overlay behavior inconsistent across different devices and Android versions - [ ] **GPS Data Sync**: Real-time GPS synchronization between main app and overlay unreliable - [ ] **Theme/Unit Sync**: Setting synchronization works partially but not consistently - [ ] **Overlay Positioning**: Poor positioning stability, sizing calculations need major work - [ ] **Performance**: Overlay may impact main app performance, needs optimization -### Critical Issues -- [ ] **Dependency Updates**: Update packages to latest compatible versions -- [ ] **Orientation Override**: Fix auto-rotate to work regardless of system toggle status - ### UI/UX Enhancements - [ ] **Background Customization**: Custom background color selection - [ ] **Interface Rearrangement**: User-defined layout customization @@ -85,6 +91,11 @@ Permissions: Location services + SYSTEM_ALERT_WINDOW for overlay functionality - **Memory**: Project uses automatic Claude Code memory - this file for major decisions only - **Git**: Active repository at `https://github.com/mikkelimatlock/gps_speedo` +## Branch Strategy +- **master**: Stable releases, ready for production APK builds +- **dev/floating-window-wip**: Advanced floating window development (seriously buggy, not for release) +- Tagged releases: v2.1.0 on master branch contains stable basic floating window + ## Code Patterns to Maintain - Provider pattern for state management - Separate widgets for reusability diff --git a/lib/main.dart b/lib/main.dart index eae9cc4..3d0d3cb 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -191,7 +191,7 @@ class _SpeedometerScreenState extends State with WidgetsBindi 'screenHeight': screenSize.height, }); - // Show the overlay with proportional sizing + // Show the overlay with hybrid sizing - proportional but with reasonable limits await FlutterOverlayWindow.showOverlay( enableDrag: true, overlayTitle: "GPS Speedometer", @@ -199,8 +199,9 @@ class _SpeedometerScreenState extends State with WidgetsBindi flag: OverlayFlag.defaultFlag, visibility: NotificationVisibility.visibilityPublic, positionGravity: PositionGravity.none, - width: overlayWidth, - height: overlayHeight, + // Use proportional sizing with minimum reasonable dimensions + width: overlayWidth.clamp(280, 400), + height: overlayHeight.clamp(140, 300), ); } catch (e) { // Silent error handling - floating window issues shouldn't crash main app @@ -296,7 +297,7 @@ class _SpeedometerScreenState extends State with WidgetsBindi children: [ // Speed area - takes most space, precise tap targets on text only Expanded( - flex: 7, + flex: 65, child: Container( width: double.infinity, color: Colors.transparent, @@ -351,7 +352,7 @@ class _SpeedometerScreenState extends State with WidgetsBindi ), // Compass area - compact but fully tappable for floating window Expanded( - flex: 3, + flex: 32, child: GestureDetector( onTap: _showFloatingWindow, // Tap navigation icon to show floating window onLongPress: _closeFloatingWindow, // Long press to close floating window