summaryrefslogtreecommitdiff
path: root/Tests/Wrapping/qtwrappingmain.cxx
blob: fabecfc72017b3abbb9823a918d33d9badab83f5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include <qapplication.h>
#include "qtwrapping.h"

#ifndef _WIN32
# include <stdlib.h>
# include <stdio.h>
#endif

int main(int argc, char *argv[])
{
#ifndef _WIN32
  const char* display = getenv("DISPLAY");
  if ( display && strlen(display)>0 )
    {
#endif
    QApplication app(argc,argv);

    qtwrapping qtw;
    app.setMainWidget(&qtw);
#ifndef _WIN32
    }
  else
    {
    printf("Environment variable DISPLAY is not set. I will pretend like the test passed, but you should really set it.\n");
    }
#endif

  return 0;
}