Skip to content

Commit

Permalink
Issue zealdocs#1033: Use const iterators for searchBarFocusShortcuts.
Browse files Browse the repository at this point in the history
Co-Authored-By: mcomella <mcomella@fastmail.com>
  • Loading branch information
nishanthkarthik and mcomella authored Nov 18, 2018
1 parent 082b3bb commit bd67e80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libs/ui/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ MainWindow::MainWindow(Core::Application *app, QWidget *parent) :
QShortcut *shortcut;
QStringList searchBarFocusShortcuts;
searchBarFocusShortcuts << "Ctrl+K" << "Ctrl+L";
for (auto it = searchBarFocusShortcuts.begin(); it != searchBarFocusShortcuts.end(); ++it) {
for (auto it = searchBarFocusShortcuts.cbegin(); it != searchBarFocusShortcuts.cend(); ++it) {
shortcut = new QShortcut(*it, this);
connect(shortcut, &QShortcut::activated,
ui->lineEdit, static_cast<void (SearchEdit::*)()>(&SearchEdit::setFocusByShortcut));
Expand Down

0 comments on commit bd67e80

Please sign in to comment.