Skip to content

Rework visual of QGCDelayButton#13706

Merged
DonLakeFlyer merged 1 commit intomasterfrom
DelayButton
Dec 7, 2025
Merged

Rework visual of QGCDelayButton#13706
DonLakeFlyer merged 1 commit intomasterfrom
DelayButton

Conversation

@DonLakeFlyer
Copy link
Copy Markdown
Collaborator

  • Double-chevron indicates delay button
  • Chevrons move from left to right as you hold down

Screenshot 2025-12-06 at 3 27 51 PM

Copilot AI review requested due to automatic review settings December 6, 2025 23:29
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the visual design of QGCDelayButton by replacing the gradient-based progress indicator with an animated double-chevron icon that moves from left to right as the user holds the button down.

Key Changes:

  • Replaces gradient/rectangle progress indicator with a moving chevron icon for better visual feedback
  • Adds new SVG resource (chevron-double-right.svg) for the progress indicator
  • Updates resource registration in qgcresources.qrc

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/QmlControls/QGCDelayButton.qml Replaces gradient-based progress visualization with QGCColoredImage showing animated chevron icon
resources/chevron-double-right.svg New SVG icon file for double-chevron indicator
qgcresources.qrc Registers the new chevron-double-right.svg resource

color: qgcPal.buttonHighlight
opacity: _showHighlight ? 1 : control.enabled && control.hovered ? .2 : 0
radius: parent.radius
property real _sliderIndicatorMargin: ScreenTools.defaultFontPixelWidth * 0.5
Copy link

Copilot AI Dec 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The property _sliderIndicatorMargin is defined at the bottom of the QGCColoredImage component (line 85), after all the other properties have been set. In QML, it's more conventional and readable to declare properties at the beginning of a component block, before they are used.

Consider moving this property declaration to the top of the QGCColoredImage block (after line 71) for better readability:

QGCColoredImage {
    property real _sliderIndicatorMargin: ScreenTools.defaultFontPixelWidth * 0.5
    
    anchors.topMargin:      _sliderIndicatorMargin
    anchors.bottomMargin:   _sliderIndicatorMargin
    // ... rest of properties
}

Copilot uses AI. Check for mistakes.
@DonLakeFlyer DonLakeFlyer reopened this Dec 7, 2025
@DonLakeFlyer DonLakeFlyer merged commit c4ea24c into master Dec 7, 2025
35 of 42 checks passed
@DonLakeFlyer DonLakeFlyer deleted the DelayButton branch December 7, 2025 02:27
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