Ignore:
Timestamp:
Sep 22, 2015, 10:01:17 PM (11 years ago)
Author:
Joachim Langenbach <joachim.langenbach@…>
Branches:
master
Children:
17ef75d
Parents:
fb602c6
Message:

Command line client is now (nearly) able to register a station

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/clientcommandline/main.cpp

    rfb602c6 r93ea008  
    1818*/
    1919
    20 // #include "testexecuter.h"
    21 // #include <settings.h>
     20#include "siweatherclientconfig.h"
    2221
    23 #include "siweatherclientconfig.h"
     22#include "stationsregister.h"
    2423
    2524#include <ecmdlineargs.h>
    … …  
    2928#include <QCoreApplication>
    3029#include <QTimer>
     30#include <QTextStream>
     31
     32#include <iostream>
    3133
    3234int main ( int argc, char** argv )
    … …  
    4446                return 1;
    4547
    46 
    4748        QCoreApplication app(argc, argv);
    4849        QString error;
    … …  
    5051
    5152        if(args->isSet("register")){
    52 //              StationsRegister *stationsRegister = new StationsRegister();
     53                StationsRegister *stationsRegister = new StationsRegister();
     54                QTimer::singleShot(1, stationsRegister, SLOT(registerStation()));
    5355        }
    5456//      else if(){
    5557//             
    5658//      }
     59        else{
     60                QTextStream stream(stdout);
     61                stream << "Please specify an option" << endl;
     62                return -2;
     63        }
    5764
    58 //      TestExecuter test;
    5965        // allow to start the event loop before executing our code
    60 //      QTimer::singleShot(1, &test, SLOT(load()));
    6166        return app.exec();
    6267}
Note: See TracChangeset for help on using the changeset viewer.