summaryrefslogtreecommitdiffhomepage
path: root/protocol-mouse/ftnoir_protocol_mouse_dialog.cpp
blob: bb5fe3b891b789f2c9edbb7dcc2b2140627dd3b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include "ftnoir_protocol_mouse.h"
#include "opentrack/plugin-api.hpp"

MOUSEControls::MOUSEControls()
{
    ui.setupUi( this );

    connect(ui.buttonBox, SIGNAL(accepted()), this, SLOT(doOK()));
    connect(ui.buttonBox, SIGNAL(rejected()), this, SLOT(doCancel()));

    tie_setting(s.Mouse_X, ui.cbxSelectMouse_X);
    tie_setting(s.Mouse_Y, ui.cbxSelectMouse_Y);
}

void MOUSEControls::doOK() {
    s.b->save();
    this->close();
}

void MOUSEControls::doCancel() {
    s.b->reload();
    this->close();
}