Commit 983322e5 authored by Maxime Doyen's avatar Maxime Doyen

5.2.1 release

parent 998544ec
2018-09-15 Maxime Doyen
Made 5.2.1 release.
* wish : #1789698 treat search box as another filter
* bugfix: #1792677 backup files are not being deleted
* bugfix: #1792567 trendtime report crash when display payee
* bugfix: #1791656 CSV import do not import info, payee, and tags
* bugfix: #1791554 revert and Restore backup menu items permanently greyed out
2018-09-08 Maxime Doyen
Made 5.2 release.
......
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for homebank 5.2.
# Generated by GNU Autoconf 2.69 for homebank 5.2.1.
#
#
# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
......@@ -577,8 +577,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='homebank'
PACKAGE_TARNAME='homebank'
PACKAGE_VERSION='5.2'
PACKAGE_STRING='homebank 5.2'
PACKAGE_VERSION='5.2.1'
PACKAGE_STRING='homebank 5.2.1'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
......@@ -1341,7 +1341,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures homebank 5.2 to adapt to many kinds of systems.
\`configure' configures homebank 5.2.1 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
......@@ -1408,7 +1408,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of homebank 5.2:";;
short | recursive ) echo "Configuration of homebank 5.2.1:";;
esac
cat <<\_ACEOF
......@@ -1516,7 +1516,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
homebank configure 5.2
homebank configure 5.2.1
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
......@@ -1935,7 +1935,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by homebank $as_me 5.2, which was
It was created by homebank $as_me 5.2.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
......@@ -2803,7 +2803,7 @@ fi
# Define the identity of the package.
PACKAGE='homebank'
VERSION='5.2'
VERSION='5.2.1'
cat >>confdefs.h <<_ACEOF
......@@ -7076,7 +7076,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by homebank $as_me 5.2, which was
This file was extended by homebank $as_me 5.2.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
......@@ -7142,7 +7142,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
homebank config.status 5.2
homebank config.status 5.2.1
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
......
......@@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.52)
AC_INIT([homebank], [5.2])
AC_INIT([homebank], [5.2.1])
#AC_INIT([homebank], [x.x-rc])
AM_CONFIG_HEADER(config.h)
......
......@@ -53,7 +53,7 @@ extern gchar *CYA_FLT_TYPE[];
extern gchar *CYA_FLT_STATUS[];
static void register_panel_collect_filtered_txn(GtkWidget *view);
static void register_panel_collect_filtered_txn(GtkWidget *view, gboolean emptysearch);
static void register_panel_listview_populate(GtkWidget *view);
static void register_panel_action(GtkWidget *widget, gpointer user_data);
static void register_panel_update(GtkWidget *widget, gpointer user_data);
......@@ -622,14 +622,14 @@ gint range;
if( future && (PREFS->date_future_nbdays > 0) )
filter_preset_daterange_add_futuregap(data->filter, PREFS->date_future_nbdays);
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, FALSE);
register_panel_listview_populate(data->LV_ope);
}
else
{
if(ui_flt_manage_dialog_new(data->window, data->filter, data->showall) != GTK_RESPONSE_REJECT)
{
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, FALSE);
register_panel_listview_populate(data->LV_ope);
register_panel_update(data->LV_ope, GINT_TO_POINTER(UF_SENSITIVE+UF_BALANCE));
}
......@@ -649,7 +649,7 @@ gint type;
filter_preset_type_set(data->filter, type);
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, FALSE);
register_panel_listview_populate(data->LV_ope);
}
......@@ -666,7 +666,7 @@ gint status;
filter_preset_status_set(data->filter, status);
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, FALSE);
register_panel_listview_populate(data->LV_ope);
}
......@@ -689,7 +689,7 @@ struct register_panel_data *data;
if( PREFS->date_future_nbdays > 0 )
filter_preset_daterange_add_futuregap(data->filter, PREFS->date_future_nbdays);
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, TRUE);
register_panel_listview_populate(data->LV_ope);
g_signal_handler_block(data->CY_range, data->handler_id[HID_RANGE]);
......@@ -773,7 +773,7 @@ gushort lpos = 1;
}
static void register_panel_collect_filtered_txn(GtkWidget *view)
static void register_panel_collect_filtered_txn(GtkWidget *view, gboolean emptysearch)
{
struct register_panel_data *data;
GList *lst_acc, *lnk_acc;
......@@ -821,10 +821,13 @@ GList *lnk_txn;
}
g_list_free(lst_acc);
g_signal_handler_block(data->ST_search, data->handler_id[HID_SEARCH]);
gtk_entry_set_text (GTK_ENTRY(data->ST_search), "");
g_signal_handler_unblock(data->ST_search, data->handler_id[HID_SEARCH]);
//#1789698 not always empty
if( emptysearch == TRUE )
{
g_signal_handler_block(data->ST_search, data->handler_id[HID_SEARCH]);
gtk_entry_set_text (GTK_ENTRY(data->ST_search), "");
g_signal_handler_unblock(data->ST_search, data->handler_id[HID_SEARCH]);
}
}
......@@ -1436,7 +1439,7 @@ gboolean result;
if(ui_flt_manage_dialog_new(data->window, data->filter, data->showall) != GTK_RESPONSE_REJECT)
{
register_panel_collect_filtered_txn(data->LV_ope);
register_panel_collect_filtered_txn(data->LV_ope, TRUE);
register_panel_listview_populate(data->LV_ope);
register_panel_update(data->LV_ope, GINT_TO_POINTER(UF_SENSITIVE+UF_BALANCE));
......
......@@ -1837,13 +1837,18 @@ void ui_mainwindow_open(GtkWidget *widget, gpointer user_data)
{
//struct hbfile_data *data;
gboolean bakmode = GPOINTER_TO_INT(user_data);;
gboolean doopen = TRUE;
gchar *filename = NULL;
DB( g_print("\n[ui-mainwindow] open\n") );
//data = g_object_get_data(G_OBJECT(gtk_widget_get_ancestor(widget, GTK_TYPE_WINDOW)), "inst_data");
if( ui_dialog_msg_savechanges(widget,NULL) == TRUE )
//#1791554 do ask for save confirm
if( bakmode != TRUE )
doopen = ui_dialog_msg_savechanges(widget,NULL);
if( doopen == TRUE )
{
if( ui_file_chooser_xhb(GTK_FILE_CHOOSER_ACTION_OPEN, &filename, bakmode) == TRUE )
{
......@@ -2342,33 +2347,27 @@ gint flags;
active = FALSE;
}
// no change: disable save
DB( g_print(" changes %d - new %d\n", GLOBALS->changes_count, GLOBALS->hbfile_is_new) );
// save
sensitive = (GLOBALS->changes_count != 0 ) ? TRUE : FALSE;
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/FileMenu/Save"), sensitive);
// backup
sensitive = ( (GLOBALS->changes_count != 0) && GLOBALS->xhb_hasrevert ) ? TRUE : FALSE;
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/FileMenu/Revert"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/FileMenu/OpenBak"), sensitive);
// define off ?
sensitive = GLOBALS->define_off == 0 ? TRUE : FALSE;
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/ManageMenu/Account"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/ManageMenu/Payee"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/ManageMenu/Category"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/ManageMenu/Budget"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/EditMenu/Preferences"), sensitive);
// empty account list: disable Import, Archives, Edit, Filter, Add, Statistics, Overdrawn, Car Cost
// empty account list: disable Archives, Edit, Filter, Add, Statistics, Overdrawn, Car Cost
sensitive = da_acc_length() > 0 ? TRUE : FALSE;
//gtk_action_set_sensitive(gtk_ui_manager_get_action(data-data->manager, "/MenuBar/FileMenu/Import"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/FileMenu/Close"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/ManageMenu/Archive"), sensitive);
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/TxnMenu/AddTxn"), sensitive);
......@@ -2389,16 +2388,13 @@ gint flags;
// empty archive list: disable scheduled check
sensitive = g_list_length(GLOBALS->arc_list) > 0 ? TRUE : FALSE;
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/TxnMenu/AddScheduled"), sensitive);
// no active account: disable Edit, Over
sensitive = (active == TRUE ) ? TRUE : FALSE;
if(data->acc && data->acc->window != NULL)
sensitive = FALSE;
gtk_action_set_sensitive(gtk_ui_manager_get_action(data->manager, "/MenuBar/TxnMenu/ShowTxn"), sensitive);
}
/* update toolbar, list */
......
......@@ -916,6 +916,7 @@ GList *list;
gentxn->memo = NULL;
gentxn->info = NULL;
// OFX:check_number
gentxn->info = g_strdup(gentxn->rawinfo);
if(ictx->opt_ofxname == 2)
......@@ -980,8 +981,14 @@ GList *list;
{
DB( g_print(" - csv option apply\n") );
//#1791656 missing: info, payee and tagsg_freg_free(gentxn->payee);
g_free(gentxn->payee);
g_free(gentxn->memo);
g_free(gentxn->info);
gentxn->payee = g_strdup(gentxn->rawpayee);
gentxn->memo = g_strdup(gentxn->rawmemo);
gentxn->info = g_strdup(gentxn->rawinfo);
}
//at last do ucfirst
......@@ -1105,6 +1112,13 @@ gint nsplit;
}
}
//#1791656 miss tags also...
if( gentxn->tags != NULL )
{
g_free(newope->tags);
newope->tags = tags_parse(gentxn->tags);
}
// splits, if not a xfer
if( gentxn->paymode != PAYMODE_INTXFER )
{
......
......@@ -773,7 +773,7 @@ GPtrArray *array;
g_free(dirname);
g_ptr_array_sort(array, (GCompareFunc)hb_filename_backup_list_sort_func);
return array;
}
......
......@@ -246,11 +246,13 @@ gboolean retval = FALSE;
if( g_file_test(filepath, G_FILE_TEST_EXISTS) )
{
DB( g_print(" - deleting: '%s'\n", filepath) );
g_remove(filepath);
retval = TRUE;
}
else
DB( g_print(" - cannot delete: '%s'\n", filepath) );
DB( g_print(" - deleted: '%s' :: %d\n", filepath, retval) );
return retval;
}
......@@ -259,7 +261,7 @@ void homebank_backup_current_file(void)
{
gchar *bakfilename;
GPtrArray *array;
guint i;
gint i;
DB( g_print("\n[homebank] backup_current_file\n") );
......@@ -286,18 +288,30 @@ guint i;
//delete any offscale backup
DB( g_print(" clean old backup\n") );
array = hb_filename_backup_list(GLOBALS->xhb_filepath);
for(i=0;i<array->len;i++)
DB( g_print(" found %d match\n", array->len) );
gchar *dirname = g_path_get_dirname(GLOBALS->xhb_filepath);
for(i=0;i<(gint)array->len;i++)
{
gchar *offscalefilename = g_ptr_array_index(array, i);
DB( g_print(" %d : '%s'\n", i, offscalefilename) );
if( i >= PREFS->bak_max_num_copies )
{
DB( g_print(" - should delete '%s'\n", offscalefilename) );
homebank_file_delete_existing(offscalefilename);
gchar *bakdelfilepath = g_build_filename(dirname, offscalefilename, NULL);
DB( g_print(" - should delete '%s'\n", bakdelfilepath) );
homebank_file_delete_existing(bakdelfilepath);
g_free(bakdelfilepath);
}
}
g_ptr_array_free(array, TRUE);
g_free(dirname);
}
}
......
......@@ -74,9 +74,9 @@
#define HB_VERSION_MAJOR 5
#define HB_VERSION_MINOR 2
#define HB_VERSION_MICRO 0
#define HB_VERSION_MICRO 1
#define HB_VERSION "5.2"
#define HB_VERSION "5.2.1"
#define HB_VERSION_NUM (HB_VERSION_MAJOR*10000) + (HB_VERSION_MINOR*100) + HB_VERSION_MICRO
#define FILE_VERSION 1.3
......
......@@ -85,7 +85,6 @@ Payee *item;
name = (gchar *)gtk_entry_get_text(GTK_ENTRY (gtk_bin_get_child(GTK_BIN (entry_box))));
item = da_pay_get_by_name(name);
g_free(name);
if( item != NULL )
return item->key;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment