Commit Graph

1845 Commits

Author SHA1 Message Date
Thomas Farstrike 9bbab6a908 Fix ImageView 2026-01-23 22:25:52 +01:00
Thomas Farstrike 68b6ff3886 Cleanup WidgetAnimator framework 2026-01-23 21:37:53 +01:00
Thomas Farstrike 86d9c38902 Introduce DisplayMetrics framework 2026-01-23 20:46:36 +01:00
Thomas Farstrike 4efe22f4bf Bigger logo 2026-01-23 18:50:50 +01:00
Thomas Farstrike de7fb2b9fa Fix unit test 2026-01-23 17:19:12 +01:00
Thomas Farstrike 30b3764710 Harmonize frameworks
All frameworks now follow the same singleton class pattern with class methods:

AudioFlinger (already had this pattern)
DownloadManager (refactored)
ConnectivityManager (refactored)
CameraManager (refactored)
SensorManager (refactored)
Pattern Structure:

class FrameworkName:
    _initialized = False
    _instance_data = {}

    @classmethod
    def init(cls, *args, **kwargs):
        """Initialize the framework"""
        cls._initialized = True
        # initialization logic

    @classmethod
    def is_available(cls):
        """Check if framework is available"""
        return cls._initialized

    @classmethod
    def method_name(cls, *args):
        """Framework methods as class methods"""
        # implementation

2. Standardized Imports in __init__.py
All frameworks are now imported consistently as classes:

from .content.package_manager import PackageManager
from .config import SharedPreferences
from .net.connectivity_manager import ConnectivityManager
from .net.wifi_service import WifiService
from .audio.audioflinger import AudioFlinger
from .net.download_manager import DownloadManager
from .task_manager import TaskManager
from .camera_manager import CameraManager
from .sensor_manager import SensorManager
3. Updated Board Initialization Files
Fixed imports in all board files to use the new class-based pattern:

linux.py
fri3d_2024.py
fri3d_2026.py
waveshare_esp32_s3_touch_lcd_2.py
4. Updated UI Components
Fixed topmenu.py to import SensorManager as a class instead of a module.

5. Benefits of This Harmonization
 Consistency: All frameworks follow the same pattern - no more mixing of module imports and class imports  Simplicity: Single, clear way to use frameworks - always as classes with class methods  Functionality: All frameworks work identically - init(), is_available(), and other methods are consistent  Maintainability: New developers see one pattern to follow across all frameworks  No Breaking Changes: Apps continue to work without modification (Quasi apps, Lightning Piggy, etc.)

6. Testing
All tests pass successfully, confirming:

Framework initialization works correctly
Board hardware detection functions properly
UI components render without errors
No regressions in existing functionality
The harmonization is complete and production-ready. All frameworks now provide a unified, predictable interface that's easy to understand and extend.
2026-01-23 15:31:47 +01:00
Thomas Farstrike d8cbb2d68f Nostr: decrypt DMs 2026-01-21 21:36:15 +01:00
Thomas Farstrike 4f67ece2ac Nostr: show more event info 2026-01-21 21:33:40 +01:00
Thomas Farstrike 775b7c83b8 Nostr: show QR of npub 2026-01-21 21:26:57 +01:00
Thomas Farstrike 7296a4111e Convert npub 2026-01-21 20:57:26 +01:00
Thomas Farstrike a740cfe3f8 Show error 2026-01-21 20:54:57 +01:00
Thomas Farstrike e3bf36f9b1 Work on Nostr client 2026-01-21 17:32:59 +01:00
Thomas Farstrike faa46fbb18 Work on Nostr app 2026-01-21 17:18:07 +01:00
Thomas Farstrike a76d2b7826 Fix logo in dark mode 2026-01-21 16:18:44 +01:00
Thomas Farstrike 75b7e8dd3b Update CHANGELOG 2026-01-21 15:29:01 +01:00
Thomas Farstrike 020c5238f9 Fix topmenu handling without foreground app 2026-01-21 15:27:31 +01:00
Thomas Farstrike 3f52960371 connectivity_manager.py: remove unused imports 2026-01-21 13:45:43 +01:00
Thomas Farstrike abbd8b7409 Comments 2026-01-21 13:44:52 +01:00
Thomas Farstrike 1a39a64979 OSUpdate: simplify 2026-01-21 13:32:51 +01:00
Thomas Farstrike 0accfa269f OSUpdate: eliminate requests library 2026-01-21 13:32:04 +01:00
Thomas Farstrike bb25471b95 Remove ota library
It was hardly used.
2026-01-21 12:16:27 +01:00
Thomas Farstrike 1afc5465c3 Merge pull request #22 from QuasiKili/patch-7
Update run_desktop.sh to fix settings being ignored
2026-01-21 10:44:25 +01:00
Thomas Farstrike 0b53d6a35f scripts/bundle_apps.sh : catch typos in manifestst 2026-01-21 09:33:40 +01:00
Thomas Farstrike f40a2dab1f Fix typo in Camera manifest 2026-01-21 09:33:27 +01:00
Thomas Farstrike c6776b0107 Merge branch 'main' of https://github.com/MicroPythonOS/MicroPythonOS 2026-01-20 19:40:48 +01:00