xmlNode* ags_recall_dssi_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsRecallDssi *recall_dssi; xmlNode *node; gchar *id; /* */ recall_dssi = AGS_RECALL_DSSI(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-recall-dssi"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", recall_dssi, NULL)); xmlAddChild(parent, node); return(node); }
xmlNode* ags_panel_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsPanel *panel; AgsFileLookup *file_lookup; xmlNode *node; GList *list; gchar *id; guint i; panel = AGS_PANEL(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-panel"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", panel, NULL)); xmlAddChild(parent, node); return(node); }
xmlNode* ags_audiorec_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsAudiorec *audiorec; xmlNode *node; gchar *id; audiorec = AGS_AUDIOREC(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-audiorec"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", audiorec, NULL)); //TODO:JK: implement me xmlAddChild(parent, node); return(node); }
xmlNode* ags_desk_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsDesk *desk; xmlNode *node; GList *list; gchar *id; guint i; desk = AGS_DESK(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-desk"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", desk, NULL)); return(node); }
void ags_matrix_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsMatrix *gobject; AgsFileLaunch *file_launch; GList *list; gobject = AGS_MATRIX(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); /* */ file_launch = g_object_new(AGS_TYPE_FILE_LAUNCH, "node\0", node, "file\0", file, NULL); g_signal_connect(G_OBJECT(file_launch), "start\0", G_CALLBACK(ags_matrix_launch_task), gobject); ags_file_add_launch(file, file_launch); }
xmlNode* ags_synth_input_line_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsSynthInputLine *synth_input_line; xmlNode *node; gchar *id; synth_input_line = AGS_SYNTH_INPUT_LINE(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-synth-input-line"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", synth_input_line, NULL)); ags_file_write_oscillator(file, node, synth_input_line->oscillator); xmlAddChild(parent, node); return(node); }
void ags_drum_input_pad_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsDrumInputPad *gobject; AgsFileLaunch *file_launch; gobject = AGS_DRUM_INPUT_PAD(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); /* */ file_launch = (AgsFileLaunch *) g_object_new(AGS_TYPE_FILE_LAUNCH, "node", node, "file", file, NULL); g_signal_connect(G_OBJECT(file_launch), "start", G_CALLBACK(ags_drum_input_pad_launch_task), gobject); ags_file_add_launch(file, (GObject *) file_launch); }
xmlNode* ags_recall_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { xmlNode *node; gchar *id; id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, AGS_RECALL(plugin)->xml_type); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "main\0", file->ags_main, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", G_OBJECT(plugin), NULL)); xmlAddChild(parent, node); return(node); }
xmlNode* ags_mixer_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsMixer *mixer; xmlNode *node; gchar *id; guint i; mixer = AGS_MIXER(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-mixer\0"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", mixer, NULL)); xmlAddChild(parent, node); return(node); }
void ags_recall_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "main\0", file->ags_main, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", G_OBJECT(plugin), NULL)); }
xmlNode* ags_drum_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsDrum *drum; xmlNode *node; GList *list; gchar *id; guint i; drum = AGS_DRUM(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-drum\0"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", drum, NULL)); xmlNewProp(node, "length\0", g_strdup_printf("%d\0", (gint) gtk_spin_button_get_value(drum->length_spin))); for(i = 0; drum->selected0 != drum->index0[i]; i++); xmlNewProp(node, "bank-index-0\0", g_strdup_printf("%d\0", i)); for(i = 0; drum->selected1 != drum->index1[i]; i++); xmlNewProp(node, "bank-index-1\0", g_strdup_printf("%d\0", i)); xmlNewProp(node, "loop\0", g_strdup_printf("%s\0", ((gtk_toggle_button_get_active(drum->loop_button)) ? AGS_FILE_TRUE: AGS_FILE_FALSE))); xmlAddChild(parent, node); return(node); }
xmlNode* ags_file_write_oscillator(AgsFile *file, xmlNode *parent, AgsOscillator *oscillator) { xmlNode *node; gchar *id; id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-oscillator\0"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "main\0", file->ags_main, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", oscillator, NULL)); xmlNewProp(node, "wave\0", gtk_combo_box_text_get_active_text((GtkComboBoxText *) oscillator->wave)); xmlNewProp(node, "attack\0", g_strdup_printf("%f\0", oscillator->attack->adjustment->value)); xmlNewProp(node, "frame-count\0", g_strdup_printf("%f\0", oscillator->frame_count->adjustment->value)); xmlNewProp(node, "frequency\0", g_strdup_printf("%f\0", oscillator->frequency->adjustment->value)); xmlNewProp(node, "phase\0", g_strdup_printf("%f\0", oscillator->phase->adjustment->value)); xmlNewProp(node, "volume\0", g_strdup_printf("%f\0", oscillator->volume->adjustment->value)); xmlAddChild(parent, node); }
xmlNode* ags_xorg_application_context_write(AgsFile *file, xmlNode *parent, GObject *application_context) { xmlNode *node, *child; gchar *id; id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-application-context\0"); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", application_context, NULL)); xmlNewProp(node, AGS_FILE_CONTEXT_PROP, "xorg\0"); xmlNewProp(node, AGS_FILE_ID_PROP, id); xmlNewProp(node, AGS_FILE_FLAGS_PROP, g_strdup_printf("%x\0", ((~AGS_APPLICATION_CONTEXT_CONNECTED) & (AGS_APPLICATION_CONTEXT(application_context)->flags)))); xmlNewProp(node, AGS_FILE_VERSION_PROP, AGS_APPLICATION_CONTEXT(application_context)->version); xmlNewProp(node, AGS_FILE_BUILD_ID_PROP, AGS_APPLICATION_CONTEXT(application_context)->build_id); /* add to parent */ xmlAddChild(parent, node); ags_file_write_window(file, node, AGS_XORG_APPLICATION_CONTEXT(application_context)->window); return(node); }
void ags_drum_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsDrum *gobject; AgsFileLookup *file_lookup; AgsFileLaunch *file_launch; GList *list; gobject = AGS_DRUM(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); list = file->lookup; while((file_lookup = ags_file_lookup_find_by_node(list, node->parent)) != NULL){ if(g_signal_handler_find(list->data, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, ags_file_read_machine_resolve_audio, NULL) != 0){ g_signal_connect_after(G_OBJECT(file_lookup), "resolve\0", G_CALLBACK(ags_drum_read_resolve_audio), gobject); break; } list = list->next; } /* */ file_launch = g_object_new(AGS_TYPE_FILE_LAUNCH, "node\0", node, "file\0", file, NULL); g_signal_connect(G_OBJECT(file_launch), "start\0", G_CALLBACK(ags_drum_launch_task), gobject); ags_file_add_launch(file, file_launch); }
void ags_desk_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsDesk *gobject; gobject = AGS_DESK(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); }
void ags_synth_input_pad_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsSynthInputPad *gobject; AgsFileLookup *file_lookup; gobject = AGS_SYNTH_INPUT_PAD(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); }
xmlNode* ags_play_dssi_audio_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsPlayDssiAudio *play_dssi_audio; xmlNode *node; gchar *id; play_dssi_audio = AGS_PLAY_DSSI_AUDIO(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-recall-dssi"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", play_dssi_audio, NULL)); xmlNewProp(node, "filename", g_strdup(AGS_RECALL(play_dssi_audio)->filename)); xmlNewProp(node, "effect", g_strdup(AGS_RECALL(play_dssi_audio)->effect)); xmlNewProp(node, "index", g_strdup_printf("%u", AGS_RECALL(play_dssi_audio)->effect_index)); xmlAddChild(parent, node); return(node); }
void ags_audiorec_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsAudiorec *gobject; gobject = AGS_AUDIOREC(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); //TODO:JK: implement me }
void ags_mixer_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsMixer *gobject; GList *list; guint64 index; gobject = AGS_MIXER(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "main\0", file->ags_main, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); }
void ags_synth_input_line_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsSynthInputLine *gobject; AgsFileLookup *file_lookup; xmlNode *child; gobject = AGS_SYNTH_INPUT_LINE(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); gobject->oscillator = ags_oscillator_new(); file_lookup = (AgsFileLookup *) g_object_new(AGS_TYPE_FILE_LOOKUP, "file", file, "node", node, "reference", gobject, NULL); ags_file_add_lookup(file, (GObject *) file_lookup); g_signal_connect(G_OBJECT(file_lookup), "resolve", G_CALLBACK(ags_synth_input_line_resolve_line), gobject); /* child elements */ child = node->children; while(child != NULL){ if(XML_ELEMENT_NODE == child->type){ if(!xmlStrncmp(child->name, "ags-oscillator", 15)){ ags_file_read_oscillator(file, child, &(gobject->oscillator)); } } child = child->next; } }
xmlNode* ags_recall_ladspa_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsRecallLadspa *recall_ladspa; xmlNode *node; GList *list; gchar *id; recall_ladspa = AGS_RECALL_LADSPA(plugin); id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-recall-ladspa\0"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", id), "reference\0", recall_ladspa, NULL)); xmlNewProp(node, "filename\0", g_strdup(recall_ladspa->filename)); xmlNewProp(node, "effect\0", g_strdup(recall_ladspa->effect)); xmlNewProp(node, "index\0", g_strdup_printf("%d\0", recall_ladspa->effect_index)); xmlAddChild(parent, node); return(node); }
void ags_recall_dssi_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsRecallDssi *gobject; AgsDssiPlugin *dssi_plugin; gobject = AGS_RECALL_DSSI(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); ags_recall_dssi_load(gobject); }
void ags_panel_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsPanel *gobject; AgsFileLookup *file_lookup; GList *list; guint64 length, index; gobject = AGS_PANEL(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); list = file->lookup; while((list = ags_file_lookup_find_by_node(list, node->parent)) != NULL){ file_lookup = AGS_FILE_LOOKUP(list->data); if(g_signal_handler_find(list->data, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, ags_file_read_machine_resolve_audio, NULL) != 0){ g_signal_connect_after(G_OBJECT(file_lookup), "resolve", G_CALLBACK(ags_panel_read_resolve_audio), gobject); break; } list = list->next; } }
xmlNode* ags_drum_input_pad_write(AgsFile *file, xmlNode *parent, AgsPlugin *plugin) { AgsDrumInputPad *drum_input_pad; xmlNode *node; gchar *id; drum_input_pad = AGS_DRUM_INPUT_PAD(plugin); node = NULL; if(gtk_toggle_button_get_active(drum_input_pad->edit)){ id = ags_id_generator_create_uuid(); node = xmlNewNode(NULL, "ags-drum-input-pad"); xmlNewProp(node, AGS_FILE_ID_PROP, id); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", id), "reference", drum_input_pad, NULL)); xmlNewProp(node, "edit", g_strdup_printf("%s", AGS_FILE_TRUE)); xmlAddChild(parent, node); } return(node); }
void ags_play_dssi_audio_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsPlayDssiAudio *gobject; AgsDssiPlugin *dssi_plugin; gchar *filename, *effect; unsigned long effect_index; gobject = AGS_PLAY_DSSI_AUDIO(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context", file->application_context, "file", file, "node", node, "xpath", g_strdup_printf("xpath=//*[@id='%s']", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference", gobject, NULL)); filename = xmlGetProp(node, "filename"); effect = xmlGetProp(node, "effect"); effect_index = g_ascii_strtoull(xmlGetProp(node, "index"), NULL, 10); g_object_set(gobject, "filename", filename, "effect", effect, "effect-index", effect_index, NULL); ags_play_dssi_audio_load(gobject); }
void ags_recall_ladspa_read(AgsFile *file, xmlNode *node, AgsPlugin *plugin) { AgsRecallLadspa *gobject; AgsLadspaPlugin *ladspa_plugin; gchar *filename, *effect; unsigned long effect_index; gobject = AGS_RECALL_LADSPA(plugin); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); filename = xmlGetProp(node, "filename\0"); effect = xmlGetProp(node, "effect\0"); effect_index = g_ascii_strtoull(xmlGetProp(node, "index\0"), NULL, 10); g_object_set(gobject, "filename\0", filename, "effect\0", effect, "index\0", effect_index, NULL); ags_recall_ladspa_load(gobject); }
void ags_file_read_oscillator(AgsFile *file, xmlNode *node, AgsOscillator **oscillator) { AgsOscillator *gobject; xmlChar *wave; if(*oscillator == NULL){ gobject = (AgsOscillator *) g_object_new(AGS_TYPE_OSCILLATOR, NULL); *oscillator = gobject; }else{ gobject = *oscillator; } ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "main\0", file->ags_main, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); wave = (xmlChar *) xmlGetProp(node, "wave\0"); if(!xmlStrncmp(wave, "sin\0", 4)){ gtk_combo_box_set_active(gobject->wave, 0); }else if(!xmlStrncmp(wave, "sawtooth\0", 9)){ gtk_combo_box_set_active(gobject->wave, 1); }else if(!xmlStrncmp(wave, "square\0", 7)){ gtk_combo_box_set_active(gobject->wave, 2); }else if(!xmlStrncmp(wave, "triangle\0", 9)){ gtk_combo_box_set_active(gobject->wave, 3); } gtk_spin_button_set_value(gobject->attack, g_ascii_strtod(xmlGetProp(node, "attack\0"), NULL)); gtk_spin_button_set_value(gobject->frame_count, g_ascii_strtod(xmlGetProp(node, "frame-count\0"), NULL)); gtk_spin_button_set_value(gobject->frequency, g_ascii_strtod(xmlGetProp(node, "frequency\0"), NULL)); gtk_spin_button_set_value(gobject->phase, g_ascii_strtod(xmlGetProp(node, "phase\0"), NULL)); gtk_spin_button_set_value(gobject->volume, g_ascii_strtod(xmlGetProp(node, "volume\0"), NULL)); }
void ags_xorg_application_context_read(AgsFile *file, xmlNode *node, GObject **application_context) { AgsXorgApplicationContext *gobject; GList *list; xmlNode *child; if(*application_context == NULL) { gobject = g_object_new(AGS_TYPE_XORG_APPLICATION_CONTEXT, NULL); *application_context = (GObject *) gobject; } else { gobject = (AgsApplicationContext *) *application_context; } file->application_context = gobject; g_object_set(G_OBJECT(file), "application-context\0", gobject, NULL); ags_file_add_id_ref(file, g_object_new(AGS_TYPE_FILE_ID_REF, "application-context\0", file->application_context, "file\0", file, "node\0", node, "xpath\0", g_strdup_printf("xpath=//*[@id='%s']\0", xmlGetProp(node, AGS_FILE_ID_PROP)), "reference\0", gobject, NULL)); /* properties */ AGS_APPLICATION_CONTEXT(gobject)->flags = (guint) g_ascii_strtoull(xmlGetProp(node, AGS_FILE_FLAGS_PROP), NULL, 16); AGS_APPLICATION_CONTEXT(gobject)->version = xmlGetProp(node, AGS_FILE_VERSION_PROP); AGS_APPLICATION_CONTEXT(gobject)->build_id = xmlGetProp(node, AGS_FILE_BUILD_ID_PROP); //TODO:JK: check version compatibelity /* child elements */ child = node->children; while(child != NULL) { if(child->type == XML_ELEMENT_NODE) { if(!xmlStrncmp("ags-window\0", child->name, 11)) { ags_file_read_window(file, child, &(gobject->window)); } } child = child->next; } }