Browse Source

Set 'Cancel' as the default button in the shutdown confirmation dialog.

adaptive-webui-19844
sledgehammer999 10 years ago
parent
commit
58ad90fa9c
  1. 2
      src/qtlibtorrent/shutdownconfirm.cpp

2
src/qtlibtorrent/shutdownconfirm.cpp

@ -52,6 +52,8 @@ ShutdownConfirmDlg::ShutdownConfirmDlg(const shutDownAction &action): exit_now(N
setIcon(QMessageBox::Warning); setIcon(QMessageBox::Warning);
// Always on top // Always on top
setWindowFlags(windowFlags()|Qt::WindowStaysOnTopHint); setWindowFlags(windowFlags()|Qt::WindowStaysOnTopHint);
// Set 'Cancel' as default button.
setDefaultButton(QMessageBox::Cancel);
timer.setInterval(1000); // 1sec timer.setInterval(1000); // 1sec
connect(&timer, SIGNAL(timeout()), this, SLOT(updateSeconds())); connect(&timer, SIGNAL(timeout()), this, SLOT(updateSeconds()));
show(); show();

Loading…
Cancel
Save