From: Norbert Moutarde Date: Wed, 22 Oct 2014 19:10:26 +0000 (+0200) Subject: fix a little bug X-Git-Url: https://git.nothing2do.fr/?a=commitdiff_plain;h=99c1b37863ea3b2ee3a2b8330e15d65987545c54;p=diary-mobile.git fix a little bug --- diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml index e4b8cda..1cec6ce 100644 --- a/android/AndroidManifest.xml +++ b/android/AndroidManifest.xml @@ -45,4 +45,5 @@ Remove the comment if you do not require these default features. --> + diff --git a/mainwindow.cpp b/mainwindow.cpp index df58f4e..c7cb90a 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -42,7 +42,7 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent) { qDebug()<<"begin of MainWindows"; conf=new QSettings(QString("FwF"), QString("diary-mobile"), this); - orientation=0; + orienta=0; if(conf->allKeys().size()==0){ qDebug()<<"first"; firstrun(); @@ -75,7 +75,7 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent) }; statusBar()->addPermanentWidget(label); menuBar()->setVisible(conf->value(QString("menu")).toBool()); - //start(); + start(); } void MainWindow::start(){ QString a=conf->value(QString("currenttype")).toString(); @@ -872,7 +872,7 @@ void MainWindow::resetRAW(){ exec(QList({"delete from raw;"})); } void MainWindow::get(const QString & a){ - const QString b=QInputDialog::getText(this, trUtf8("get", "title to ask keyword fot get"), trUtf8("Enter the keyword : ", "ask keyword to get buttons")); + const QString b=QInputDialog::getText(this, trUtf8("get", "title to ask keyword to get"), trUtf8("Enter the keyword : ", "ask keyword to get buttons")); get(a, b); } void MainWindow::insert(const QString & type, const QString & keyword, const QString & label, const QString & action){ @@ -968,12 +968,12 @@ void MainWindow::resizeEvent(QResizeEvent *event) { QSize size = event->size(); bool isLandscape = size.width() > size.height(); - if (isLandscape!=orientation){ + if (isLandscape!=orienta){ size.transpose(); const int a=conf->value(QString("maxcolumn")).toInt(); conf->setValue(QString("maxcolumn"), conf->value(QString("maxline")).toInt()); conf->setValue(QString("maxline"), a); - orientation=isLandscape; + orienta=isLandscape; flush(); if(lastprint[0]=='-')action(lastprint); else action('-'+lastprint); diff --git a/mainwindow.h b/mainwindow.h index 74e31e9..9cbf5ea 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -214,7 +214,7 @@ private: FileDownloader * m; QNetworkAccessManager *net; QNetworkReply * rep; - bool orientation;//0=portrait 1=paysage (size.width() > size.height()) + bool orienta;//0=portrait 1=paysage (size.width() > size.height()) unsigned short int deb; QVideoWidget * videoWidget; };