Merge branch 'master' of ssh://mercury.wipsl.com/var/git/irw
authorJari Jarvi <t7jaja00@students.oamk.fi>
Wed, 19 May 2010 13:16:42 +0000 (16:16 +0300)
committerJari Jarvi <t7jaja00@students.oamk.fi>
Wed, 19 May 2010 13:16:42 +0000 (16:16 +0300)
1  2 
src/mainwidget.cpp

@@@ -25,26 -26,15 +27,25 @@@ MainWidget::MainWidget (QWidget *parent
      connect(buttons[5], SIGNAL(clicked(bool)), &irCtrl, SLOT(sendCmd5(bool)));
  
      this->setLayout(layout);
 +    this->setAttribute(Qt::WA_TranslucentBackground);
  }
  
 + void MainWidget::paintEvent(QPaintEvent *event)
 + {
 +     QPainter p(this);
 +     p.setBrush(QColor(0, 0, 0, 128));
 +     p.setPen(Qt::NoPen);
 +     p.drawRoundRect(rect(), 10, 20);
 +     p.end();
 + }
 + 
  void MainWidget::showSettingsDialog()
  {
-     bool isOk;
-     QString newText = QInputDialog::getText(this, tr("New Text"),
-             tr("Please enter a new text:"), QLineEdit::Normal,
-             "foo", &isOk);
- //    if (isOk)
- //        setText(newText);
+     SettingsDlg dlg(this);
+     if (dlg.exec() == QDialog::Accepted)
+     {
+         irCtrl.setRemoteName(dlg.getRemoteName());
+     }
  }