mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
More HIG changes.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@12950 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
fda788321c
commit
59cd5535dd
@ -1,5 +1,11 @@
|
||||
2006-01-22 David Hampton <hampton@employees.org>
|
||||
|
||||
* src/gnome-utils/glade/commodity.glade:
|
||||
* src/gnome/dialog-price-editor.c:
|
||||
* src/gnome/glade/progress.glade:
|
||||
* src/gnome/glade/price.glade:
|
||||
* src/gnome/dialog-price-edit-db.c: More HIG changes.
|
||||
|
||||
* src/scm/printing/print-check.scm:
|
||||
* src/gnome/glade/print.glade:
|
||||
* src/gnome/schemas/Makefile.am:
|
||||
|
@ -28,7 +28,7 @@
|
||||
<child internal-child="action_area">
|
||||
<widget class="GtkHButtonBox" id="dialog-action_area12">
|
||||
<property name="visible">True</property>
|
||||
<property name="layout_style">GTK_BUTTONBOX_EDGE</property>
|
||||
<property name="layout_style">GTK_BUTTONBOX_END</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="new_button">
|
||||
|
@ -179,7 +179,7 @@ gnc_prices_dialog_remove_old_clicked (GtkWidget *widget, gpointer data)
|
||||
{
|
||||
PricesDialog *pdb_dialog = data;
|
||||
GladeXML *xml;
|
||||
GtkWidget *dialog, *button, *date;
|
||||
GtkWidget *dialog, *button, *date, *label;
|
||||
gint result;
|
||||
gboolean delete_user, delete_last;
|
||||
|
||||
@ -187,6 +187,8 @@ gnc_prices_dialog_remove_old_clicked (GtkWidget *widget, gpointer data)
|
||||
xml = gnc_glade_xml_new ("price.glade", "Deletion Date");
|
||||
dialog = glade_xml_get_widget (xml, "Deletion Date");
|
||||
date = glade_xml_get_widget (xml, "date");
|
||||
label = glade_xml_get_widget (xml, "date_label");
|
||||
gnc_date_make_mnemonic_target (GNC_DATE_EDIT(date), label);
|
||||
glade_xml_signal_autoconnect_full(xml, gnc_glade_autoconnect_full_func, pdb_dialog);
|
||||
gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (pdb_dialog->dialog));
|
||||
|
||||
|
@ -56,7 +56,7 @@ typedef struct
|
||||
GtkWidget * currency_edit;
|
||||
GtkWidget * date_edit;
|
||||
GtkWidget * source_entry;
|
||||
GtkWidget * type_option;
|
||||
GtkWidget * type_combobox;
|
||||
GtkWidget * price_edit;
|
||||
|
||||
GNCPrice *price;
|
||||
@ -65,6 +65,8 @@ typedef struct
|
||||
|
||||
} PriceEditDialog;
|
||||
|
||||
void pedit_dialog_response_cb (GtkDialog *dialog, gint response, gpointer data);
|
||||
void pedit_data_changed_cb (GtkWidget *w, gpointer data);
|
||||
|
||||
|
||||
static void
|
||||
@ -146,9 +148,8 @@ price_to_gui (PriceEditDialog *pedit_dialog)
|
||||
|
||||
gtk_entry_set_text (GTK_ENTRY (pedit_dialog->source_entry), source);
|
||||
|
||||
gtk_option_menu_set_history (GTK_OPTION_MENU (pedit_dialog->type_option),
|
||||
type_string_to_index (type));
|
||||
|
||||
gtk_combo_box_set_active (GTK_COMBO_BOX(pedit_dialog->type_combobox),
|
||||
type_string_to_index (type));
|
||||
gnc_amount_edit_set_amount (GNC_AMOUNT_EDIT (pedit_dialog->price_edit), value);
|
||||
}
|
||||
|
||||
@ -178,7 +179,7 @@ gui_to_price (PriceEditDialog *pedit_dialog)
|
||||
date.tv_nsec = 0;
|
||||
|
||||
type = type_index_to_string
|
||||
(gnc_option_menu_get_active (pedit_dialog->type_option));
|
||||
(gtk_combo_box_get_active (GTK_COMBO_BOX (pedit_dialog->type_combobox)));
|
||||
|
||||
if (!gnc_amount_edit_evaluate (GNC_AMOUNT_EDIT (pedit_dialog->price_edit)))
|
||||
return _("You must enter a valid amount.");
|
||||
@ -198,7 +199,7 @@ gui_to_price (PriceEditDialog *pedit_dialog)
|
||||
}
|
||||
|
||||
static void
|
||||
price_window_destroy_cb (GtkWidget *widget, gpointer data)
|
||||
pedit_dialog_destroy_cb (GtkWidget *widget, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
@ -215,8 +216,8 @@ price_window_destroy_cb (GtkWidget *widget, gpointer data)
|
||||
g_free (pedit_dialog);
|
||||
}
|
||||
|
||||
static void
|
||||
pedit_dialog_response (GtkDialog *dialog, gint response, gpointer data)
|
||||
void
|
||||
pedit_dialog_response_cb (GtkDialog *dialog, gint response, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
GNCBook *book = gnc_get_current_book ();
|
||||
@ -237,7 +238,9 @@ pedit_dialog_response (GtkDialog *dialog, gint response, gpointer data)
|
||||
gnc_gui_refresh_all ();
|
||||
}
|
||||
|
||||
gnc_save_window_size(GCONF_SECTION, GTK_WINDOW(pedit_dialog->dialog));
|
||||
gtk_widget_destroy (GTK_WIDGET (pedit_dialog->dialog));
|
||||
pedit_dialog_destroy_cb (NULL, pedit_dialog);
|
||||
}
|
||||
|
||||
static void
|
||||
@ -279,47 +282,8 @@ commodity_changed_cb (GNCGeneralSelect *gsl, gpointer data)
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
currency_changed_cb (GtkWidget *w, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
gnc_prices_set_changed (pedit_dialog, TRUE);
|
||||
}
|
||||
|
||||
static void
|
||||
date_changed_cb (GNCDateEdit *gde, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
gnc_prices_set_changed (pedit_dialog, TRUE);
|
||||
}
|
||||
|
||||
static void
|
||||
date_entry_changed_cb (GtkWidget *w, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
gnc_prices_set_changed (pedit_dialog, TRUE);
|
||||
}
|
||||
|
||||
static void
|
||||
type_menu_changed (GtkButton *button, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
gnc_prices_set_changed (pedit_dialog, TRUE);
|
||||
}
|
||||
|
||||
static void
|
||||
connect_type_menu_item (GtkWidget *item, gpointer data)
|
||||
{
|
||||
g_signal_connect (G_OBJECT(item), "activate",
|
||||
G_CALLBACK (type_menu_changed), data);
|
||||
}
|
||||
|
||||
static void
|
||||
amount_changed_cb (GtkWidget *w, gpointer data)
|
||||
void
|
||||
pedit_data_changed_cb (GtkWidget *w, gpointer data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = data;
|
||||
|
||||
@ -333,9 +297,9 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
GNCPrintAmountInfo print_info;
|
||||
GtkWidget *dialog;
|
||||
GtkWidget *entry;
|
||||
GtkWidget *menu;
|
||||
GtkWidget *box;
|
||||
GtkWidget *w;
|
||||
GtkWidget *label;
|
||||
|
||||
xml = gnc_glade_xml_new ("price.glade", "Price Dialog");
|
||||
|
||||
@ -346,13 +310,6 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
if (parent != NULL)
|
||||
gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (parent));
|
||||
|
||||
g_signal_connect (G_OBJECT (dialog), "response",
|
||||
G_CALLBACK (pedit_dialog_response), pedit_dialog);
|
||||
|
||||
g_signal_connect (G_OBJECT (dialog), "destroy",
|
||||
G_CALLBACK (price_window_destroy_cb),
|
||||
pedit_dialog);
|
||||
|
||||
box = glade_xml_get_widget (xml, "commodity_box");
|
||||
w = gnc_general_select_new (GNC_GENERAL_SELECT_TYPE_SELECT,
|
||||
gnc_commodity_edit_get_string,
|
||||
@ -363,6 +320,8 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
gtk_widget_show (w);
|
||||
g_signal_connect (G_OBJECT (w), "changed",
|
||||
G_CALLBACK (commodity_changed_cb), pedit_dialog);
|
||||
label = glade_xml_get_widget (xml, "commodity_label");
|
||||
gnc_general_select_make_mnemonic_target (GNC_GENERAL_SELECT(w), label);
|
||||
|
||||
|
||||
box = glade_xml_get_widget (xml, "currency_box");
|
||||
@ -373,7 +332,9 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
gtk_box_pack_start (GTK_BOX (box), w, TRUE, TRUE, 0);
|
||||
gtk_widget_show (w);
|
||||
g_signal_connect (G_OBJECT (GTK_COMBO_BOX(w)), "changed",
|
||||
G_CALLBACK (currency_changed_cb), pedit_dialog);
|
||||
G_CALLBACK (pedit_data_changed_cb), pedit_dialog);
|
||||
label = glade_xml_get_widget (xml, "currency_label");
|
||||
gtk_label_set_mnemonic_widget (GTK_LABEL(label), w);
|
||||
|
||||
box = glade_xml_get_widget (xml, "date_box");
|
||||
w = gnc_date_edit_new (time (NULL), FALSE, FALSE);
|
||||
@ -381,23 +342,19 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
gtk_box_pack_start (GTK_BOX (box), w, TRUE, TRUE, 0);
|
||||
gtk_widget_show (w);
|
||||
g_signal_connect (G_OBJECT (w), "date_changed",
|
||||
G_CALLBACK (date_changed_cb), pedit_dialog);
|
||||
G_CALLBACK (pedit_data_changed_cb), pedit_dialog);
|
||||
g_signal_connect (G_OBJECT (GNC_DATE_EDIT (w)->date_entry), "changed",
|
||||
G_CALLBACK (date_entry_changed_cb), pedit_dialog);
|
||||
G_CALLBACK (pedit_data_changed_cb), pedit_dialog);
|
||||
gtk_entry_set_activates_default(GTK_ENTRY(GNC_DATE_EDIT(w)->date_entry), TRUE);
|
||||
label = glade_xml_get_widget (xml, "date_label");
|
||||
gnc_date_make_mnemonic_target (GNC_DATE_EDIT(w), label);
|
||||
|
||||
|
||||
w = glade_xml_get_widget (xml, "source_entry");
|
||||
pedit_dialog->source_entry = w;
|
||||
|
||||
w = glade_xml_get_widget (xml, "type_option");
|
||||
pedit_dialog->type_option = w;
|
||||
|
||||
|
||||
gnc_option_menu_init (w);
|
||||
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (w));
|
||||
gtk_container_forall (GTK_CONTAINER (menu),
|
||||
connect_type_menu_item, pedit_dialog);
|
||||
w = glade_xml_get_widget (xml, "type_combobox");
|
||||
pedit_dialog->type_combobox = w;
|
||||
|
||||
box = glade_xml_get_widget (xml, "price_box");
|
||||
w = gnc_amount_edit_new ();
|
||||
@ -409,10 +366,17 @@ gnc_price_pedit_dialog_create (GtkWidget * parent, PriceEditDialog *pedit_dialog
|
||||
gnc_amount_edit_set_fraction (GNC_AMOUNT_EDIT (w), 1000000);
|
||||
gtk_entry_set_activates_default(GTK_ENTRY(w), TRUE);
|
||||
gtk_widget_show (w);
|
||||
label = glade_xml_get_widget (xml, "price_label");
|
||||
gtk_label_set_mnemonic_widget (GTK_LABEL(label), w);
|
||||
|
||||
entry = gnc_amount_edit_gtk_entry (GNC_AMOUNT_EDIT (w));
|
||||
g_signal_connect (G_OBJECT (entry), "changed",
|
||||
G_CALLBACK (amount_changed_cb), pedit_dialog);
|
||||
G_CALLBACK (pedit_data_changed_cb), pedit_dialog);
|
||||
|
||||
glade_xml_signal_autoconnect_full( xml,
|
||||
gnc_glade_autoconnect_full_func,
|
||||
pedit_dialog );
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
@ -436,8 +400,7 @@ close_handler (gpointer user_data)
|
||||
{
|
||||
PriceEditDialog *pedit_dialog = user_data;
|
||||
|
||||
gnc_save_window_size(GCONF_SECTION, GTK_WINDOW(pedit_dialog->dialog));
|
||||
gtk_widget_destroy (GTK_WIDGET (pedit_dialog->dialog));
|
||||
gtk_dialog_response(GTK_DIALOG(pedit_dialog->dialog), GTK_RESPONSE_CANCEL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -5,12 +5,13 @@
|
||||
<requires lib="gnome"/>
|
||||
|
||||
<widget class="GtkWindow" id="Progress Dialog">
|
||||
<property name="border_width">6</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="title" translatable="yes">Working...</property>
|
||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||
<property name="modal">True</property>
|
||||
<property name="resizable">True</property>
|
||||
<property name="resizable">False</property>
|
||||
<property name="destroy_with_parent">False</property>
|
||||
<property name="decorated">True</property>
|
||||
<property name="skip_taskbar_hint">False</property>
|
||||
@ -23,7 +24,7 @@
|
||||
<property name="border_width">5</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">5</property>
|
||||
<property name="spacing">6</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="heading_label">
|
||||
@ -51,7 +52,7 @@
|
||||
<property name="visible">True</property>
|
||||
<property name="orientation">GTK_PROGRESS_LEFT_TO_RIGHT</property>
|
||||
<property name="fraction">0</property>
|
||||
<property name="pulse_step">0.1</property>
|
||||
<property name="pulse_step">0.10000000149</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
@ -64,7 +65,7 @@
|
||||
<widget class="GtkHButtonBox" id="hbuttonbox3">
|
||||
<property name="visible">True</property>
|
||||
<property name="layout_style">GTK_BUTTONBOX_END</property>
|
||||
<property name="spacing">30</property>
|
||||
<property name="spacing">6</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="cancel_button">
|
||||
|
Loading…
Reference in New Issue
Block a user