Bug #591
Ctrl+Q shortcut in SelectPackageDlg is slogan only.
| Status: | Approved | Start date: | 11/28/2013 | |
|---|---|---|---|---|
| Priority: | Low | Due date: | ||
| Assignee: | Miroslav Fidler | % Done: | 100% | |
| Category: | IDE | Spent 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.
History
#1 Updated by Zbigniew Rebacz about 12 years ago
- File deleted (
SelectPkg.cpp)
#2 Updated by Zbigniew Rebacz about 12 years ago
- File SelectPkg.cpp
added
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 about 12 years ago
- Status changed from Ready for QA to Patch ready
#4 Updated by Miroslav Fidler almost 12 years ago
- Status changed from Patch ready to Approved