mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Finish conversion to a GtkDialog. Redo dialog as a table instead of
boxes in boxes. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@12011 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
51dbc58b59
commit
154bfc33c2
@ -1,3 +1,9 @@
|
||||
2005-11-21 David Hampton <hampton@employees.org>
|
||||
|
||||
* src/gnome/glade/userpass.glade:
|
||||
* src/gnome/dialog-userpass.c: Finish conversion to a
|
||||
GtkDialog. Redo dialog as a table instead of boxes in boxes.
|
||||
|
||||
2005-11-21 Derek Atkins <derek@ihtfp.com>
|
||||
|
||||
* src/gnome-utils/Makefile.am: exit if "svn info" fails.
|
||||
|
@ -52,37 +52,37 @@ gnc_get_username_password (GtkWidget *parent,
|
||||
dialog = glade_xml_get_widget (xml, "Username Password Dialog");
|
||||
|
||||
if (parent)
|
||||
gnome_dialog_set_parent (GNOME_DIALOG (dialog), GTK_WINDOW (parent));
|
||||
gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (parent));
|
||||
|
||||
heading_label = glade_xml_get_widget (xml, "heading_label");
|
||||
username_entry = glade_xml_get_widget (xml, "username_entry");
|
||||
password_entry = glade_xml_get_widget (xml, "password_entry");
|
||||
|
||||
gnome_dialog_set_default (GNOME_DIALOG (dialog), 0);
|
||||
|
||||
if (heading)
|
||||
gtk_label_set_text (GTK_LABEL (heading_label), heading);
|
||||
|
||||
if (initial_username)
|
||||
gtk_entry_set_text (GTK_ENTRY (username_entry), initial_username);
|
||||
gtk_editable_select_region (GTK_EDITABLE (username_entry), 0, -1);
|
||||
|
||||
if (initial_password)
|
||||
gtk_entry_set_text (GTK_ENTRY (password_entry), initial_password);
|
||||
|
||||
gtk_widget_grab_focus (username_entry);
|
||||
result = gtk_dialog_run(GTK_DIALOG (dialog));
|
||||
gtk_widget_hide(dialog);
|
||||
|
||||
result = gnome_dialog_run_and_close (GNOME_DIALOG (dialog));
|
||||
|
||||
if (result == 0)
|
||||
if (result == GTK_RESPONSE_OK)
|
||||
{
|
||||
*username = gtk_editable_get_chars (GTK_EDITABLE (username_entry), 0, -1);
|
||||
*password = gtk_editable_get_chars (GTK_EDITABLE (password_entry), 0, -1);
|
||||
|
||||
gtk_widget_destroy(dialog);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
*username = NULL;
|
||||
*password = NULL;
|
||||
|
||||
gtk_widget_destroy(dialog);
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -39,7 +39,7 @@
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="focus_on_click">True</property>
|
||||
<property name="response_id">0</property>
|
||||
<property name="response_id">-6</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
@ -47,12 +47,13 @@
|
||||
<widget class="GtkButton" id="okbutton">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="has_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-ok</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="focus_on_click">True</property>
|
||||
<property name="response_id">0</property>
|
||||
<property name="response_id">-5</property>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
@ -86,30 +87,20 @@
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkFrame" id="frame47">
|
||||
<property name="visible">True</property>
|
||||
<property name="label_xalign">0</property>
|
||||
<property name="label_yalign">0.5</property>
|
||||
<property name="shadow_type">GTK_SHADOW_ETCHED_IN</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkHBox" id="hbox95">
|
||||
<property name="border_width">10</property>
|
||||
<widget class="GtkTable" id="table1">
|
||||
<property name="border_width">6</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">2</property>
|
||||
<property name="n_columns">2</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">2</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkVBox" id="vbox105">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="spacing">5</property>
|
||||
<property name="row_spacing">6</property>
|
||||
<property name="column_spacing">12</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label847713">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Username:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="label" translatable="yes">_Username:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_CENTER</property>
|
||||
<property name="wrap">False</property>
|
||||
@ -118,19 +109,23 @@
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
<property name="mnemonic_widget">username_entry</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label847714">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Password:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="label" translatable="yes">_Password:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_CENTER</property>
|
||||
<property name="wrap">False</property>
|
||||
@ -139,43 +134,37 @@
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
<property name="mnemonic_widget">password_entry</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkVBox" id="vbox106">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="spacing">5</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkEntry" id="username_entry">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="has_focus">True</property>
|
||||
<property name="editable">True</property>
|
||||
<property name="visibility">True</property>
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="invisible_char">*</property>
|
||||
<property name="activates_default">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
@ -188,13 +177,15 @@
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="invisible_char">*</property>
|
||||
<property name="activates_default">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
@ -206,15 +197,6 @@
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
|
||||
</glade-interface>
|
||||
|
Loading…
Reference in New Issue
Block a user