rxantos
rxantos
Reputation Top 10%
rxantos
1 Snippet  (374th place)
Published
1 Channel
Created
2 Channels
Following
5 hours ago
Last Visit
Nov 19, 2017
Registered
31 points  (1007th place)
Reputation
Junior Code Generator
Junior Publisher
Junior Trend Maker
Junior Autobiographer
Serious Autobiographer
Junior Snip2Coder

Recent Snippets See all snippets by rxantos

public by rxantos created Nov 19, 2017  93  0  2  0

Console Application template windows. Main file.

Requires stdafx.h
#include "stdafx.h"
/**
 * @file
 * @brief Program entry point.
 */

#pragma region Declaration
/**
 * Program entry point.
 * @param [in] argc Number of arguments.
 * @param [in] argv Arguments.
 * @return 0 on success. 1 - 255 Error code.
 */
int main(int argc, char * argv[]);

/**
 * Initializes a program.
 * @param [in] argc Number of arguments.
 * @param [in] argv Arguments.
 * @return 0 on success. 1 - 255 Error code.
 */
static int Init(int argc, const char * argv[]);

/**
 * Cleans up for the program. 
 */
static void Cleanup(void);

/**
 * Main loop.
 */
static void MainLoop(void);

#pragma endregion

#pragma region Implementation

int main(int argc, char * argv[])
{
	int r = Init(argc, argv);
	
	if(!r) {
		MainLoop();
	}
	
	Cleanup();
	
	return r;
}

static int Init(int argc, const char * argv[])
{
	UNREFERENCED_PARAMETER(argc);
	UNREFERENCED_PARAMETER(argv);
	return 0;
}

static void Cleanup(void)
{
}

static void MainLoop(void)
{
}

#pragma endregion
;