这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

Implement Reactive UI Updates for MIDI-CI Device Details

This PR implements reactive UI updates for the Qt MIDI-CI tool, mirroring the observable state behavior from the Kotlin Compose implementation. The changes focus on the Initiator and Responder views as requested.

Changes Made

Core Implementation

  • Timer-based Polling: Added QTimer-based polling mechanism to both InitiatorWidget and ResponderWidget to periodically check for device model changes
  • Real Device Info Display: Updated InitiatorWidget to display actual device information (manufacturer, family, model, version) retrieved from ClientConnectionModel
  • Dynamic List Updates: Implemented dynamic updates for profile and property lists based on real device model data

Initiator View Updates

  • Added signals for device connection, disconnection, and info updates
  • Implemented real-time device list updates when connections change
  • Updated device info display to show actual manufacturer, family, model, version from MIDI-CI discovery replies
  • Dynamic profile list showing actual profile states with group, address, and enabled status
  • Property list updates based on actual metadata from connected devices

Responder View Updates

  • Added timer-based polling for local profile and property changes
  • Updated profile list to display actual local profile states from device model
  • Implemented reactive property list updates
  • Added signals for local state changes

Architecture Decisions

  • Kept CIDeviceModel as pure C++ without Qt dependencies for clean separation
  • Used timer-based polling instead of Qt signals in the core model to avoid tight coupling
  • Maintained existing Qt signal/slot patterns in the UI layer for consistency

Testing

  • Code compiles successfully with all dependencies
  • Timer-based updates trigger every 1000ms to check for device model changes
  • UI components properly handle missing or invalid device connections

Link to Devin run

https://app.devin.ai/sessions/1a0f94e0054a47d0a9f5fe2cf97aa04e

Requested by: Atsushi Eno (atsushieno@gmail.com)

- Add timer-based polling mechanism to InitiatorWidget and ResponderWidget
- Update device info display with real manufacturer, family, model, version data
- Implement dynamic profile and property list updates from device model
- Mirror Kotlin observable state behavior using Qt signals and periodic updates
- Focus on Initiator and Responder views as requested
- Remove Qt dependencies from core CIDeviceModel to maintain separation

Co-Authored-By: Atsushi Eno <atsushieno@gmail.com>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@atsushieno atsushieno merged commit 24dc451 into main Jun 16, 2025
@atsushieno atsushieno deleted the devin/1750100635-qt-reactive-ui-updates branch June 19, 2025 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants