| 1354 | |
| 1355 | |
| 1356 | NetHackQtStringRequestor::NetHackQtStringRequestor(NetHackQtKeyBuffer& ks, const char* p, const char* cancelstr) : |
| 1357 | QDialog(qApp->mainWidget(),"string",FALSE), |
| 1358 | prompt(p,this,"prompt"), |
| 1359 | input(this,"input"), |
| 1360 | keysource(ks) |
| 1361 | { |
| 1362 | cancel=new QPushButton(cancelstr,this); |
| 1363 | connect(cancel,SIGNAL(clicked()),this,SLOT(reject())); |
| 1364 | |
| 1365 | okay=new QPushButton("Okay",this); |
| 1366 | connect(okay,SIGNAL(clicked()),this,SLOT(accept())); |
| 1367 | connect(&input,SIGNAL(returnPressed()),this,SLOT(accept())); |
| 1368 | okay->setDefault(TRUE); |
| 1369 | |
| 1370 | setFocusPolicy(StrongFocus); |
| 1371 | } |
| 1372 | |
| 1373 | void NetHackQtStringRequestor::resizeEvent(QResizeEvent*) |
| 1374 | { |
nothing calls this directly
no test coverage detected