mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Merge maint. The gnc_gui_refresh_all statement in gnc_book_options_dialog_apply_cb causes the 'apply' and 'OK' buttons to be set to sensitive on the open Book Options dialog in some circumstances; this commit causes them to be reset to insensitive, as they should be.
This commit is contained in:
commit
079257a074
6
README
6
README
@ -323,8 +323,7 @@ Getting Source with Git
|
|||||||
We maintain a mirror of our master repository on Github. You can
|
We maintain a mirror of our master repository on Github. You can
|
||||||
browse the code at https://github.com/Gnucash/gnucash. Clone URIs are
|
browse the code at https://github.com/Gnucash/gnucash. Clone URIs are
|
||||||
on that page, or if you have a Github account you can fork it
|
on that page, or if you have a Github account you can fork it
|
||||||
there. Note, however, that we do *not* accept Github pull requests:
|
there.
|
||||||
All patches should be submitted via Bugzilla, see below.
|
|
||||||
|
|
||||||
##################
|
##################
|
||||||
Developing GnuCash
|
Developing GnuCash
|
||||||
@ -355,5 +354,8 @@ Submitting a Patch:
|
|||||||
patches to either of the mailing lists, as they tend to be
|
patches to either of the mailing lists, as they tend to be
|
||||||
forgotten.
|
forgotten.
|
||||||
|
|
||||||
|
Alternatively, you can also submit your patches in the form of a git
|
||||||
|
pull request.
|
||||||
|
|
||||||
|
|
||||||
Thank you.
|
Thank you.
|
||||||
|
@ -263,7 +263,6 @@ gnc_book_option_num_field_source_change_cb (gboolean num_action)
|
|||||||
}
|
}
|
||||||
gnc_book_option_num_field_source_change (num_action);
|
gnc_book_option_num_field_source_change (num_action);
|
||||||
gnc_resume_gui_refresh ();
|
gnc_resume_gui_refresh ();
|
||||||
gnc_gui_refresh_all ();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Calls gnc_book_option_book_currency_selected to initiate registered
|
/** Calls gnc_book_option_book_currency_selected to initiate registered
|
||||||
|
@ -9,7 +9,7 @@ SET(GNC_BUILDDIR ${CMAKE_BINARY_DIR})
|
|||||||
|
|
||||||
CONFIGURE_FILE(gnucash-make-guids.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-make-guids)
|
CONFIGURE_FILE(gnucash-make-guids.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-make-guids)
|
||||||
GNC_CONFIGURE(gnucash-env.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-env)
|
GNC_CONFIGURE(gnucash-env.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-env)
|
||||||
GNC_CONFIGURE(guile.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/guile)
|
GNC_CONFIGURE(guile.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/guile) #not installed
|
||||||
GNC_CONFIGURE(gnucash-build-env.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-build-env) # not installed
|
GNC_CONFIGURE(gnucash-build-env.in ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/gnucash-build-env) # not installed
|
||||||
|
|
||||||
SET(SCRIPT_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR})
|
SET(SCRIPT_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR})
|
||||||
@ -28,6 +28,5 @@ INSTALL(
|
|||||||
PROGRAMS
|
PROGRAMS
|
||||||
${SCRIPT_OUTPUT_DIR}/gnucash-env
|
${SCRIPT_OUTPUT_DIR}/gnucash-env
|
||||||
${SCRIPT_OUTPUT_DIR}/gnucash-make-guids
|
${SCRIPT_OUTPUT_DIR}/gnucash-make-guids
|
||||||
${SCRIPT_OUTPUT_DIR}/guile
|
|
||||||
DESTINATION libexec/gnucash/overrides
|
DESTINATION libexec/gnucash/overrides
|
||||||
)
|
)
|
@ -2,8 +2,7 @@ gncoverridesdir = ${GNC_LIBEXECDIR}/overrides
|
|||||||
# When you add a file here, please modify ../test/Makefile.am's overrides.stamp
|
# When you add a file here, please modify ../test/Makefile.am's overrides.stamp
|
||||||
gncoverrides_SCRIPTS = \
|
gncoverrides_SCRIPTS = \
|
||||||
gnucash-env \
|
gnucash-env \
|
||||||
gnucash-make-guids \
|
gnucash-make-guids
|
||||||
guile
|
|
||||||
|
|
||||||
EXTRA_DIST = \
|
EXTRA_DIST = \
|
||||||
gnucash-env.in \
|
gnucash-env.in \
|
||||||
@ -11,7 +10,7 @@ EXTRA_DIST = \
|
|||||||
gnucash-make-guids \
|
gnucash-make-guids \
|
||||||
guile.in
|
guile.in
|
||||||
|
|
||||||
noinst_DATA = gnucash-build-env
|
noinst_DATA = gnucash-build-env guile
|
||||||
|
|
||||||
PWD := $(shell pwd)
|
PWD := $(shell pwd)
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
exec gnucash-env @GUILE@ -s "$0" "$@"
|
exec gnucash-env guile -s "$0" "$@"
|
||||||
!#
|
!#
|
||||||
|
|
||||||
(define (usage)
|
(define (usage)
|
||||||
|
@ -168,6 +168,14 @@ gnc_options_dialog_changed (GNCOptionWin *win)
|
|||||||
gnc_options_dialog_changed_internal (win->dialog, TRUE);
|
gnc_options_dialog_changed_internal (win->dialog, TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
gnc_options_dialog_not_changed (GNCOptionWin *win)
|
||||||
|
{
|
||||||
|
if (!win) return;
|
||||||
|
|
||||||
|
gnc_options_dialog_changed_internal (win->dialog, FALSE);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
gnc_option_changed_widget_cb(GtkWidget *widget, GNCOption *option)
|
gnc_option_changed_widget_cb(GtkWidget *widget, GNCOption *option)
|
||||||
{
|
{
|
||||||
|
@ -46,6 +46,7 @@ GtkWidget * gnc_options_page_list(GNCOptionWin * win);
|
|||||||
GtkWidget * gnc_options_dialog_notebook(GNCOptionWin * win);
|
GtkWidget * gnc_options_dialog_notebook(GNCOptionWin * win);
|
||||||
|
|
||||||
void gnc_options_dialog_changed (GNCOptionWin *win);
|
void gnc_options_dialog_changed (GNCOptionWin *win);
|
||||||
|
void gnc_options_dialog_not_changed (GNCOptionWin *win);
|
||||||
|
|
||||||
void gnc_option_changed_widget_cb(GtkWidget *widget, GNCOption *option);
|
void gnc_option_changed_widget_cb(GtkWidget *widget, GNCOption *option);
|
||||||
void gnc_option_changed_option_cb(GtkWidget *dummy, GNCOption *option);
|
void gnc_option_changed_option_cb(GtkWidget *dummy, GNCOption *option);
|
||||||
|
@ -3923,7 +3923,7 @@ gnc_main_window_cmd_page_setup (GtkAction *action,
|
|||||||
gnc_ui_page_setup(gtk_window);
|
gnc_ui_page_setup(gtk_window);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
gboolean
|
||||||
gnc_book_options_dialog_apply_helper(GNCOptionDB * options)
|
gnc_book_options_dialog_apply_helper(GNCOptionDB * options)
|
||||||
{
|
{
|
||||||
QofBook *book = gnc_get_current_book ();
|
QofBook *book = gnc_get_current_book ();
|
||||||
@ -3933,8 +3933,9 @@ gnc_book_options_dialog_apply_helper(GNCOptionDB * options)
|
|||||||
gnc_book_use_book_currency (book);
|
gnc_book_use_book_currency (book);
|
||||||
gboolean use_split_action_for_num_after;
|
gboolean use_split_action_for_num_after;
|
||||||
gboolean use_book_currency_after;
|
gboolean use_book_currency_after;
|
||||||
|
gboolean return_val = FALSE;
|
||||||
|
|
||||||
if (!options) return;
|
if (!options) return return_val;
|
||||||
|
|
||||||
gnc_option_db_commit (options);
|
gnc_option_db_commit (options);
|
||||||
qof_book_begin_edit (book);
|
qof_book_begin_edit (book);
|
||||||
@ -3943,11 +3944,18 @@ gnc_book_options_dialog_apply_helper(GNCOptionDB * options)
|
|||||||
qof_book_use_split_action_for_num_field (book);
|
qof_book_use_split_action_for_num_field (book);
|
||||||
use_book_currency_after = gnc_book_use_book_currency (book);
|
use_book_currency_after = gnc_book_use_book_currency (book);
|
||||||
if (use_split_action_for_num_before != use_split_action_for_num_after)
|
if (use_split_action_for_num_before != use_split_action_for_num_after)
|
||||||
|
{
|
||||||
gnc_book_option_num_field_source_change_cb (
|
gnc_book_option_num_field_source_change_cb (
|
||||||
use_split_action_for_num_after);
|
use_split_action_for_num_after);
|
||||||
|
return_val = TRUE;
|
||||||
|
}
|
||||||
if (use_book_currency_before != use_book_currency_after)
|
if (use_book_currency_before != use_book_currency_after)
|
||||||
|
{
|
||||||
gnc_book_option_book_currency_selected_cb (use_book_currency_after);
|
gnc_book_option_book_currency_selected_cb (use_book_currency_after);
|
||||||
|
return_val = TRUE;
|
||||||
|
}
|
||||||
qof_book_commit_edit (book);
|
qof_book_commit_edit (book);
|
||||||
|
return return_val;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@ -3955,8 +3963,18 @@ gnc_book_options_dialog_apply_cb(GNCOptionWin * optionwin,
|
|||||||
gpointer user_data)
|
gpointer user_data)
|
||||||
{
|
{
|
||||||
GNCOptionDB * options = user_data;
|
GNCOptionDB * options = user_data;
|
||||||
|
|
||||||
if (!options) return;
|
if (!options) return;
|
||||||
gnc_book_options_dialog_apply_helper (options);
|
|
||||||
|
if (gnc_book_options_dialog_apply_helper (options));
|
||||||
|
{
|
||||||
|
gnc_gui_refresh_all ();
|
||||||
|
if (!optionwin) return;
|
||||||
|
/* the previous stmt causes the 'apply' and 'OK' buttons to be set to
|
||||||
|
sensitive on the open Book Options dialog; the next stmt resets them
|
||||||
|
to insensitive, as they should be */
|
||||||
|
gnc_options_dialog_not_changed (optionwin);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -431,8 +431,9 @@ GtkWidget *gnc_book_options_dialog_cb (gboolean modal, gchar *title);
|
|||||||
*
|
*
|
||||||
* @param GNCOptionDB * options.
|
* @param GNCOptionDB * options.
|
||||||
*
|
*
|
||||||
|
* @return TRUE if gnc_gui_refresh_all should be called; otherwise FALSE.
|
||||||
**/
|
**/
|
||||||
void gnc_book_options_dialog_apply_helper(GNCOptionDB * options);
|
gboolean gnc_book_options_dialog_apply_helper(GNCOptionDB * options);
|
||||||
|
|
||||||
#endif /* __GNC_MAIN_WINDOW_H */
|
#endif /* __GNC_MAIN_WINDOW_H */
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user