mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Kevin Finn's patch to set option widget sensitivities.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@2567 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
94cf525150
commit
4396cd5d39
@ -378,6 +378,36 @@ gnc_option_get_ui_value(GNCOption *option)
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/********************************************************************\
|
||||
* gnc_set_option_selectable_by_name *
|
||||
* Change the selectable state of the widget that represents a *
|
||||
* GUI option. *
|
||||
* *
|
||||
* Args: section - section of option *
|
||||
* name - name of option
|
||||
* selectable - if false, update the widget so that it *
|
||||
* cannot be selected by the user. If true, *
|
||||
* update the widget so that it can be selected.*
|
||||
* Return: nothing *
|
||||
\********************************************************************/
|
||||
void
|
||||
gnc_set_option_selectable_by_name( const char *section,
|
||||
const char *name,
|
||||
gncBoolean selectable)
|
||||
{
|
||||
GNCOption *option = gnc_get_option_by_name( section, name );
|
||||
|
||||
if ((option == NULL) || (option->widget == NULL))
|
||||
return;
|
||||
|
||||
gtk_widget_set_sensitive( GTK_WIDGET(option->widget),
|
||||
selectable );
|
||||
|
||||
return;
|
||||
} /* gnc_set_option_selectable_by_name */
|
||||
|
||||
|
||||
static void
|
||||
default_button_cb(GtkButton *button, gpointer data)
|
||||
{
|
||||
|
@ -752,7 +752,6 @@ static void
|
||||
gnc_configure_auto_decimal_cb(void *not_used)
|
||||
{
|
||||
gnc_configure_auto_decimal();
|
||||
gnc_group_ui_refresh(gncGetCurrentGroup());
|
||||
}
|
||||
|
||||
/* gnc_configure_auto_decimal
|
||||
|
Loading…
Reference in New Issue
Block a user