mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-01 06:30:26 +00:00
06eab74a72
So, this is what happens now: Every tab should be populated from updateDiveInfo method, it will be called whenever a new dive is selected I'm already populating the 'notes' box to show how it can be done. If you are unsure what's the name of anything, open the file maintab.ui on the designer, click on the item and check its objectName, the access is ui->objectName from here on. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
46 lines
703 B
C++
46 lines
703 B
C++
/*
|
|
* maintab.h
|
|
*
|
|
* header file for the main tab of Subsurface
|
|
*
|
|
*/
|
|
#ifndef MAINTAB_H
|
|
#define MAINTAB_H
|
|
|
|
#include <QTabWidget>
|
|
#include <QDialog>
|
|
|
|
#include "models.h"
|
|
|
|
namespace Ui
|
|
{
|
|
class MainTab;
|
|
}
|
|
|
|
class MainTab : public QTabWidget
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
MainTab(QWidget *parent);
|
|
void clearStats();
|
|
void clearInfo();
|
|
void clearEquipment();
|
|
void reload();
|
|
|
|
public Q_SLOTS:
|
|
void on_addCylinder_clicked();
|
|
void on_editCylinder_clicked();
|
|
void on_delCylinder_clicked();
|
|
void on_addWeight_clicked();
|
|
void on_editWeight_clicked();
|
|
void on_delWeight_clicked();
|
|
|
|
void updateDiveInfo(int dive);
|
|
|
|
private:
|
|
Ui::MainTab *ui;
|
|
WeightModel *weightModel;
|
|
CylindersModel *cylindersModel;
|
|
};
|
|
|
|
#endif
|