9 Commits

Author SHA1 Message Date
5351513619 v1.1.2: Channel name formatting and Live TV search optimization
## New Features

### lib/utils/channel_name_formatter.dart (NEW)
- Created new utility class for formatting channel names
- Removes quality tokens (SD, HD, FHD, UHD, 4K, 8K, HDR, HEVC, H264, H265, FULLHD)
- Strips prefixes before pipe character (e.g., "AR | Channel" → "Channel")
- Removes leading dashes, colons, and other separators
- Implements caching mechanism (max 50,000 entries) for performance
- Normalizes tokens by removing non-alphanumeric characters

## UI/UX Improvements

### lib/screens/home_screen.dart
- **Live TV Memory Optimization**: Live streams list now persists in memory while app is running
  - Prevents unnecessary reloads when navigating back to Live TV
  - Improves performance and reduces API calls
- **Search Bar Visibility**: Hidden search bar for Live TV content type
  - Search only shown for Movies and Series
  - Cleaner UI for Live TV browsing
- **Channel Name Display**: Applied ChannelNameFormatter to channel cards
  - Removes quality indicators from displayed names
  - Better text styling with centered alignment
  - Increased font weight (w500 → w600)
  - Improved line height (1.15) for better readability
  - Text alignment changed to center
  - Better overflow handling with ellipsis

### lib/screens/player_screen.dart
- Code cleanup and optimization
- Removed unused imports/statements (9 lines removed)

## Technical Details

### Performance
- Channel name caching reduces string processing overhead
- Live TV list persistence reduces API calls
- Memory-efficient cache with automatic cleanup

### Code Quality
- Separation of concerns with new utility class
- Consistent formatting across channel names
- Better memory management for large channel lists

## Statistics
- 3 files changed
- +141 insertions, -68 deletions
- Net: +73 lines
- New file: lib/utils/channel_name_formatter.dart

## Breaking Changes
None - all changes are additive or UI improvements
2026-02-26 00:28:03 -03:00
8c7bbc5f2d v1.1.0: Major refactoring and Android TV optimizations
## Screens

### home_screen.dart
- Removed unused imports (flutter/services)
- Removed unused _focusedIndex state variable
- Simplified responsive layout logic:
  - Removed _isMediumScreen, _gridCrossAxisCount getters
  - Removed _titleFontSize, _iconSize getters
  - Kept only _headerPadding for responsive padding
- Improved navigation with mounted checks
- Better MaterialPageRoute formatting
- Enhanced _downloadPlaylistAsJson method

## Services

### xtream_api.dart
- Added http.Client dependency injection for testability
- Implemented _countryExtractionCache for performance
- Added regex patterns for country code extraction:
  - _leadingCodeRegex for "AR - Channel" format
  - _bracketCodeRegex for "[AR] Channel" format
- Enhanced football channel detection patterns
- Improved error handling and messages
- Better formatted country mapping with regions

### iptv_provider.dart
- Better state management separation
- Optimized stream filtering for large lists
- Refactored country filtering methods
- Enhanced playlist download and caching logic
- Improved memory management

## Widgets

### countries_sidebar.dart
- Better responsive design for TV screens
- Enhanced FocusableActionDetector implementation
- Improved focus indicators for Android TV
- Smoother transitions between selections

### simple_countries_sidebar.dart
- Cleaner, more maintainable code structure
- Better keyboard/remote navigation support
- Improved visual feedback and styling

## Player

### player_screen.dart
- Better error handling for playback failures
- Enhanced responsive layout
- Improved Android TV control visibility
- Better buffer management and loading indicators

## Tests

### widget_test.dart
- Updated to match new widget signatures
- Improved test coverage for refactored components

## Technical Improvements

- Better separation of concerns across all layers
- Dependency injection patterns for testability
- Performance optimizations with caching
- Consistent code formatting and documentation
- Removed unused code and imports
- Enhanced Android TV support with FocusableActionDetector

## Statistics
- 8 files changed
- +1300 insertions
- -1139 deletions
- Net: +161 lines of cleaner code

## Breaking Changes
None - all internal refactorings with no API changes
2026-02-26 00:02:41 -03:00
5d38b89a53 v1.0.2: Fix syntax error and complete Android TV remote navigation 2026-02-25 23:33:37 -03:00
19b45152f8 v1.0.1: Fix Android TV remote control navigation and focus indicators 2026-02-25 22:59:44 -03:00
e281ba3922 v2: TV optimized UI, country filter fix, landscape mode 2026-02-25 15:43:24 -03:00
120dd746d7 New dashboard UI with country filter and grid layout 2026-02-25 13:29:15 -03:00
f9098ba234 Add search functionality to Live, Movies and Series tabs 2026-02-25 13:19:43 -03:00
1f5b53ea3c Fix type casting errors for Xtream API 2026-02-25 13:10:39 -03:00
dd61066b3a Initial commit: Xtream IPTV Player for Android TV 2026-02-25 13:01:25 -03:00