Exemplo n.º 1
0
 void ProgramVersion::ShowVersionWindow ()
 {
   QString versionMessage(Version());
   QMessageBox box;
   box.setText (versionMessage);
   QTimer::singleShot(30000,&box,SLOT(accept()));
   box.exec();
 }
Exemplo n.º 2
0
static void ShowVersion()
{
#if defined(_WIN32)
    AboutDialog *dlg = new AboutDialog(CppCheck::version(), CppCheck::extraVersion(), 0);
    dlg->exec();
    delete dlg;
#else
    std::string versionMessage("Cppcheck ");
    versionMessage += CppCheck::version();
    const char * extraVersion = CppCheck::extraVersion();
    if (*extraVersion != 0)
        versionMessage += std::string(" (") + extraVersion + ")";

    std::cout << versionMessage << std::endl;
#endif
}
Exemplo n.º 3
0
int main(int argc,  char  *argv[]) {
FILE *f;
extern void initGlobalStructure(void);
extern void setMetaKeyOptions(int swap);
	parseArguments( argv, argc, args);

	if (versionMe) versionMessage(vmPath);
	if (helpMe) helpMessage(vmPath, "!Help");

	atexit(exit_function);   // setup a clean exit function

	InitRiscOS();
	initGlobalStructure();

	dummyWimpPoll();

	/* read the image file and allocate memory for Squeak heap
	    - the image name has been set to the path parsed by c.sqArgument
	    - if no filename was passed in, the default is to expect an image
	      file (Squeak/image) inside the application directory */
	f = fopen(imageName, "rb");
	PRINTF(("\\t Starting Squeak with image file: %s\n", imageName));
	if (f == NULL) {
		/* give a RPC error message if image file is not found */
		extern char VMVersion[];
		privateErr.errnum = (bits)0;
		sprintf(privateErr.errmess, "Could not open the Squeak image file '%s' (Squeak version: %s)", imageName, VMVersion);
		printf("Squeak version: %s was unable to find and open the image file supposedly at %s\n", VMVersion, imageName);
		printf("If you simply tried to run the !Squeak application, it will have attempted to run a default image within the application directory which is not usually present\n");
		platReportError((os_error *)&privateErr);
		helpMessage(vmPath, "!ImName");
		ioExit();
	}

	setMetaKeyOptions(swapMeta);

	readImageFromFileHeapSize(f, objectHeadroom);
	fclose(f);

	/* run Squeak */
	PRINTF(("\\t start running image\n"));

	interpret();
}
Exemplo n.º 4
0
int main(int argc,  char  *argv[]) {
FILE *f;
extern void initGlobalStructure(void);
extern void setMetaKeyOptions(int swap);
	parseArguments( argv, argc, args);

	if (versionMe) versionMessage(vmPath);
	if (helpMe) helpMessage(vmPath, "!Help");

	atexit(exit_function);   // setup a clean exit function

	InitRiscOS();
	initGlobalStructure();

	dummyWimpPoll();

	/* read the image file and allocate memory for Squeak heap */
	f = fopen(imageName, "rb");
	PRINTF(("\\t Starting Squeak with image file: %s\n", imageName));
	if (f == NULL) {
		/* give a RPC error message if image file is not found */
		extern char VMVersion[];
		privateErr.errnum = (bits)0;
		sprintf(privateErr.errmess, "Could not open the Squeak image file '%s' (Squeak version: %s)", imageName, VMVersion);
		printf("%s\n", privateErr.errmess);
		platReportError((os_error *)&privateErr);
		helpMessage(vmPath, "!ImName");
		ioExit();
	}

	setMetaKeyOptions(swapMeta);

	readImageFromFileHeapSize(f, objectHeadroom);
	fclose(f);

	/* run Squeak */
	PRINTF(("\\t start running image\n"));

	interpret();
}