mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
move code around a lot.
* Rename a bunch of files: business-options to business-options-gnome business-utils to business-gnome-utils - this required changes to a bunch of files in business-gnome * move business-options.scm and business-prefs.scm to business-utils * create a business-utils gnc-module - required changes to configure.in, business/Makefile.am - added a bunch of files (generally moved from business-gnome) * moved a bunch of other non-gnome definitions out of the gnome-specific locations (gnome-utils -> app-utils, or business-gnome -> business-utils) * gncEntryLedgerLoad.c: commented-out code to load tax-tables from the options; waiting until code is actually written. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@7844 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
2e15b07299
commit
bfe6c757b3
15
ChangeLog
15
ChangeLog
@ -18,6 +18,21 @@
|
||||
|
||||
Initial fix for #93462. Next commit will actually use the values.
|
||||
|
||||
move code around a lot.
|
||||
* Rename a bunch of files:
|
||||
business-options to business-options-gnome
|
||||
business-utils to business-gnome-utils
|
||||
- this required changes to a bunch of files in business-gnome
|
||||
* move business-options.scm and business-prefs.scm to business-utils
|
||||
* create a business-utils gnc-module
|
||||
- required changes to configure.in, business/Makefile.am
|
||||
- added a bunch of files (generally moved from business-gnome)
|
||||
* moved a bunch of other non-gnome definitions out of the gnome-specific
|
||||
locations (gnome-utils -> app-utils, or business-gnome -> business-utils)
|
||||
|
||||
* gncEntryLedgerLoad.c: commented-out code to load tax-tables from
|
||||
the options; waiting until code is actually written.
|
||||
|
||||
2003-01-16 Derek Atkins <derek@ihtfp.com>
|
||||
|
||||
* src/engine/commodity-table.scm: move gnc:commodity-is-currency? here
|
||||
|
@ -1158,6 +1158,7 @@ AC_OUTPUT( m4/Makefile intl/Makefile po/Makefile.in
|
||||
src/business/business-core/Makefile
|
||||
src/business/business-core/test/Makefile
|
||||
src/business/business-core/file/Makefile
|
||||
src/business/business-utils/Makefile
|
||||
src/business/dialog-tax-table/Makefile
|
||||
src/business/business-gnome/Makefile
|
||||
src/business/business-gnome/glade/Makefile
|
||||
|
@ -254,6 +254,7 @@
|
||||
(export gnc:register-kvp-option-generator)
|
||||
(export gnc:unregister-kvp-option-generator)
|
||||
(export gnc:make-kvp-options)
|
||||
(export gnc:*kvp-option-path*)
|
||||
|
||||
(load-from-path "c-interface.scm")
|
||||
(load-from-path "config-var.scm")
|
||||
@ -264,6 +265,8 @@
|
||||
(load-from-path "date-utilities.scm")
|
||||
(load-from-path "simple-obj.scm")
|
||||
|
||||
|
||||
|
||||
(gnc:hook-add-dangler gnc:*startup-hook*
|
||||
(lambda ()
|
||||
(begin
|
||||
|
@ -23,6 +23,8 @@
|
||||
(use-modules (ice-9 slib))
|
||||
(require 'hash)
|
||||
|
||||
(define gnc:*kvp-option-path* '("options"))
|
||||
|
||||
(define gnc:*kvp-option-registry* (make-hash-table 23))
|
||||
|
||||
(define (get-ref id-type)
|
||||
|
@ -1,5 +1,6 @@
|
||||
SUBDIRS = \
|
||||
business-core \
|
||||
business-utils \
|
||||
dialog-tax-table \
|
||||
business-ledger \
|
||||
business-gnome \
|
||||
|
@ -28,9 +28,9 @@ AM_CFLAGS = \
|
||||
|
||||
libgncmod_business_gnome_la_SOURCES = \
|
||||
businessmod-gnome.c \
|
||||
business-options.c \
|
||||
business-options-gnome.c \
|
||||
business-urls.c \
|
||||
business-utils.c \
|
||||
business-gnome-utils.c \
|
||||
dialog-billterms.c \
|
||||
dialog-customer.c \
|
||||
dialog-date-close.c \
|
||||
@ -40,13 +40,12 @@ libgncmod_business_gnome_la_SOURCES = \
|
||||
dialog-order.c \
|
||||
dialog-payment.c \
|
||||
dialog-vendor.c \
|
||||
search-owner.c \
|
||||
gnc-business-utils.c
|
||||
search-owner.c
|
||||
|
||||
noinst_HEADERS = \
|
||||
business-options.h \
|
||||
business-options-gnome.h \
|
||||
business-urls.h \
|
||||
business-utils.h \
|
||||
business-gnome-utils.h \
|
||||
dialog-billterms.h \
|
||||
dialog-customer.h \
|
||||
dialog-date-close.h \
|
||||
@ -56,8 +55,7 @@ noinst_HEADERS = \
|
||||
dialog-order.h \
|
||||
dialog-payment.h \
|
||||
dialog-vendor.h \
|
||||
search-owner.h \
|
||||
gnc-business-utils.h
|
||||
search-owner.h
|
||||
|
||||
libgncmod_business_gnome_la_LDFLAGS = -module
|
||||
|
||||
@ -79,12 +77,6 @@ libgw_business_gnome_la_LDFLAGS = -module ${G_WRAP_LINK_ARGS}
|
||||
gncscmmoddir = ${GNC_SHAREDIR}/guile-modules/gnucash/report/
|
||||
gncscmmod_DATA =
|
||||
|
||||
# For regular scheme definitions
|
||||
gncscmdir = ${GNC_SHAREDIR}/scm
|
||||
gncscm_DATA = \
|
||||
business-options.scm \
|
||||
business-prefs.scm
|
||||
|
||||
gncmoddir = ${GNC_SHAREDIR}/guile-modules/gnucash
|
||||
gncmod_DATA = business-gnome.scm
|
||||
|
||||
@ -97,7 +89,6 @@ EXTRA_DIST = \
|
||||
.cvsignore \
|
||||
${gncmod_DATA} \
|
||||
${gwmod_DATA} \
|
||||
${gncscm_DATA} \
|
||||
${gncscmmod_DATA}
|
||||
|
||||
if GNUCASH_SEPARATE_BUILDDIR
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* business-utils.c -- General GUI Utilities for GNC Business Objects
|
||||
* business-gnome-utils.c -- General GUI Utilities for GNC Business Objects
|
||||
*
|
||||
* Written By: Derek Atkins <warlord@MIT.EDU>
|
||||
* Copyright (C) 2001, 2002 Derek Atkins
|
||||
@ -22,7 +22,7 @@
|
||||
|
||||
#include "gnc-general-search.h"
|
||||
#include "gncObject.h"
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-customer.h"
|
||||
#include "dialog-job.h"
|
||||
#include "dialog-vendor.h"
|
@ -1,12 +1,12 @@
|
||||
/*
|
||||
* business-utils.h -- General GUI Utilities for GNC Business Objects
|
||||
* business-gnome-utils.h -- General GUI Utilities for GNC Business Objects
|
||||
*
|
||||
* Written By: Derek Atkins <warlord@MIT.EDU>
|
||||
* Copyright (C) 2001
|
||||
*/
|
||||
|
||||
#ifndef GNC_BUSINESS_UTILS_H_
|
||||
#define GNC_BUSINESS_UTILS_H_
|
||||
#ifndef GNC_BUSINESS_GNOME_UTILS_H_
|
||||
#define GNC_BUSINESS_GNOME_UTILS_H_
|
||||
|
||||
#include "gnc-book.h"
|
||||
#include "gncOwner.h"
|
||||
@ -63,4 +63,4 @@ gpointer gnc_ui_optionmenu_get_value (GtkWidget *omenu);
|
||||
void gnc_ui_optionmenu_set_value (GtkWidget *omenu, gpointer data);
|
||||
|
||||
|
||||
#endif /* GNC_BUSINESS_UTILS_H_ */
|
||||
#endif /* GNC_BUSINESS_GNOME_UTILS_H_ */
|
@ -4,11 +4,13 @@
|
||||
|
||||
(gnc:module-load "gnucash/gnome-utils" 0)
|
||||
(gnc:module-load "gnucash/business-core" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
(gnc:module-load "gnucash/gnome-search" 0)
|
||||
(gnc:module-load "gnucash/business-core-file" 0)
|
||||
(gnc:module-load "gnucash/dialog-tax-table" 0)
|
||||
|
||||
(gnc:module-load "gnucash/report/report-gnome" 0)
|
||||
|
||||
(use-modules (gnucash report business-reports))
|
||||
(use-modules (gnucash main)) ;for gnc:debug
|
||||
|
||||
@ -17,12 +19,6 @@
|
||||
(define new-label (N_ "New"))
|
||||
(define find-label (N_ "Find"))
|
||||
|
||||
(define gnc:*business-label* (N_ "Business"))
|
||||
(define gnc:*company-name* (N_ "Company Name"))
|
||||
(define gnc:*company-addy* (N_ "Company Address"))
|
||||
|
||||
(export gnc:*business-label* gnc:*company-name* gnc:*company-addy*)
|
||||
|
||||
(define (add-customer-items)
|
||||
(let ((last-cust (gnc:owner-create))
|
||||
(cust (N_ "Customers")))
|
||||
@ -389,6 +385,3 @@
|
||||
(gnc:hook-add-dangler gnc:*report-hook* business-report-function)
|
||||
(gnc:hook-add-dangler gnc:*ui-startup-hook* add-business-items)
|
||||
(gnc:hook-add-dangler gnc:*add-extension-hook* add-business-test)
|
||||
|
||||
(load-from-path "business-options.scm")
|
||||
(load-from-path "business-prefs.scm")
|
||||
|
@ -17,8 +17,8 @@
|
||||
#include "gnc-general-search.h"
|
||||
|
||||
#include "dialog-options.h"
|
||||
#include "business-options.h"
|
||||
#include "business-utils.h"
|
||||
#include "business-options-gnome.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-invoice.h"
|
||||
|
||||
static int
|
||||
@ -430,7 +430,7 @@ taxtable_get_value (GNCOption *option, GtkWidget *widget)
|
||||
|
||||
|
||||
void
|
||||
gnc_business_options_initialize (void)
|
||||
gnc_business_options_gnome_initialize (void)
|
||||
{
|
||||
int i;
|
||||
static GNCOptionDef_t options[] = {
|
@ -8,6 +8,6 @@
|
||||
#ifndef GNC_BUSINESS_OPTIONS_H_
|
||||
#define GNC_BUSINESS_OPTIONS_H_
|
||||
|
||||
void gnc_business_options_initialize (void);
|
||||
void gnc_business_options_gnome_initialize (void);
|
||||
|
||||
#endif /* GNC_BUSINESS_OPTIONS_H_ */
|
@ -20,7 +20,7 @@
|
||||
#include "search-core-type.h"
|
||||
#include "search-owner.h"
|
||||
#include "gncOwner.h"
|
||||
#include "business-options.h"
|
||||
#include "business-options-gnome.h"
|
||||
#include "business-urls.h"
|
||||
|
||||
/* version of the gnc module system interface we require */
|
||||
@ -83,7 +83,7 @@ libgncmod_business_gnome_LTX_gnc_module_init(int refcount)
|
||||
gnc_search_core_register_type (GNC_OWNER_MODULE_NAME,
|
||||
(GNCSearchCoreNew) gnc_search_owner_new);
|
||||
gnc_business_urls_initialize ();
|
||||
gnc_business_options_initialize ();
|
||||
gnc_business_options_gnome_initialize ();
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
@ -26,7 +26,7 @@
|
||||
#include "gncCustomer.h"
|
||||
#include "gncCustomerP.h"
|
||||
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-customer.h"
|
||||
#include "dialog-job.h"
|
||||
#include "dialog-order.h"
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include "gnc-date-edit.h"
|
||||
#include "gnc-account-sel.h"
|
||||
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-date-close.h"
|
||||
|
||||
typedef struct _dialog_date_close_window {
|
||||
|
@ -35,7 +35,7 @@
|
||||
#include "dialog-date-close.h"
|
||||
#include "dialog-invoice.h"
|
||||
#include "dialog-job.h"
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-payment.h"
|
||||
#include "dialog-tax-table.h"
|
||||
#include "dialog-billterms.h"
|
||||
|
@ -21,7 +21,7 @@
|
||||
#include "gncJob.h"
|
||||
#include "gncJobP.h"
|
||||
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-job.h"
|
||||
#include "dialog-invoice.h"
|
||||
#include "dialog-payment.h"
|
||||
|
@ -27,7 +27,7 @@
|
||||
|
||||
#include "dialog-order.h"
|
||||
#include "dialog-invoice.h"
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-date-close.h"
|
||||
|
||||
#define DIALOG_NEW_ORDER_CM_CLASS "dialog-new-order"
|
||||
|
@ -25,7 +25,7 @@
|
||||
#include "gncInvoice.h"
|
||||
|
||||
#include "dialog-payment.h"
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
|
||||
#define DIALOG_PAYMENT_CUSTOMER_CM_CLASS "customer-payment-dialog"
|
||||
#define DIALOG_PAYMENT_VENDOR_CM_CLASS "vendor-payment-dialog"
|
||||
|
@ -24,7 +24,7 @@
|
||||
#include "gncVendor.h"
|
||||
#include "gncVendorP.h"
|
||||
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "dialog-vendor.h"
|
||||
#include "dialog-job.h"
|
||||
#include "dialog-order.h"
|
||||
|
@ -29,7 +29,7 @@
|
||||
#include "gnc-gui-query.h"
|
||||
#include "gncOwner.h"
|
||||
|
||||
#include "business-utils.h"
|
||||
#include "business-gnome-utils.h"
|
||||
#include "search-owner.h"
|
||||
|
||||
#define d(x)
|
||||
|
@ -205,7 +205,7 @@ void gnc_entry_ledger_load (GncEntryLedger *ledger, GList *entry_list)
|
||||
|
||||
{
|
||||
GncOwner *owner = gncInvoiceGetOwner (ledger->invoice);
|
||||
GncTaxTable *table;
|
||||
GncTaxTable *table = NULL;
|
||||
GncTaxIncluded taxincluded_p = GNC_TAXINCLUDED_USEGLOBAL;
|
||||
gboolean taxincluded = FALSE;
|
||||
gnc_numeric discount = gnc_numeric_zero ();
|
||||
@ -240,19 +240,30 @@ void gnc_entry_ledger_load (GncEntryLedger *ledger, GList *entry_list)
|
||||
break;
|
||||
}
|
||||
|
||||
/* XXX: Get the default tax-table */
|
||||
table = NULL;
|
||||
|
||||
/* Maybe override the global taxtable */
|
||||
switch (gncOwnerGetType (owner)) {
|
||||
case GNC_OWNER_CUSTOMER:
|
||||
#if 0
|
||||
table = gnc_lookup_taxtable_option (ledger->book,
|
||||
"Business",
|
||||
"Default Customer TaxTable",
|
||||
NULL);
|
||||
#endif
|
||||
if (gncCustomerGetTaxTableOverride (owner->owner.customer))
|
||||
table = gncCustomerGetTaxTable (owner->owner.customer);
|
||||
break;
|
||||
|
||||
case GNC_OWNER_VENDOR:
|
||||
#if 0
|
||||
table = gnc_lookup_taxtable_option (ledger->book,
|
||||
"Business",
|
||||
"Default Vendor TaxTable",
|
||||
NULL);
|
||||
#endif
|
||||
if (gncVendorGetTaxTableOverride (owner->owner.vendor))
|
||||
table = gncVendorGetTaxTable (owner->owner.vendor);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -34,6 +34,8 @@
|
||||
|
||||
(gnc:module-load "gnucash/report/report-system" 0)
|
||||
(gnc:module-load "gnucash/business-core" 0)
|
||||
|
||||
(use-modules (gnucash report standard-reports))
|
||||
(use-modules (gnucash report business-reports))
|
||||
|
||||
(define optname-to-date (N_ "To"))
|
||||
|
@ -8,7 +8,7 @@
|
||||
(define-module (gnucash report business-reports))
|
||||
(use-modules (gnucash gnc-module))
|
||||
(gnc:module-load "gnucash/report/standard-reports" 0)
|
||||
(gnc:module-load "gnucash/business-gnome" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
|
||||
(define gnc:menuname-business-reports (N_ "Business Reports"))
|
||||
|
||||
|
@ -15,7 +15,10 @@
|
||||
(require 'record)
|
||||
|
||||
(gnc:module-load "gnucash/report/report-system" 0)
|
||||
(gnc:module-load "gnucash/business-gnome" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
|
||||
(use-modules (gnucash report standard-reports))
|
||||
(use-modules (gnucash report business-reports))
|
||||
|
||||
(define invoice-page gnc:pagename-general)
|
||||
(define invoice-name (N_ "Invoice Number"))
|
||||
|
@ -15,8 +15,10 @@
|
||||
(use-modules (gnucash main)) ; for gnc:debug
|
||||
|
||||
(gnc:module-load "gnucash/report/report-system" 0)
|
||||
(gnc:module-load "gnucash/business-gnome" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
|
||||
(use-modules (gnucash report standard-reports))
|
||||
(use-modules (gnucash report business-reports))
|
||||
|
||||
(define acct-string (N_ "Account"))
|
||||
(define owner-string (N_ "Company"))
|
||||
|
@ -29,10 +29,11 @@
|
||||
(use-modules (gnucash gnc-module))
|
||||
|
||||
(gnc:module-load "gnucash/report/report-system" 0)
|
||||
(gnc:module-load "gnucash/business-gnome" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
|
||||
(use-modules (gnucash report aging))
|
||||
(use-modules (gnucash report standard-reports))
|
||||
(use-modules (gnucash report business-reports))
|
||||
|
||||
(define acc-page gnc:pagename-general)
|
||||
(define this-acc (N_ "Payable Account"))
|
||||
|
@ -29,10 +29,11 @@
|
||||
(use-modules (gnucash gnc-module))
|
||||
|
||||
(gnc:module-load "gnucash/report/report-system" 0)
|
||||
(gnc:module-load "gnucash/business-gnome" 0)
|
||||
(gnc:module-load "gnucash/business-utils" 0)
|
||||
|
||||
(use-modules (gnucash report aging))
|
||||
(use-modules (gnucash report standard-reports))
|
||||
(use-modules (gnucash report business-reports))
|
||||
|
||||
(define acc-page gnc:pagename-general)
|
||||
(define this-acc (N_ "Receivables Account"))
|
||||
|
6
src/business/business-utils/.cvsignore
Normal file
6
src/business/business-utils/.cvsignore
Normal file
@ -0,0 +1,6 @@
|
||||
*.la
|
||||
*.lo
|
||||
.deps
|
||||
.libs
|
||||
Makefile
|
||||
Makefile.in
|
38
src/business/business-utils/Makefile.am
Normal file
38
src/business/business-utils/Makefile.am
Normal file
@ -0,0 +1,38 @@
|
||||
pkglib_LTLIBRARIES = libgncmod-business-utils.la
|
||||
|
||||
AM_CFLAGS = \
|
||||
-I${top_srcdir}/src \
|
||||
-I${top_srcdir}/src/engine \
|
||||
-I${top_srcdir}/src/gnc-module \
|
||||
-I${top_srcdir}/src/business/business-core \
|
||||
${G_WRAP_COMPILE_ARGS} \
|
||||
${GUILE_INCS} \
|
||||
${GLIB_CFLAGS}
|
||||
|
||||
libgncmod_business_utils_la_SOURCES = \
|
||||
gncmod-business-utils.c \
|
||||
business-options.c
|
||||
|
||||
noinst_HEADERS = \
|
||||
business-options.h
|
||||
|
||||
libgncmod_business_utils_la_LDFLAGS = -module
|
||||
libgncmod_business_utils_la_LIBADD = \
|
||||
${GUILE_LIBS} \
|
||||
${GLIB_LIBS} \
|
||||
${EFENCE_LIBS}
|
||||
|
||||
# Guile Modules
|
||||
gncmoddir = ${GNC_SHAREDIR}/guile-modules/gnucash
|
||||
gncmod_DATA = business-utils.scm
|
||||
|
||||
# For regular scheme definitions
|
||||
gncscmdir = ${GNC_SHAREDIR}/scm
|
||||
gncscm_DATA = \
|
||||
business-options.scm \
|
||||
business-prefs.scm
|
||||
|
||||
EXTRA_DIST = \
|
||||
.cvsignore \
|
||||
${gncscm_DATA} \
|
||||
${gncmod_DATA}
|
1
src/business/business-utils/business-options.c
Normal file
1
src/business/business-utils/business-options.c
Normal file
@ -0,0 +1 @@
|
||||
|
1
src/business/business-utils/business-options.h
Normal file
1
src/business/business-utils/business-options.h
Normal file
@ -0,0 +1 @@
|
||||
|
1
src/business/business-utils/business-utils.c
Normal file
1
src/business/business-utils/business-utils.c
Normal file
@ -0,0 +1 @@
|
||||
|
1
src/business/business-utils/business-utils.h
Normal file
1
src/business/business-utils/business-utils.h
Normal file
@ -0,0 +1 @@
|
||||
|
14
src/business/business-utils/business-utils.scm
Normal file
14
src/business/business-utils/business-utils.scm
Normal file
@ -0,0 +1,14 @@
|
||||
(define-module (gnucash business-utils))
|
||||
|
||||
(use-modules (gnucash gnc-module))
|
||||
(gnc:module-load "gnucash/app-utils" 0)
|
||||
(gnc:module-load "gnucash/business-core" 0)
|
||||
|
||||
(define gnc:*business-label* (N_ "Business"))
|
||||
(define gnc:*company-name* (N_ "Company Name"))
|
||||
(define gnc:*company-addy* (N_ "Company Address"))
|
||||
|
||||
(export gnc:*business-label* gnc:*company-name* gnc:*company-addy*)
|
||||
|
||||
(load-from-path "business-options.scm")
|
||||
(load-from-path "business-prefs.scm")
|
67
src/business/business-utils/gncmod-business-utils.c
Normal file
67
src/business/business-utils/gncmod-business-utils.c
Normal file
@ -0,0 +1,67 @@
|
||||
/*********************************************************************
|
||||
* gncmod-business-utils.c
|
||||
* module definition/initialization for the Business Utilitizes module
|
||||
*
|
||||
* Copyright (c) 2003 Derek Atkins <warlord@MIT.EDU>
|
||||
*********************************************************************/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <guile/gh.h>
|
||||
#include <glib.h>
|
||||
|
||||
#include "gnc-module.h"
|
||||
#include "gnc-module-api.h"
|
||||
|
||||
/* version of the gnc module system interface we require */
|
||||
int libgncmod_business_utils_LTX_gnc_module_system_interface = 0;
|
||||
|
||||
/* module versioning uses libtool semantics. */
|
||||
int libgncmod_business_utils_LTX_gnc_module_current = 0;
|
||||
int libgncmod_business_utils_LTX_gnc_module_revision = 0;
|
||||
int libgncmod_business_utils_LTX_gnc_module_age = 0;
|
||||
|
||||
/* forward references */
|
||||
char *libgncmod_business_utils_LTX_gnc_module_path(void);
|
||||
char *libgncmod_business_utils_LTX_gnc_module_description(void);
|
||||
int libgncmod_business_utils_LTX_gnc_module_init(int refcount);
|
||||
int libgncmod_business_utils_LTX_gnc_module_end(int refcount);
|
||||
|
||||
char *
|
||||
libgncmod_business_utils_LTX_gnc_module_path(void)
|
||||
{
|
||||
return g_strdup("gnucash/business-utils");
|
||||
}
|
||||
|
||||
char *
|
||||
libgncmod_business_utils_LTX_gnc_module_description(void)
|
||||
{
|
||||
return g_strdup("The Gnucash business utilities module");
|
||||
}
|
||||
|
||||
int
|
||||
libgncmod_business_utils_LTX_gnc_module_init(int refcount)
|
||||
{
|
||||
/* load the business-core (we depend on it) */
|
||||
if (!gnc_module_load("gnucash/business-core", 0)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Load the application utils.. */
|
||||
if (!gnc_module_load("gnucash/app-utils", 0)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if(refcount == 0)
|
||||
{
|
||||
/* initialize known types */
|
||||
}
|
||||
|
||||
gh_eval_str("(use-modules (gnucash business-utils))");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
int
|
||||
libgncmod_business_utils_LTX_gnc_module_end(int refcount) {
|
||||
return TRUE;
|
||||
}
|
@ -18,13 +18,10 @@
|
||||
(export gnc:new-menu-namer)
|
||||
(export gnc:*add-extension-hook*)
|
||||
|
||||
(export gnc:*kvp-option-path*)
|
||||
(export gnc:kvp-option-dialog)
|
||||
|
||||
(load-from-path "gnc-menu-extensions.scm")
|
||||
|
||||
(define gnc:*kvp-option-path* '("options"))
|
||||
|
||||
(define (gnc:kvp-option-dialog id-type slots title changed_cb)
|
||||
(let* ((options (gnc:make-kvp-options id-type))
|
||||
(optiondb (gnc:option-db-new options))
|
||||
|
Loading…
Reference in New Issue
Block a user