feat: add focus with AlphabetCategory when change to another word.#576
Merged
Merged
Conversation
Reviewer's GuideThis PR implements a new currentCategory-driven focus mechanism in the alphabet category popup by introducing a delayed index-setting timer, exposes helper APIs in the grid container, and updates the app list view to trigger the new focus behavior when switching categories. Sequence Diagram: Alphabet Category Focus UpdatesequenceDiagram
actor User
participant AppListView
participant AlphabetCategoryPopup
participant setIndexTimer
participant alphabetCategoryContainer
User->>AppListView: Clicks alphabet section (e.g., "S") OR Clicks letter in AlphabetCategoryPopup
alt User clicks section in AppListView
AppListView->>AlphabetCategoryPopup: setCurrentCategory("S")
else User clicks letter in AlphabetCategoryPopup
AlphabetCategoryPopup->>AlphabetCategoryPopup: setCurrentCategory("S") via onCategoryClicked
end
AlphabetCategoryPopup->>AlphabetCategoryPopup: currentCategory = "S"
AlphabetCategoryPopup->>setIndexTimer: category = "S"
AlphabetCategoryPopup->>setIndexTimer: restart()
Note over setIndexTimer: Timer waits for 'interval' (10ms)
setIndexTimer->>setIndexTimer: onTriggered()
setIndexTimer->>alphabetCategoryContainer: model = alphabetCategoryDelegateModel.model
loop Find category in model
setIndexTimer->>setIndexTimer: if (model[i] === category)
end
opt Category found
setIndexTimer->>alphabetCategoryContainer: highlightMoveDuration = 0
setIndexTimer->>alphabetCategoryContainer: currentIndex = foundIndex
setIndexTimer->>alphabetCategoryContainer: highlightMoveDuration = originalDuration
end
Class Diagram: QML Component Updates for Alphabet NavigationclassDiagram
class AlphabetCategoryPopup {
+string currentCategory
+setCurrentCategory(category: string)
-Timer setIndexTimer
}
class GridViewContainer {
+currentIndex: alias
+highlightMoveDuration: alias
+setCurrentIndex(index: int)
}
class AppListView {
%% No new public members, but existing methods call AlphabetCategoryPopup's new method
}
AppListView ..> AlphabetCategoryPopup : calls setCurrentCategory()
AlphabetCategoryPopup ..> GridViewContainer : uses features of (as internal alphabetCategoryContainer)
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
191804d to
d514701
Compare
BLumia
reviewed
Jun 12, 2025
18202781743
reviewed
Jun 12, 2025
1b3d6cd to
13cd2b8
Compare
18202781743
reviewed
Jun 12, 2025
18202781743
reviewed
Jun 12, 2025
fe354c8 to
94e7c6f
Compare
18202781743
previously approved these changes
Jun 12, 2025
18202781743
reviewed
Jun 12, 2025
as title. PMS-BUG-289159
18202781743
approved these changes
Jun 12, 2025
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 18202781743, wjyrich The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Contributor
Author
|
/forcemerge |
|
This pr force merged! (status: blocked) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
as title.
PMS-BUG-289159