shbtn_prefs.remove_all_objects();
int shbtns_total = defaults->get("SHBTNS_TOTAL", -1);
if( shbtns_total < 0 ) {
- shbtn_prefs.append(new ShBtnPref("manual", "firefox file:///$CINELERRA_PATH/manual.pdf", 0));
- shbtn_prefs.append(new ShBtnPref("online help", "firefox http://cinelerra.org/help.php/", 0));
+// shbtn_prefs.append(new ShBtnPref("manual", "firefox file:///$CINELERRA_PATH/manual.pdf", 0));
+ shbtn_prefs.append(new ShBtnPref("online help", "firefox https://cinelerra-cv.org/docs/cinelerra_cv_manual_en.html", 0));
shbtns_total = 0;
}
for( int i=0; i<shbtns_total; ++i ) {
int Preferences::get_asset_file_path(Asset *asset, char *path)
{
strcpy(path, asset->path);
- int result = access(path, R_OK);
+ int result = !access(path, R_OK) ? 0 : -1;
if( !result && asset->format == FILE_MPEG ) {
- char source_filename[BCTEXTLEN];
- char index_filename[BCTEXTLEN];
+ char source_filename[BCTEXTLEN], index_filename[BCTEXTLEN];
IndexFile::get_index_filename(source_filename,
- index_directory, index_filename,
- asset->path, ".toc");
- struct stat st;
- if( !access(index_filename, R_OK) &&
- !stat(index_filename,&st) && st.st_size > 0 )
+ index_directory, index_filename, asset->path, ".toc");
strcpy(path, index_filename);
+ if( access(path, R_OK) )
+ result = 1;
}
+// result = 0, asset->path/toc exist, -1 no asset, 1 no toc
return result;
}