blob: 6dcae602bc892e3d7b7281fa1eb057e4777dd07a [file] [log] [blame]
Yingdi Yud95c5642013-10-20 19:43:10 -07001/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
2/*
3 * Copyright (c) 2013, Regents of the University of California
4 * Yingdi Yu
5 *
6 * BSD license, See the LICENSE file for more information
7 *
8 * Author: Yingdi Yu <yingdi@cs.ucla.edu>
9 */
10
Yingdi Yuab557b42013-10-18 19:03:08 -070011#include "warningdialog.h"
12#include "ui_warningdialog.h"
13
Yingdi Yud95c5642013-10-20 19:43:10 -070014using namespace std;
15
Yingdi Yuab557b42013-10-18 19:03:08 -070016WarningDialog::WarningDialog(QWidget *parent) :
17 QDialog(parent),
18 ui(new Ui::WarningDialog)
19{
Yingdi Yud95c5642013-10-20 19:43:10 -070020 ui->setupUi(this);
21
22 connect(ui->okButton, SIGNAL(clicked()),
23 this, SLOT(onOkClicked()));
Yingdi Yuab557b42013-10-18 19:03:08 -070024}
25
26WarningDialog::~WarningDialog()
27{
28 delete ui;
29}
30
Yingdi Yud95c5642013-10-20 19:43:10 -070031void
32WarningDialog::setMsg(const string& msg)
Yingdi Yue35bdb82013-11-07 11:32:40 -080033{ ui->message->setText(QString::fromStdString(msg)); }
Yingdi Yud95c5642013-10-20 19:43:10 -070034
35void
36WarningDialog::onOkClicked()
37{ this->hide(); }
38
Yingdi Yuab557b42013-10-18 19:03:08 -070039#if WAF
40#include "warningdialog.moc"
41#include "warningdialog.cpp.moc"
42#endif