|
@@ -82,11 +82,23 @@ void MainAndSecondaryCamerasWnd::initFrom()
|
|
|
int groupId = settings.value("GroupId", 0).toInt();
|
|
|
int index = settings.value("Index", 0).toInt();
|
|
|
|
|
|
- checkSettings();
|
|
|
+
|
|
|
|
|
|
+ if (m_allGroup.size() == 1) {
|
|
|
+ if (lastGroupId == lastLastGroupId) {
|
|
|
+ GetCurrentSelectSlots(lastLastGroupId, lastLastIndex);
|
|
|
+ GetCurrentSelectSlots(lastGroupId, lastIndex);
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ GetCurrentSelectSlots(lastGroupId, lastIndex);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ GetCurrentSelectSlots(lastLastGroupId, lastLastIndex);
|
|
|
+ GetCurrentSelectSlots(lastGroupId, lastIndex);
|
|
|
+ }
|
|
|
+ checkSettings();
|
|
|
|
|
|
- GetCurrentSelectSlots(lastLastGroupId, lastLastIndex);
|
|
|
- GetCurrentSelectSlots(lastGroupId, lastIndex);
|
|
|
}
|
|
|
|
|
|
void MainAndSecondaryCamerasWnd::InitPage()
|
|
@@ -485,7 +497,7 @@ void MainAndSecondaryCamerasWnd::GetCurrentSelectSlots(int groupId, int nIndex)
|
|
|
//解绑
|
|
|
disconnect(m_veCurrentSelectGroup_R.pSelectGroup, &Group::SetUpDataImageShowSig,
|
|
|
this, &MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals4);
|
|
|
- m_veCurrentSelectGroup_L = m_veCurrentSelectGroup_R;
|
|
|
+
|
|
|
//换绑
|
|
|
connect(m_veCurrentSelectGroup_L.pSelectGroup, &Group::SetUpDataImageShowSig,
|
|
|
this, &MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals0);
|
|
@@ -526,6 +538,10 @@ void MainAndSecondaryCamerasWnd::GetCurrentSelectSlots(int groupId, int nIndex)
|
|
|
|
|
|
}else {
|
|
|
if (m_veCurrentSelectGroup_R.isInitialed == true) {
|
|
|
+ if (m_veCurrentSelectGroup_L.isBond == true) {
|
|
|
+ disconnect(m_veCurrentSelectGroup_L.pSelectGroup, &Group::SetUpDataImageShowSig,
|
|
|
+ this, &MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals0);
|
|
|
+ }
|
|
|
m_veCurrentSelectGroup_L = m_veCurrentSelectGroup_R;
|
|
|
UpdataLightJoystickSwitchPage(m_veCurrentSelectGroup_L.pSelectGroup->m_nGroupId, 1, false);
|
|
|
}
|
|
@@ -677,7 +693,10 @@ void MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals0(const QPixmap& image
|
|
|
//lastIndex = 1;
|
|
|
QSize size_left = ui->viewwidgetgroup_L->getOperatewidget()->size();
|
|
|
QPixmap scaledPixmap_left = m_lastRightPixmap.scaled(size_left, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
|
|
- ui->viewwidgetgroup_L->getOperatewidget()->setPixmap(scaledPixmap_left);
|
|
|
+ //ui->viewwidgetgroup_L->getOperatewidget()->setPixmap(scaledPixmap_left);
|
|
|
+ ui->viewwidgetgroup_L->setScaleFactorSize(scaledPixmap_left);
|
|
|
+
|
|
|
+
|
|
|
m_lastRightPixmap = imageData;
|
|
|
//UpdataGroupSettings(imageData);
|
|
|
}
|
|
@@ -691,8 +710,9 @@ void MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals1(const QPixmap& image
|
|
|
void MainAndSecondaryCamerasWnd::GetUpDataImageShowSignals4(const QPixmap& imageData)
|
|
|
{
|
|
|
QSize size_left = ui->viewwidgetgroup_R->getOperatewidget()->size();
|
|
|
- QPixmap scaledPixmap_left = imageData.scaled(size_left, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
|
|
- ui->viewwidgetgroup_R->getOperatewidget()->setPixmap(scaledPixmap_left);
|
|
|
+ QPixmap scaledPixmap_right = imageData.scaled(size_left, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
|
|
+ //ui->viewwidgetgroup_R->getOperatewidget()->setPixmap(scaledPixmap_left);
|
|
|
+ ui->viewwidgetgroup_R->setScaleFactorSize(scaledPixmap_right);
|
|
|
m_lastRightPixmap = imageData;
|
|
|
}
|
|
|
|