Remove more functions to be deprecated in libqof2. (Pass Three - more

trivial substitutions and simple translations.)


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@13550 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
David Hampton 2006-03-09 06:08:02 +00:00
parent 4b04137e7d
commit 59056ce619
5 changed files with 24 additions and 17 deletions

View File

@ -1,5 +1,12 @@
2006-03-09 David Hampton <hampton@employees.org>
* src/engine/gw-engine-spec.scm:
* src/engine/Group.c:
* lib/libqof/qof/qofquery.c:
* lib/libqof/qof/qofsession.c: Remove more functions to be
deprecated in libqof2. (Pass Three - more trivial substitutions
and simple translations.)
* numerous: Never include "config.h" from a header file. Doing so
makes it nigh impossible to override configuration settings.

View File

@ -703,7 +703,7 @@ GList * qof_query_run (QofQuery *q)
}
/* Maybe log this sucker */
if (gnc_should_log (log_module, GNC_LOG_DETAIL)) qof_query_print (q);
if (qof_log_check (log_module, QOF_LOG_DETAIL)) qof_query_print (q);
/* Now run the query over all the objects and save the results */
{

View File

@ -214,9 +214,9 @@ qof_session_get_current_session (void)
{
if (!current_session)
{
gnc_engine_suspend_events ();
qof_event_suspend ();
current_session = qof_session_new ();
gnc_engine_resume_events ();
qof_event_resume ();
}
return current_session;
@ -634,7 +634,7 @@ qof_entity_copy_to_session(QofSession* new_session, QofEntity* original)
if(!new_session || !original) { return FALSE; }
if(qof_entity_guid_match(new_session, original)) { return FALSE; }
if(!qof_object_compliance(original->e_type, TRUE)) { return FALSE; }
gnc_engine_suspend_events();
qof_event_suspend();
qecd.param_list = NULL;
book = qof_session_get_book(new_session);
qecd.new_session = new_session;
@ -649,7 +649,7 @@ qof_entity_copy_to_session(QofSession* new_session, QofEntity* original)
if(g_slist_length(qecd.param_list) == 0) { return FALSE; }
g_slist_foreach(qecd.param_list, qof_entity_foreach_copy, &qecd);
g_slist_free(qecd.param_list);
gnc_engine_resume_events();
qof_event_resume();
return TRUE;
}
@ -660,12 +660,12 @@ gboolean qof_entity_copy_list(QofSession *new_session, GList *entity_list)
if(!new_session || !entity_list) { return FALSE; }
ENTER (" list=%d", g_list_length(entity_list));
qecd = g_new0(QofEntityCopyData, 1);
gnc_engine_suspend_events();
qof_event_suspend();
qecd->param_list = NULL;
qecd->new_session = new_session;
qof_book_set_partial(qof_session_get_book(new_session));
g_list_foreach(entity_list, qof_entity_list_foreach, qecd);
gnc_engine_resume_events();
qof_event_resume();
if(qecd->error)
{
PWARN (" some/all entities in the list could not be copied.");
@ -682,7 +682,7 @@ qof_entity_copy_coll(QofSession *new_session, QofCollection *entity_coll)
g_return_val_if_fail(new_session, FALSE);
if(!entity_coll) { return FALSE; }
gnc_engine_suspend_events();
qof_event_suspend();
qecd.param_list = NULL;
qecd.new_session = new_session;
qof_book_set_partial(qof_session_get_book(qecd.new_session));
@ -691,7 +691,7 @@ qof_entity_copy_coll(QofSession *new_session, QofCollection *entity_coll)
qof_entity_param_cb, &qecd);
qof_collection_foreach(entity_coll, qof_entity_coll_copy, &qecd);
if(qecd.param_list != NULL) { g_slist_free(qecd.param_list); }
gnc_engine_resume_events();
qof_event_resume();
return TRUE;
}

View File

@ -756,7 +756,7 @@ xaccGroupInsertAccount (AccountGroup *grp, Account *acc)
group_sort_helper);
/* Gather event data */
gnc_engine_gen_event (&acc->inst.entity, GNC_EVENT_ADD);
qof_event_gen (&acc->inst.entity, QOF_EVENT_ADD, NULL);
acc->inst.dirty = TRUE;
xaccAccountCommitEdit (acc);

View File

@ -111,11 +111,11 @@
(let ((wt (gw:wrap-enumeration ws '<gnc:event-type> "QofEventId")))
(gw:enum-add-value! wt "QOF_EVENT_NONE" 'gnc-event-none)
(gw:enum-add-value! wt "QOF_EVENT_CREATE" 'gnc-event-create)
(gw:enum-add-value! wt "QOF_EVENT_MODIFY" 'gnc-event-modify)
(gw:enum-add-value! wt "QOF_EVENT_DESTROY" 'gnc-event-destroy)
(gw:enum-add-value! wt "QOF_EVENT_ALL" 'gnc-event-all))
(gw:enum-add-value! wt "QOF_EVENT_NONE" 'qof-event-none)
(gw:enum-add-value! wt "QOF_EVENT_CREATE" 'qof-event-create)
(gw:enum-add-value! wt "QOF_EVENT_MODIFY" 'qof-event-modify)
(gw:enum-add-value! wt "QOF_EVENT_DESTROY" 'qof-event-destroy)
(gw:enum-add-value! wt "QOF_EVENT_ALL" 'qof-event-all))
(let ((wt (gw:wrap-enumeration ws '<gnc:query-op> "QofQueryOp")))
@ -2463,7 +2463,7 @@ the timepair representing midday on that day")
(gw:wrap-function
ws
'gnc:engine-suspend-events
'qof:event-suspend
'<gw:void>
"qof_event_suspend"
'()
@ -2471,7 +2471,7 @@ the timepair representing midday on that day")
(gw:wrap-function
ws
'gnc:engine-resume-events
'qof:event-resume
'<gw:void>
"qof_event_resume"
'()