char *package_version_minor;
char *package_version_release;
char *package_version_build;
+ // why are we not using typedef'd arrays here? :/ in the name of consistency with
+ // existing above, lets just copy from pxml and use a list of [123] members..
+ char *associationitem1_name;
+ char *associationitem1_filetype;
+ char *associationitem1_parameter;
+ char *associationitem2_name;
+ char *associationitem2_filetype;
+ char *associationitem2_parameter;
+ char *associationitem3_name;
+ char *associationitem3_filetype;
+ char *associationitem3_parameter;
} pnd_disco_t;
void pnd_disco_destroy ( pnd_disco_t *p ); // a function name that simply could not be avoided
fprintf ( f, "X-Pandora-Info-Name=%s\n", p -> info_name );
}
+ if ( p -> associationitem1_name || p -> associationitem2_name || p -> associationitem3_name ) {
+ fprintf ( f, "MimeType=" );
+ if ( p -> associationitem1_name ) {
+ fprintf ( f, "%s;", p -> associationitem1_filetype );
+ pnd_log ( PND_LOG_DEFAULT, "App %s is handling mimetype %s [1]\n", p -> title_en, p -> associationitem1_filetype );
+ }
+ if ( p -> associationitem2_name ) {
+ fprintf ( f, "%s;", p -> associationitem2_filetype );
+ pnd_log ( PND_LOG_DEFAULT, "App %s is handling mimetype %s [2]\n", p -> title_en, p -> associationitem2_filetype );
+ }
+ if ( p -> associationitem3_name ) {
+ fprintf ( f, "%s;", p -> associationitem3_filetype );
+ pnd_log ( PND_LOG_DEFAULT, "App %s is handling mimetype %s [3]\n", p -> title_en, p -> associationitem3_filetype );
+ }
+ fprintf ( f, "\n" );
+ }
+
#if 0 // we let pnd_run.sh command line handle this instead of in .desktop
if ( p -> startdir ) {
snprintf ( buffer, 1020, "Path=%s\n", p -> startdir );
if ( pnd_pxml_get_package_version_build ( pxmlh ) ) {
p -> package_version_build = strdup ( pnd_pxml_get_package_version_build ( pxmlh ) );
}
+ // file associations
+ if ( pnd_pxml_get_associationitem1_name ( pxmlh ) ) {
+ p -> associationitem1_name = pnd_pxml_get_associationitem1_name ( pxmlh );
+ p -> associationitem1_filetype = pnd_pxml_get_associationitem1_filetype ( pxmlh );
+ p -> associationitem1_parameter = pnd_pxml_get_associationitem1_parameter ( pxmlh );
+ }
+ if ( pnd_pxml_get_associationitem2_name ( pxmlh ) ) {
+ p -> associationitem2_name = pnd_pxml_get_associationitem2_name ( pxmlh );
+ p -> associationitem2_filetype = pnd_pxml_get_associationitem2_filetype ( pxmlh );
+ p -> associationitem2_parameter = pnd_pxml_get_associationitem2_parameter ( pxmlh );
+ }
+ if ( pnd_pxml_get_associationitem3_name ( pxmlh ) ) {
+ p -> associationitem3_name = pnd_pxml_get_associationitem3_name ( pxmlh );
+ p -> associationitem3_filetype = pnd_pxml_get_associationitem3_filetype ( pxmlh );
+ p -> associationitem3_parameter = pnd_pxml_get_associationitem3_parameter ( pxmlh );
+ }
// look for any PXML overrides, if requested
if ( disco_overrides ) {