static void gnc_plugin_page_owner_tree_cmd_owner_report (GtkAction *action, GncPluginPageOwnerTree *plugin_page) { GncOwner *current_owner; int id; ENTER("(action %p, plugin_page %p)", action, plugin_page); g_return_if_fail(GNC_IS_PLUGIN_PAGE_OWNER_TREE(plugin_page)); current_owner = gnc_plugin_page_owner_tree_get_current_owner (plugin_page); id = build_owner_report (current_owner, NULL); if (id >= 0) { GncMainWindow *window; window = GNC_MAIN_WINDOW(GNC_PLUGIN_PAGE(plugin_page)->window); gnc_main_window_open_report(id, window); } LEAVE(" "); }
/************************************************************** * custom_report_run_report * * this procedure sets up and calls the report on the scheme * side. This is what makes the report actually run. **************************************************************/ static void custom_report_run_report(SCM guid, CustomReportDialog *crd) { SCM make_report = scm_c_eval_string("gnc:make-report"); int report_id; GncMainWindow *window = crd->window; if (scm_is_null(guid)) return; /* this generates the report */ report_id = scm_to_int (scm_call_1(make_report, guid)); /* do this *before* displaying the report because sometimes that takes a while... */ custom_report_dialog_close_cb(NULL, crd); /* display the report */ gnc_main_window_open_report(report_id, window); }
static void gnc_plugin_page_owner_tree_cmd_owners_report (GtkAction *action, GncPluginPageOwnerTree *plugin_page) { GncPluginPageOwnerTreePrivate *priv; int id; ENTER("(action %p, plugin_page %p)", action, plugin_page); g_return_if_fail(GNC_IS_PLUGIN_PAGE_OWNER_TREE(plugin_page)); priv = GNC_PLUGIN_PAGE_OWNER_TREE_GET_PRIVATE(plugin_page); id = build_aging_report (priv->owner_type); if (id >= 0) { GncMainWindow *window; window = GNC_MAIN_WINDOW(GNC_PLUGIN_PAGE(plugin_page)->window); gnc_main_window_open_report(id, window); } LEAVE(" "); }