Commit b6e9bef6 authored by Pino Toscano's avatar Pino Toscano

SunControlWidget: use QDialogButtonBox

parent 579d5ac3
......@@ -16,6 +16,7 @@
#include "ui_SunControlWidget.h"
// Qt
#include <QPushButton>
#include <QShowEvent>
// Marble
......@@ -35,10 +36,10 @@ SunControlWidget::SunControlWidget( MarbleWidget* marbleWidget, QWidget* parent
m_uiWidget->lockWarningLabel->hide();
connect( m_uiWidget->applyButton, SIGNAL(clicked()), this, SLOT(apply()) );
connect( m_uiWidget->cancelButton, SIGNAL(clicked()), this, SLOT(reject()) );
connect( m_uiWidget->okButton, SIGNAL(clicked()), this, SLOT(apply()) );
connect( m_uiWidget->okButton, SIGNAL(clicked()), this, SLOT(accept()) );
connect( m_uiWidget->buttonBox->button(QDialogButtonBox::Apply), SIGNAL(clicked()), this, SLOT(apply()) );
connect( m_uiWidget->buttonBox, SIGNAL(reject()), this, SLOT(reject()) );
connect( m_uiWidget->buttonBox->button(QDialogButtonBox::Ok), SIGNAL(clicked()), this, SLOT(apply()) );
connect( m_uiWidget->buttonBox->button(QDialogButtonBox::Ok), SIGNAL(clicked()), this, SLOT(accept()) );
setModal( false );
......
......@@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>333</width>
<height>323</height>
<height>399</height>
</rect>
</property>
<property name="sizePolicy">
......@@ -23,7 +23,7 @@
<item>
<widget class="QGroupBox" name="sunShading">
<property name="title">
<string>Sun Shading</string>
<string>S&amp;un Shading</string>
</property>
<property name="checkable">
<bool>true</bool>
......@@ -38,7 +38,7 @@
<string/>
</property>
<property name="text">
<string>Shadow</string>
<string>Sha&amp;dow</string>
</property>
<property name="checked">
<bool>true</bool>
......@@ -51,7 +51,7 @@
<string/>
</property>
<property name="text">
<string>Night Map</string>
<string>&amp;Night Map</string>
</property>
</widget>
</item>
......@@ -271,48 +271,11 @@ p, li { white-space: pre-wrap; }
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="okButton">
<property name="text">
<string>OK</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="applyButton">
<property name="text">
<string>Apply</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="cancelButton">
<property name="text">
<string>Cancel</string>
</property>
<property name="checkable">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="standardButtons">
<set>QDialogButtonBox::Apply|QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>
</layout>
</widget>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment