View unanswered posts | View active topics



Reply to topic  [ 7 posts ] 
Snippet list closes automatically after short period of time 
Author Message
Member

Joined: Wed Jun 15, 2016 3:22 pm
Posts: 3
Reply with quote
When i press CTRL+B for the snippet list, while a text is selected, it usually closes after around one second automatically. When i instantly open it again, it works good.

It happens in UITools.cs : private void OnUIRefresh(ScintillaControl sci)

Are these lines necessary?

Code:
callTip.Hide();
CompletionList.Hide();
simpleTip.Hide();



Version 5.1.1.1 with .NET 3.5. But goes on from version 5.


Wed Jun 15, 2016 3:35 pm
Profile
Member

Joined: Sat Oct 10, 2015 4:25 am
Posts: 34
Location: New Zealand
Reply with quote
The lines before the hide calls ensure that if the editor is in focus, and the completion list or the call tip is active and valid, the method returns before reaching the hide calls. And yes, the hide calls are necessary.

I cannot reproduce the problem (release 5.1.1 and also development). Does it happen every time you press Ctrl+B while the text is selected?


Fri Jun 17, 2016 3:50 am
Profile WWW
Member

Joined: Wed Jun 15, 2016 3:22 pm
Posts: 3
Reply with quote
I think i figured it out. It happens when you select a word from its end to start.

Start FD, and just start typing into Untitled1.as:

- type in "var"
- press shift+ctrl+left
- ctrl+b

CompletionList.CheckPosition returns false.


Mon Jun 20, 2016 10:49 am
Profile
Member

Joined: Sat Oct 10, 2015 4:25 am
Posts: 34
Location: New Zealand
Reply with quote
Sorry, I still can't reproduce it...
I followed your exact steps, and tried every variations.

Are there any more details? Do you have any plugins installed?


Mon Jun 20, 2016 12:30 pm
Profile WWW
Member

Joined: Wed Jun 15, 2016 3:22 pm
Posts: 3
Reply with quote
I checked out the current version (ccbe1d4) from github, compiled it in visual studio and it does the same. The only requirement is to highlight the word backwards. Looks like currentPos contains the last character index of the selection, but if you highlight the word from the last character to the first, currentPos will be equal to the first character index, so this function returns false

Code:
CompletionList.cs

public static Boolean CheckPosition(Int32 position)
{
    return position == currentPos;
}


so the onUIRefresh won't return before hiding the panels.


Mon Jun 20, 2016 1:51 pm
Profile
Admin

Joined: Wed Aug 31, 2005 7:27 am
Posts: 12172
Location: London
Reply with quote
Thanks, please raise an issue on Github now that the problem is well identified!


Sat Jul 02, 2016 8:25 pm
Profile WWW
Member

Joined: Sat Oct 10, 2015 4:25 am
Posts: 34
Location: New Zealand
Reply with quote
Strange. OP described that the issue is present in both the release (5.1.1.1) and the current development version.

I can reproduce it in the current dev version, but not in the release?
Anyways: https://github.com/fdorg/flashdevelop/issues/1277


Mon Jul 04, 2016 4:03 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 7 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.