You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
500 B
26 lines
500 B
7 years ago
|
#include "tabitemview.h"
|
||
|
#include "ui_tabitemview.h"
|
||
|
#include <QtMvvmCore/Binding>
|
||
|
|
||
|
TabItemView::TabItemView(QtMvvm::ViewModel *viewModel, QWidget *parent) :
|
||
|
QWidget(parent),
|
||
|
_viewModel(static_cast<TabItemViewModel*>(viewModel)),
|
||
|
ui(new Ui::TabItemView)
|
||
|
{
|
||
|
ui->setupUi(this);
|
||
|
|
||
|
QtMvvm::bind(_viewModel, "title",
|
||
|
ui->checkBox, "text",
|
||
|
QtMvvm::Binding::OneWayToView);
|
||
|
}
|
||
|
|
||
|
TabItemView::~TabItemView()
|
||
|
{
|
||
|
delete ui;
|
||
|
}
|
||
|
|
||
|
TabItemViewModel *TabItemView::viewModel() const
|
||
|
{
|
||
|
return _viewModel;
|
||
|
}
|