Omr::Omr(const QString& p, Score* s) { _score = s; _path = p; _ocr = 0; initUtils(); }
Omr::Omr(const QString& p, Score* s) { _score = s; _path = p; _ocr = 0; ActionNames = QList<QString>()<< QWidget::tr("Loading PDF") << QWidget::tr("Initializing Staves") << QWidget::tr("Load Parameters") << QWidget::tr("Identifying Systems"); initUtils(); }
Omr::Omr(Score* s) { _score = s; #ifdef OCR _ocr = 0; #endif initUtils(); }
Omr::Omr(Score* s) { _score = s; #ifdef OCR _ocr = 0; #endif ActionNames = QList<QString>() << QWidget::tr("Loading PDF") << QWidget::tr("Initializing Staves") << QWidget::tr("Identifying Systems"); initUtils(); }
int module_start( SceSize args, void *argp ) { int fw = initPatches(); sceIoAssign("ms0:", "msstor0p1:", "fatms0:", IOASSIGN_RDWR, NULL, 0); log( "Firmware Version: %08x\n", fw ); cxmb_magic = getMagic(); if ( cxmb_magic == 0 ) { log( "Not supported firmware version!\n" ); } log( "CXMB Magic: %08x\n", cxmb_magic ); initUtils(); install_cxmb(); int thid = sceKernelCreateThread("cxmb_thread", main_thread, 47, 0x400, 0x00100001, NULL); if( thid >= 0 ) sceKernelStartThread(thid, 0, 0); return 0; }
void initFile(int fl) { UFILE *fp; initUtils(fl); //need the error stuff from Utils //#ifndef _WIN32 //int i; //init file structure - do we need this? //for( i=0; i < OPEN_MAX; i++ ) //{ // _iob[i].ptr = (char *)((dword)(_iob[i].ptr) + _tap_startAddr); // _iob[i].base = (char *)((dword)(_iob[i].base) + _tap_startAddr); // _iob[i].fd = (TYPE_File *)((dword)(_iob[i].fd) + _tap_startAddr); //} //#endif for (fp = _iob; fp < _iob + OPEN_MAX; fp++) { //fp->base = NULL; seems to screw stdout?? fp->cnt = 0; fp->flag = 0; } }
BOOL CWinLauncher2App::InitInstance() { // InitCommonControlsEx() is required on Windows XP if an application // manifest specifies use of ComCtl32.dll version 6 or later to enable // visual styles. Otherwise, any window creation will fail. INITCOMMONCONTROLSEX InitCtrls; InitCtrls.dwSize = sizeof(InitCtrls); // Set this to include all the common control classes you want to use // in your application. InitCtrls.dwICC = ICC_WIN95_CLASSES; InitCommonControlsEx(&InitCtrls); CWinApp::InitInstance(); AfxEnableControlContainer(); // Create the shell manager, in case the dialog contains // any shell tree view or shell list view controls. CShellManager *pShellManager = new CShellManager; // Activate "Windows Native" visual manager for enabling themes in MFC controls CMFCVisualManager::SetDefaultManager(RUNTIME_CLASS(CMFCVisualManagerWindows)); // Set CWinApp default registry key. Must be consistent with all apps using findjava2. SetRegistryKey(_T("Android-FindJava2")); // Use VERSIONINFO.FileDescription as the canonical app name initUtils(NULL); CLauncherCmdLineInfo cmdLine; ParseCommandLine(cmdLine); if (cmdLine.mDoHelp) { const TCHAR *msg = _T("WinLauncher2 [/7|/f|/h]\r\n") _T("/7 : Requires Java 1.7 instead of 1.6\r\n") _T("/f : Force UI\r\n") _T("/h : Help\r\n"); AfxMessageBox(msg); return FALSE; // quit without starting MFC app msg loop } CJavaFinder javaFinder(JAVA_VERS_TO_INT(1, cmdLine.mDoJava1_7 ? 7 : 6)); CJavaPath javaPath = javaFinder.getRegistryPath(); if (cmdLine.mDoForceUi || javaPath.isEmpty()) { javaPath.clear(); CFindJava2Dlg dlg; dlg.setJavaFinder(&javaFinder); m_pMainWnd = &dlg; INT_PTR nResponse = dlg.DoModal(); if (nResponse == IDOK) { // Use choice selected by user and save in registry. javaPath = dlg.getSelectedPath(); javaFinder.setRegistryPath(javaPath); } else if (nResponse == IDCANCEL) { // Canceled by user, exit silently. } else if (nResponse == -1) { TRACE(traceAppMsg, 0, "Warning: dialog creation failed, so application is terminating unexpectedly.\n"); } } if (!javaPath.isEmpty()) { // TODO actually launch configured app instead of just printing path. CString msg(_T("PLACEHOLDER TODO run app using ")); msg.Append(javaPath.mPath); AfxMessageBox(msg); } // Delete the shell manager created above. if (pShellManager != NULL) { delete pShellManager; } // Since the dialog has been closed, return FALSE so that we exit the // application, rather than start the application's message pump. return FALSE; }
extern "C" LUAMBEDTLS_DLL_EXPORTED int luaopen_luambedtls(lua_State * L){ State * state = new State(L); Stack * stack = state->stack; Module luambedtls_module; stack->newTable(); initMPI(state, luambedtls_module); initASN1buf(state, luambedtls_module); initASN1named(state, luambedtls_module); initASN1sequence(state, luambedtls_module); //key-pairs initPKContext(state, luambedtls_module); initPKinfo(state, luambedtls_module); initCTRDRBGContext(state, luambedtls_module); initDHMContext(state, luambedtls_module); initEntropyContext(state, luambedtls_module); initSSLConfig(state, luambedtls_module); initSSLContext(state, luambedtls_module); initSSLCookieContext(state, luambedtls_module); initSSLSession(state, luambedtls_module); initx509crt(state, luambedtls_module); initx509crl(state, luambedtls_module); initx509crlEntry(state, luambedtls_module); initx509crtProfile(state, luambedtls_module); initx509csr(state, luambedtls_module); initx509writeCert(state, luambedtls_module); initx509writeCSR(state, luambedtls_module); initTimingDelayContext(state, luambedtls_module); initAESContext(state, luambedtls_module); //symmetric-encryption initARC4Context(state, luambedtls_module); initBlowfishContext(state, luambedtls_module); initCamelliaContext(state, luambedtls_module); initDESContext(state, luambedtls_module); initDES3Context(state, luambedtls_module); initGCMContext(state, luambedtls_module); initXTEAContext(state, luambedtls_module); //asymmetric-ecnryption initDHMContext(state, luambedtls_module); initRSAContext(state, luambedtls_module); //EC initECPCurveInfo(state, luambedtls_module); initECPPoint(state, luambedtls_module); initECPGroup(state, luambedtls_module); initECPKeyPair(state, luambedtls_module); initECDHContext(state, luambedtls_module); initECSDAContext(state, luambedtls_module); //message-digest initMDContext(state, luambedtls_module); initMDinfo(state, luambedtls_module); //cipher initCipherContext(state, luambedtls_module); initCipherInfo(state, luambedtls_module); //utils initUtils(state, luambedtls_module); luambedtls_module["init"] = init; initConstants(state, luambedtls_module); luambedtls_module["strError"] = strError; luambedtls_module["debugTreshhold"] = debugTreshhold; luambedtls_module["MPIlen"] = MPIlen; luambedtls_module["pushOIDAttrShortName"] = pushOIDAttrShortName; luambedtls_module["pushOIDNumericString"] = pushOIDNumericString; luambedtls_module["pushOIDExtType"] = pushOIDExtType; luambedtls_module["pushOIDPkAlg"] = pushOIDPkAlg; state->registerLib(luambedtls_module); return 1; }
int TAP_Main(void) { char buffer[MAX_LEN]; char iniBuff[MAX_LEN]; int length, i; char last = '\0'; char* nextKey; char* appname = "test"; char* filename = "testINI.ini"; printf("Starting TestINI test...\r\n\r\n"); PrintMem(); printf("initing utils package...\r\n"); initUtils(_INFO); PrintMem(); //this *should* delete the entire section //ret = WritePrivateProfileString(appname, (char*) NULL, buffer, filename); /* if (!TAP_Hdd_Exist(filename)) { TAP_Hdd_Create(filename, ATTR_NORMAL); } if (WritePrivateProfileString(appname, "key1", "value1", filename) > 0) { //WritePrivateProfileString(appname, "key2", "value2", filename); } else { printf("Error from WritePrivateProfileString: %s\r\n", GetLastErrorString()); return 0; } printf("after writeprivate...\r\n"); PrintMem(); */ buffer[0]='\0'; printf("calling GetPrivateProileString, appname = %s\r\n", appname); if ((length = GetPrivateProfileString(appname, (char*) NULL, (char*) NULL, buffer, sizeof(buffer), filename)) <= 0) { printf("Error from GetPrivateProfile: %s\r\n", GetLastErrorString()); return 0; } printf("Getting keys...\r\n"); nextKey = buffer; // final dir is marked with double null while(strlen(nextKey)>0) { printf("Found keys = %s. Getting value\r\n", nextKey); if (GetPrivateProfileString(appname, nextKey, "", iniBuff, sizeof(iniBuff), filename) > 0) { printf("Found %s = %s\r\n", nextKey, iniBuff); //check for commas in next version //attach to key structure } nextKey += strlen(nextKey) + 1; } printf("Ending test\r\n"); PrintMem(); return 0; }