Bug #591

Ctrl+Q shortcut in SelectPackageDlg is slogan only.

Added by Zbigniew Rebacz almost 7 years ago. Updated almost 7 years ago.

Status:ApprovedStart date:11/28/2013
Priority:LowDue date:
Assignee:Miroslav Fidler% Done:

100%

Category:IDESpent time:-
Target version:-

Description

I think someone forgot to write additional functionality to "SelectPackageDlg" when Ctrl+Q is pressed. Ctrl+Q is shortcut for search. Below is a improved function that corrects this little bug (ide/SelectPkg.cpp - line 61):

bool SelectPackageDlg::Key(dword key, int count)
{
    if(key == K_ALT_ENTER) {
        ChangeDescription();
        return true;
    }
    else if(key == K_CTRL_Q) {
        search.SetFocus();
        return true;
    }
    if((clist.HasFocus() || alist.HasFocus()) && search.Key(key, count))
        return true;
    return TopWindow::Key(key, count);
}

In addition, I enclose patched source file.

SelectPkg.cpp Magnifier - CTRL+K insted of CTRL+Q for search (13.4 KB) Zbigniew Rebacz, 11/28/2013 01:11 AM

History

#1 Updated by Zbigniew Rebacz almost 7 years ago

  • File deleted (SelectPkg.cpp)

#2 Updated by Zbigniew Rebacz almost 7 years ago

Personally, I think we should also change shortcut combination (CTRL+Q to CTRL+K), because CTRL+K is more neutral for search. Moreover this shortcut is widely used for example in Mozilla Firefox or Thunderbird. While CTRL+Q is good shortcut for exiting the program.

// In Constructor:
search.NullText("Search (Ctrl+K)", StdFont().Italic(), SColorDisabled());

// Changed shortcut:
bool SelectPackageDlg::Key(dword key, int count)
{
    if(key == K_ALT_ENTER) {
        ChangeDescription();
        return true;
    }
    else if(key == K_CTRL_K) {
        search.SetFocus();
        return true;
    }
    if((clist.HasFocus() || alist.HasFocus()) && search.Key(key, count))
        return true;
    return TopWindow::Key(key, count);
}

#3 Updated by Miroslav Fidler almost 7 years ago

  • Status changed from Ready for QA to Patch ready

#4 Updated by Miroslav Fidler almost 7 years ago

  • Status changed from Patch ready to Approved

Also available in: Atom PDF