#include "mainwindow.h" #include "ui_mainwindow.h" #include MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); } MainWindow::~MainWindow() { delete ui; } void MainWindow::closeEvent(QCloseEvent *event) { if (ObserverClientModel->Connected) { ObserverClientModel->Finish(); } event->accept(); } void MainWindow::OpenMap() { QUrl url("C:/Workplace/Projects/k_observer/K-observer_client_qt/script.html"); ui->webView->settings()->setAttribute(QWebSettings::JavascriptEnabled, true); ui->webView->load(url); }