IDEA-112728 Can't create new task from tasks menu in toolbar: no need to fix lost typing for Go To Task

This commit is contained in:
Dmitry Avdeev
2013-08-28 19:23:13 +04:00
parent a8160c2ef3
commit ddad3bbde7
2 changed files with 14 additions and 6 deletions
@@ -155,6 +155,7 @@ public abstract class ChooseByNameBase {
private ShortcutSet myCheckBoxShortcut;
protected boolean myInitIsDone;
static final boolean ourLoadNamesEachTime = FileBasedIndex.ourEnableTracingOfKeyHashToVirtualFileMapping;
private boolean myFixLostTyping = true;
public boolean checkDisposed() {
if (myDisposedFlag && myPostponedOkAction != null && !myPostponedOkAction.isProcessed()) {
@@ -777,8 +778,12 @@ public abstract class ChooseByNameBase {
return false;
}
protected static boolean isToFixLostTyping() {
return Registry.is("actionSystem.fixLostTyping");
public void setFixLostTyping(boolean fixLostTyping) {
myFixLostTyping = fixLostTyping;
}
protected boolean isToFixLostTyping() {
return myFixLostTyping && Registry.is("actionSystem.fixLostTyping");
}
private synchronized void ensureNamesLoaded(boolean checkboxState) {
@@ -1194,10 +1199,12 @@ public abstract class ChooseByNameBase {
}
protected List<Object> getChosenElements() {
if (myListIsUpToDate) {
List<Object> values = new ArrayList<Object>(Arrays.asList(myList.getSelectedValues()));
values.remove(EXTRA_ELEM);
values.remove(NON_PREFIX_SEPARATOR);
List<Object> values = new ArrayList<Object>(Arrays.asList(myList.getSelectedValues()));
values.remove(EXTRA_ELEM);
values.remove(NON_PREFIX_SEPARATOR);
if (myListIsUpToDate || !values.isEmpty()) {
return values;
}
@@ -83,6 +83,7 @@ public class GotoTaskAction extends GotoActionBase implements DumbAware {
popup.setShowListForEmptyPattern(true);
popup.setSearchInAnyPlace(true);
popup.setFixLostTyping(false);
popup.setAdText("<html>Press SHIFT to merge with current context<br/>" +
"Pressing " +
KeymapUtil.getFirstKeyboardShortcutText(ActionManager.getInstance().getAction(IdeActions.ACTION_QUICK_JAVADOC)) +