mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-01 01:33:23 +00:00
Enable the location edit widget on mainwindow
Clicking on the 'Manage' button now brings you to the widget to manage it. Nothing has been added on it yet. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
e3d800885f
commit
7d66dcd12d
5 changed files with 13 additions and 5 deletions
|
@ -49,6 +49,8 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent),
|
|||
ui.extraData->setModel(extraDataModel);
|
||||
closeMessage();
|
||||
|
||||
connect(ui.manageDiveSite, SIGNAL(clicked()), this, SIGNAL(requestDiveSiteEdit()));
|
||||
|
||||
QAction *action = new QAction(tr("Apply changes"), this);
|
||||
connect(action, SIGNAL(triggered(bool)), this, SLOT(acceptChanges()));
|
||||
addMessageAction(action);
|
||||
|
|
|
@ -55,7 +55,7 @@ public:
|
|||
signals:
|
||||
void addDiveFinished();
|
||||
void dateTimeChanged();
|
||||
|
||||
void requestDiveSiteEdit();
|
||||
public
|
||||
slots:
|
||||
void addCylinder_clicked();
|
||||
|
|
|
@ -131,7 +131,7 @@
|
|||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton">
|
||||
<widget class="QPushButton" name="manageDiveSite">
|
||||
<property name="text">
|
||||
<string>manage</string>
|
||||
</property>
|
||||
|
@ -400,7 +400,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>454</width>
|
||||
<width>443</width>
|
||||
<height>752</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -456,7 +456,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>454</width>
|
||||
<width>443</width>
|
||||
<height>752</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -773,7 +773,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>454</width>
|
||||
<width>443</width>
|
||||
<height>752</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
|
|
@ -111,6 +111,7 @@ MainWindow::MainWindow() : QMainWindow(),
|
|||
connect(DivePlannerPointsModel::instance(), SIGNAL(planCreated()), this, SLOT(planCreated()));
|
||||
connect(DivePlannerPointsModel::instance(), SIGNAL(planCanceled()), this, SLOT(planCanceled()));
|
||||
connect(plannerDetails->printPlan(), SIGNAL(pressed()), divePlannerWidget(), SLOT(printDecoPlan()));
|
||||
connect(mainTab, SIGNAL(requestDiveSiteEdit()), this, SLOT(enableDiveSiteEdit()));
|
||||
#ifdef NO_PRINTING
|
||||
ui.printPlan->hide();
|
||||
ui.menuFile->removeAction(ui.actionPrint);
|
||||
|
@ -212,6 +213,10 @@ LocationInformationWidget *MainWindow::locationInformationWidget() {
|
|||
return qobject_cast<LocationInformationWidget*>(applicationState["EditDiveSite"].topLeft);
|
||||
}
|
||||
|
||||
void MainWindow::enableDiveSiteEdit() {
|
||||
setApplicationState("EditDiveSite");
|
||||
}
|
||||
|
||||
void MainWindow::setLoadedWithFiles(bool f)
|
||||
{
|
||||
filesAsArguments = f;
|
||||
|
|
|
@ -159,6 +159,7 @@ slots:
|
|||
void on_paste_triggered();
|
||||
void on_actionFilterTags_triggered();
|
||||
void on_actionConfigure_Dive_Computer_triggered();
|
||||
void enableDiveSiteEdit();
|
||||
|
||||
protected:
|
||||
void closeEvent(QCloseEvent *);
|
||||
|
|
Loading…
Add table
Reference in a new issue