Example #1
0
// return true if loaded file, false if not loaded
bool LoadChecklist(short checklistmode) {
  TCHAR filename[MAX_PATH];

  switch(checklistmode) {
	// notepad
	case 0:
		LocalPath(filename, TEXT(LKD_CONF));
		_tcscat(filename,_T("\\"));
		_tcscat(filename,_T(LKF_CHECKLIST));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M878_")));  // notepad
    return LoadAsciiChecklist(filename);
	// logbook TXT
	case 1:
		LocalPath(filename, TEXT(LKD_LOGS));
		_tcscat(filename,_T("\\"));
		_tcscat(filename,_T(LKF_LOGBOOKTXT));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M1748_")));  // logbook
   		 return LoadUtfChecklist(filename);
	// logbook LST
	case 2:
		LocalPath(filename, TEXT(LKD_LOGS));
		_tcscat(filename,_T("\\"));
		_tcscat(filename,_T(LKF_LOGBOOKLST));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M1748_")));  // logbook
		return LoadUtfChecklist(filename);
		break;
  default:
    StartupStore(_T("... Invalid checklist mode (%d)%s"),checklistmode,NEWLINE);
    return false;
  }
}
Example #2
0
// return true if loaded file, false if not loaded
bool LoadChecklist(short checklistmode) {
  TCHAR filename[MAX_PATH];

  switch(checklistmode) {
	// notepad
	case 0:
		LocalPath(filename, TEXT(LKD_CONF));
		_tcscat(filename,_T(DIRSEP));
		_tcscat(filename,_T(LKF_CHECKLIST));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M878_")));  // notepad
		#ifdef __linux__
   		return LoadUtfChecklist(filename);
		#else
                return LoadAsciiChecklist(filename);
		#endif
	// logbook TXT
	case 1:
		LocalPath(filename, TEXT(LKD_LOGS));
		_tcscat(filename,_T(DIRSEP));
		_tcscat(filename,_T(LKF_LOGBOOKTXT));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M1748_")));  // logbook
   		 return LoadUtfChecklist(filename);
	// logbook LST
	case 2:
		LocalPath(filename, TEXT(LKD_LOGS));
		_tcscat(filename,_T(DIRSEP));
		_tcscat(filename,_T(LKF_LOGBOOKLST));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("_@M1748_")));  // logbook
		return LoadUtfChecklist(filename);
		break;
	case 3:
		SystemPath(filename, TEXT(LKD_SYSTEM));
		_tcscat(filename,_T(DIRSEP));
		_tcscat(filename,_T(LKF_CREDITS));
		_stprintf(NoteModeTitle,_T("%s"),gettext(_T("Credits")));
		#ifdef __linux__
   		return LoadUtfChecklist(filename);
		#else
                return LoadAsciiChecklist(filename);
		#endif
		break;
  default:
    StartupStore(_T("... Invalid checklist mode (%d)%s"),checklistmode,NEWLINE);
    return false;
  }
}