mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Untangle profile from MainWindow: work around print mode
Since we don't support printing in subsurface-mobile this solves the problem at hand - but it doesn't do what we really want which is to untangle the Profile from the MainWindow. Partial credit. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3ef9e07380
commit
ae709ab30e
1 changed files with 8 additions and 0 deletions
|
@ -4,9 +4,13 @@
|
||||||
#include "preferences/preferencesdialog.h"
|
#include "preferences/preferencesdialog.h"
|
||||||
#include "diveplotdatamodel.h"
|
#include "diveplotdatamodel.h"
|
||||||
#include "animationfunctions.h"
|
#include "animationfunctions.h"
|
||||||
|
#ifndef SUBSURFACE_MOBILE
|
||||||
#include "mainwindow.h"
|
#include "mainwindow.h"
|
||||||
|
#endif
|
||||||
#include "divelineitem.h"
|
#include "divelineitem.h"
|
||||||
#include "profilewidget2.h"
|
#include "profilewidget2.h"
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QGraphicsWidget>
|
||||||
|
|
||||||
QPen DiveCartesianAxis::gridPen()
|
QPen DiveCartesianAxis::gridPen()
|
||||||
{
|
{
|
||||||
|
@ -144,7 +148,11 @@ void emptyList(QList<T *> &list, double steps)
|
||||||
|
|
||||||
void DiveCartesianAxis::updateTicks(color_indice_t color)
|
void DiveCartesianAxis::updateTicks(color_indice_t color)
|
||||||
{
|
{
|
||||||
|
#ifndef SUBSURFACE_MOBILE
|
||||||
if (!scene() || (!changed && !MainWindow::instance()->graphics()->getPrintMode()))
|
if (!scene() || (!changed && !MainWindow::instance()->graphics()->getPrintMode()))
|
||||||
|
#else
|
||||||
|
if (!scene() || !changed)
|
||||||
|
#endif
|
||||||
return;
|
return;
|
||||||
QLineF m = line();
|
QLineF m = line();
|
||||||
// unused so far:
|
// unused so far:
|
||||||
|
|
Loading…
Add table
Reference in a new issue