Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No wait cursor on CSL navigator expand #8274

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lkishalmi
Copy link
Contributor

Well, I find it a bit annoying, that almost every time I edit a Yaml, HCL file, there is a flickering on the mouse cursor changing to wait cursor and then back.

It turned out that is because the navigator is expanding it's tree to the current location, so when the structure changes it issues an expand and the TreeView.autoWaitCursor is true by default and put the cursor in wait mode for a brief moment.

That led me to try other parts of the IDE, and expanding nodes could result with a brief mouse cursor change. That made me think to change the TreeView behavior. It would be good to have the default for the wait cursor to be false, though since it is down in the core I think it's being used many places outside of NetBeans.

Probably the best would be delaying the wait cursor change by 500ms or so, and if the tree could expand it in that time we just do not do that. Might try to create a PR for that one, however for the default CSL provided navigator, I do not thing that we need the autoWaitCursor functionality at all.

@lkishalmi lkishalmi added the CSL [ci] enable web job label Feb 23, 2025
@@ -328,7 +328,6 @@ public void run() {
elementView.setScrollOnExpand( scrollOnExpand );
}
});
elementView.setAutoWaitCursor(true);
Copy link
Member

Choose a reason for hiding this comment

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

nothing against this but we should try to keep functionality in sync across the codebase.

the java navigator has the same disable/enable trick in the refresh method:

elementView.setAutoWaitCursor(false);
elementView.expandAll();
elementView.setAutoWaitCursor(true);

(there are no other usages looks like)

I think I can see the cursor change for a split second when I toggle collapse/expand in the java navigator.

Disabling the cursor change should be fine UX-wise, since the tree itself has a please-wait placeholder node for situations where it takes longer until the file structure is available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CSL [ci] enable web job
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants