Changeset 54 in tspsg-svn for trunk/src/mainwindow.h


Ignore:
Timestamp:
Aug 9, 2009, 1:45:19 AM (15 years ago)
Author:
laleppa
Message:
  • mainwindow.ui and mainwindow.ce.ui had differences only in printing actions and statusbar, so I merged them into one. Differences are now applied in source code. This will simplify Main Window maintenance.
  • Changed #ifndef Q_OS_WINCE to #ifndef QT_NO_PRINTER where relevant.
  • Now using method at() instead of operator [] in solving algorithm. This change dramatically decreased solution time (from 13 seconds to 10-40 milliseconds for 20 cities on my PC).
  • Increased maximum number of cities to 30. Setting more makes no sense at this moment, because generated solution output is big and inserting it to QTextEdit takes veeeeery long time.
  • Translations were updated.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/mainwindow.h

    r52 r54  
    2626
    2727#include "globals.h"
    28 #ifdef Q_OS_WINCE
    29         #include "ui_mainwindow.ce.h"
    30 #else
    31         #include "ui_mainwindow.h"
    32 #endif // Q_OS_WINCE
     28#include "ui_mainwindow.h"
    3329#include "settingsdialog.h"
    3430#include "tspsolver.h"
     
    5450        void actionHelpAboutTriggered();
    5551        void dataChanged();
    56 #ifndef Q_OS_WINCE
     52#ifndef QT_NO_PRINTER
    5753        void printPreview(QPrinter *);
    5854        void actionFilePrintPreviewTriggered();
    5955        void actionFilePrintTriggered();
    60 #endif // Q_OS_WINCE
     56#endif // QT_NO_PRINTER
    6157        void buttonSolveClicked();
    6258        void buttonRandomClicked();
     
    6763private:
    6864        QSettings *settings;
    69 #ifndef Q_OS_WINCE
     65#ifndef QT_NO_PRINTER
    7066        QPrinter *printer;
    71 #endif // Q_OS_WINCE
     67#endif // QT_NO_PRINTER
    7268        CTSPModel *tspmodel;
    7369        QString fileName;
Note: See TracChangeset for help on using the changeset viewer.