[Gnucash-changes] Spruce up the delete window dialog to make it
more HIG compliant.
Neil Williams
linux at codehelp.co.uk
Wed Jul 20 14:53:36 EDT 2005
On Wednesday 20 July 2005 7:28 pm, Neil Williams wrote:
> OK, all I need now is the time to replace every obj->inst.dirty = TRUE with
> qof_instance_set_dirty((QofInstance*)obj)
>
> :-(
>
> void qof_instance_set_dirty(QofInstance* inst)
> {
> QofBook *book;
> QofCollection *coll;
> QofEntity *ent;
>
> inst->dirty = TRUE;
> ent = inst->entity;
ent = &inst->entity; /* :-) */
> book = qof_instance_get_book(inst);
> coll = qof_book_get_collection(book, ent->e_type);
> qof_collection_mark_dirty(coll);
> }
That function will be in my next commit (which isn't due particularly soon).
> Then replace every is_dirty = NULL with
> is_dirty = qof_collection_is_dirty
and make_clean = NULL with make_clean = qof_collection_make_clean
When a collection is marked clean, does THAT have to iterate down to every
instance? So far, I've avoided anything that requires iteration over every
single instance for this task. It's only the collection that is actually
monitored for being dirty. It seems pointless to check every instance when
only one instance may have caused the collection to be marked as dirty. It's
very quick to code this in but it could add a noticeable delay on Save.
--
Neil Williams
=============
http://www.data-freedom.org/
http://www.nosoftwarepatents.com/
http://www.linux.codehelp.co.uk/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.gnucash.org/pipermail/gnucash-devel/attachments/20050720/75eeadc5/attachment.bin
More information about the gnucash-devel
mailing list