Skip to content

Instantly share code, notes, and snippets.

@nullcoding
Created August 21, 2012 21:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nullcoding/3419700 to your computer and use it in GitHub Desktop.
Save nullcoding/3419700 to your computer and use it in GitHub Desktop.
Genesis Example
#include "Genesis.h"
#include "stdafx.h"
#include "resource.h"
#include "includer.h"
#include "cpufinder.h"
using namespace std;
wchar_t* enterk = L"k...";
wchar_t* entern = L"n...";
wchar_t* prothdesctext = L"formula...";
wchar_t* DispCPU = new WCHAR[128];
HWND kbox, nbox, formulabox, factors, isprime, bignum, digits, CPU, otherfac, savestat; // edit boxes
HWND calcbutton, HardWorker, PANIC, clear, InstButton, saveformb; // buttons
HWND kdesc, ndesc, prothdesc; // static text
HWND ProthProgress, hStatus; // common controls
HWND WebWin; // Web Window (popup)
int Statwidths[] = {150, 300, 550, 800, -1};
void Proth_OnCommand_Create (HWND pWnd) {
//create status bar
hStatus = CreateWindowEx(NULL, STATUSCLASSNAME, NULL, WS_CHILD | WS_VISIBLE |
SBARS_SIZEGRIP, CW_USEDEFAULT, 650, CW_USEDEFAULT, CW_USEDEFAULT,
pWnd, (HMENU)IDC_MAIN_STATUS,
GetModuleHandle(NULL), NULL);
SendMessage(hStatus, SB_SETPARTS, (WPARAM)(sizeof(Statwidths)/sizeof(int)), (LPARAM)Statwidths);
SendMessage((HWND) hStatus, (UINT) SB_SETTEXT, (WPARAM)(INT) 0 | 0,
(LPARAM) (LPSTR) TEXT("Welcome to GJSieve 1.9.0!"));
// etc...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment