2006-09-27 [wwp] 2.5.2cvs9
* src/editgroup.c * src/send_message.c * src/inc.c * src/prefs_common.c * src/prefs_common.h * src/gtk/progressdialog.c remember more windows' sizes (send dialog, received dialog, edit group in addressbook).
This commit is contained in:
parent
e90b426fba
commit
37460fff49
9 changed files with 101 additions and 7 deletions
11
ChangeLog
11
ChangeLog
|
@ -1,3 +1,14 @@
|
|||
2006-09-27 [wwp] 2.5.2cvs9
|
||||
|
||||
* src/editgroup.c
|
||||
* src/send_message.c
|
||||
* src/inc.c
|
||||
* src/prefs_common.c
|
||||
* src/prefs_common.h
|
||||
* src/gtk/progressdialog.c
|
||||
remember more windows' sizes (send dialog, received dialog,
|
||||
edit group in addressbook).
|
||||
|
||||
2006-09-27 [colin] 2.5.2cvs8
|
||||
|
||||
* configure.ac
|
||||
|
|
|
@ -1922,3 +1922,4 @@
|
|||
( cvs diff -u -r 1.382.2.311 -r 1.382.2.312 src/compose.c; cvs diff -u -r 1.50.2.26 -r 1.50.2.27 src/compose.h; cvs diff -u -r 1.274.2.150 -r 1.274.2.151 src/mainwindow.c; cvs diff -u -r 1.96.2.150 -r 1.96.2.151 src/textview.c; cvs diff -u -r 1.43.2.52 -r 1.43.2.53 src/toolbar.c; ) > 2.5.2cvs6.patchset
|
||||
( cvs diff -u -r 1.60.2.64 -r 1.60.2.65 src/addressbook.c; ) > 2.5.2cvs7.patchset
|
||||
( cvs diff -u -r 1.654.2.1971 -r 1.654.2.1972 configure.ac; cvs diff -u -r 1.115.2.104 -r 1.115.2.105 src/main.c; cvs diff -u -r 1.39.2.23 -r 1.39.2.24 src/mainwindow.h; ) > 2.5.2cvs8.patchset
|
||||
( cvs diff -u -r 1.11.2.12 -r 1.11.2.13 src/editgroup.c; cvs diff -u -r 1.17.2.32 -r 1.17.2.33 src/send_message.c; cvs diff -u -r 1.149.2.58 -r 1.149.2.59 src/inc.c; cvs diff -u -r 1.204.2.103 -r 1.204.2.104 src/prefs_common.c; cvs diff -u -r 1.103.2.61 -r 1.103.2.62 src/prefs_common.h; cvs diff -u -r 1.1.4.18 -r 1.1.4.19 src/gtk/progressdialog.c; ) > 2.5.2cvs9.patchset
|
||||
|
|
|
@ -11,7 +11,7 @@ MINOR_VERSION=5
|
|||
MICRO_VERSION=2
|
||||
INTERFACE_AGE=0
|
||||
BINARY_AGE=0
|
||||
EXTRA_VERSION=8
|
||||
EXTRA_VERSION=9
|
||||
EXTRA_RELEASE=
|
||||
EXTRA_GTK2_VERSION=
|
||||
|
||||
|
|
|
@ -44,9 +44,6 @@
|
|||
#define ADDRESSBOOK_GUESS_FOLDER_NAME "NewFolder"
|
||||
#define ADDRESSBOOK_GUESS_GROUP_NAME "NewGroup"
|
||||
|
||||
#define EDITGROUP_WIDTH 580
|
||||
#define EDITGROUP_HEIGHT 340
|
||||
|
||||
typedef enum {
|
||||
GROUP_COL_NAME = 0,
|
||||
GROUP_COL_EMAIL = 1,
|
||||
|
@ -248,6 +245,15 @@ static gint edit_group_list_compare_func( GtkCList *clist, gconstpointer ptr1, g
|
|||
return g_utf8_collate( name1, name2 );
|
||||
}
|
||||
|
||||
static void addressbook_edit_group_size_allocate_cb(GtkWidget *widget,
|
||||
GtkAllocation *allocation)
|
||||
{
|
||||
g_return_if_fail(allocation != NULL);
|
||||
|
||||
prefs_common.addressbookeditgroupwin_width = allocation->width;
|
||||
prefs_common.addressbookeditgroupwin_height = allocation->height;
|
||||
}
|
||||
|
||||
static void addressbook_edit_group_create( gboolean *cancelled ) {
|
||||
GtkWidget *window;
|
||||
GtkWidget *vbox;
|
||||
|
@ -276,12 +282,13 @@ static void addressbook_edit_group_create( gboolean *cancelled ) {
|
|||
gchar *titles[ GROUP_N_COLS ];
|
||||
gint i;
|
||||
|
||||
static GdkGeometry geometry;
|
||||
|
||||
titles[ GROUP_COL_NAME ] = _( "Name" );
|
||||
titles[ GROUP_COL_EMAIL ] = _("Email Address");
|
||||
titles[ GROUP_COL_REMARKS ] = _("Remarks");
|
||||
|
||||
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
|
||||
gtk_widget_set_size_request(window, EDITGROUP_WIDTH, EDITGROUP_HEIGHT );
|
||||
gtk_container_set_border_width(GTK_CONTAINER(window), 0);
|
||||
gtk_window_set_title(GTK_WINDOW(window), _("Edit Group Data"));
|
||||
gtk_window_set_position(GTK_WINDOW(window), GTK_WIN_POS_CENTER);
|
||||
|
@ -292,6 +299,8 @@ static void addressbook_edit_group_create( gboolean *cancelled ) {
|
|||
g_signal_connect(G_OBJECT(window), "key_press_event",
|
||||
G_CALLBACK(edit_group_key_pressed),
|
||||
cancelled);
|
||||
g_signal_connect(G_OBJECT(window), "size_allocate",
|
||||
G_CALLBACK(addressbook_edit_group_size_allocate_cb), NULL);
|
||||
|
||||
vbox = gtk_vbox_new( FALSE, 6 );
|
||||
gtk_container_set_border_width(GTK_CONTAINER(vbox), BORDER_WIDTH);
|
||||
|
@ -411,6 +420,17 @@ static void addressbook_edit_group_create( gboolean *cancelled ) {
|
|||
g_signal_connect(G_OBJECT(clist_group), "button_press_event",
|
||||
G_CALLBACK(edit_group_list_group_button), NULL);
|
||||
|
||||
if (!geometry.min_height) {
|
||||
geometry.min_width = 580;
|
||||
geometry.min_height = 340;
|
||||
}
|
||||
|
||||
gtk_window_set_geometry_hints(GTK_WINDOW(window), NULL, &geometry,
|
||||
GDK_HINT_MIN_SIZE);
|
||||
gtk_widget_set_size_request(window,
|
||||
prefs_common.addressbookeditgroupwin_width,
|
||||
prefs_common.addressbookeditgroupwin_height);
|
||||
|
||||
groupeditdlg.window = window;
|
||||
groupeditdlg.ok_btn = ok_btn;
|
||||
groupeditdlg.cancel_btn = cancel_btn;
|
||||
|
|
|
@ -73,7 +73,6 @@ ProgressDialog *progress_dialog_create(void)
|
|||
progress = g_new0(ProgressDialog, 1);
|
||||
|
||||
dialog = gtk_dialog_new();
|
||||
gtk_widget_set_size_request(dialog, 460, -1);
|
||||
gtk_container_set_border_width(GTK_CONTAINER(dialog), 8);
|
||||
gtk_window_set_resizable(GTK_WINDOW(dialog), TRUE);
|
||||
gtk_widget_realize(dialog);
|
||||
|
|
24
src/inc.c
24
src/inc.c
|
@ -362,10 +362,20 @@ void inc_all_account_mail(MainWindow *mainwin, gboolean autocheck,
|
|||
inc_autocheck_timer_set();
|
||||
}
|
||||
|
||||
static void inc_progress_dialog_size_allocate_cb(GtkWidget *widget,
|
||||
GtkAllocation *allocation)
|
||||
{
|
||||
g_return_if_fail(allocation != NULL);
|
||||
|
||||
prefs_common.receivewin_width = allocation->width;
|
||||
prefs_common.receivewin_height = allocation->height;
|
||||
}
|
||||
|
||||
static IncProgressDialog *inc_progress_dialog_create(gboolean autocheck)
|
||||
{
|
||||
IncProgressDialog *dialog;
|
||||
ProgressDialog *progress;
|
||||
static GdkGeometry geometry;
|
||||
|
||||
dialog = g_new0(IncProgressDialog, 1);
|
||||
|
||||
|
@ -376,7 +386,9 @@ static IncProgressDialog *inc_progress_dialog_create(gboolean autocheck)
|
|||
G_CALLBACK(inc_cancel_cb), dialog);
|
||||
g_signal_connect(G_OBJECT(progress->window), "delete_event",
|
||||
G_CALLBACK(inc_dialog_delete_cb), dialog);
|
||||
/* manage_window_set_transient(GTK_WINDOW(progress->window)); */
|
||||
g_signal_connect(G_OBJECT(progress->window), "size_allocate",
|
||||
G_CALLBACK(inc_progress_dialog_size_allocate_cb), NULL);
|
||||
/* manage_window_set_transient(GTK_WINDOW(progress->window)); */
|
||||
|
||||
progress_dialog_get_fraction(progress);
|
||||
|
||||
|
@ -387,6 +399,16 @@ static IncProgressDialog *inc_progress_dialog_create(gboolean autocheck)
|
|||
stock_pixbuf_gdk(progress->treeview, STOCK_PIXMAP_ERROR,
|
||||
&errorpix);
|
||||
|
||||
if (!geometry.min_height) {
|
||||
geometry.min_width = 460;
|
||||
geometry.min_height = 250;
|
||||
}
|
||||
|
||||
gtk_window_set_geometry_hints(GTK_WINDOW(progress->window), NULL, &geometry,
|
||||
GDK_HINT_MIN_SIZE);
|
||||
gtk_widget_set_size_request(progress->window, prefs_common.receivewin_width,
|
||||
prefs_common.receivewin_height);
|
||||
|
||||
if (prefs_common.recv_dialog_mode == RECV_DIALOG_ALWAYS ||
|
||||
(prefs_common.recv_dialog_mode == RECV_DIALOG_MANUAL &&
|
||||
!autocheck)) {
|
||||
|
|
|
@ -164,6 +164,10 @@ static PrefParam param[] = {
|
|||
NULL, NULL, NULL},
|
||||
{"receive_dialog_mode", "1", &prefs_common.recv_dialog_mode, P_ENUM,
|
||||
NULL, NULL, NULL},
|
||||
{"receivewin_width", "460", &prefs_common.receivewin_width, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
{"receivewin_height", "-1", &prefs_common.receivewin_height, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
{"no_receive_error_panel", "FALSE", &prefs_common.no_recv_err_panel,
|
||||
P_BOOL, NULL, NULL, NULL},
|
||||
{"close_receive_dialog", "TRUE", &prefs_common.close_recv_dialog,
|
||||
|
@ -176,6 +180,10 @@ static PrefParam param[] = {
|
|||
P_BOOL, NULL, NULL, NULL},
|
||||
{"send_dialog_mode", "0", &prefs_common.send_dialog_mode, P_ENUM,
|
||||
NULL, NULL, NULL},
|
||||
{"sendwin_width", "460", &prefs_common.sendwin_width, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
{"sendwin_height", "-1", &prefs_common.sendwin_height, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
|
||||
{"outgoing_charset", CS_AUTO, &prefs_common.outgoing_charset, P_STRING,
|
||||
NULL, NULL, NULL},
|
||||
|
@ -706,6 +714,11 @@ static PrefParam param[] = {
|
|||
{"addressbookeditpersonwin_height", "-1", &prefs_common.addressbookeditpersonwin_height, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
|
||||
{"addressbookeditgroupwin_width", "580", &prefs_common.addressbookeditgroupwin_width, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
{"addressbookeditgroupwin_height", "340", &prefs_common.addressbookeditgroupwin_height, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
|
||||
{"pluginswin_width", "480", &prefs_common.pluginswin_width, P_INT,
|
||||
NULL, NULL, NULL},
|
||||
{"pluginswin_height", "-1", &prefs_common.pluginswin_height, P_INT,
|
||||
|
|
|
@ -94,6 +94,8 @@ struct _PrefsCommon
|
|||
gboolean newmail_notify_manu;
|
||||
gchar *newmail_notify_cmd;
|
||||
RecvDialogMode recv_dialog_mode;
|
||||
gint receivewin_width;
|
||||
gint receivewin_height;
|
||||
gboolean close_recv_dialog;
|
||||
gboolean no_recv_err_panel;
|
||||
|
||||
|
@ -101,6 +103,8 @@ struct _PrefsCommon
|
|||
gboolean savemsg;
|
||||
gboolean confirm_send_queued_messages;
|
||||
SendDialogMode send_dialog_mode;
|
||||
gint sendwin_width;
|
||||
gint sendwin_height;
|
||||
gchar *outgoing_charset;
|
||||
TransferEncodingMethod encoding_method;
|
||||
|
||||
|
@ -365,6 +369,8 @@ struct _PrefsCommon
|
|||
gint addressbookwin_height;
|
||||
gint addressbookeditpersonwin_width;
|
||||
gint addressbookeditpersonwin_height;
|
||||
gint addressbookeditgroupwin_width;
|
||||
gint addressbookeditgroupwin_height;
|
||||
gint pluginswin_width;
|
||||
gint pluginswin_height;
|
||||
gint prefswin_width;
|
||||
|
|
|
@ -533,10 +533,20 @@ static gint send_send_data_finished(Session *session, guint len, gpointer data)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void send_progress_dialog_size_allocate_cb(GtkWidget *widget,
|
||||
GtkAllocation *allocation)
|
||||
{
|
||||
g_return_if_fail(allocation != NULL);
|
||||
|
||||
prefs_common.sendwin_width = allocation->width;
|
||||
prefs_common.sendwin_height = allocation->height;
|
||||
}
|
||||
|
||||
static SendProgressDialog *send_progress_dialog_create(void)
|
||||
{
|
||||
SendProgressDialog *dialog;
|
||||
ProgressDialog *progress;
|
||||
static GdkGeometry geometry;
|
||||
|
||||
dialog = g_new0(SendProgressDialog, 1);
|
||||
|
||||
|
@ -548,10 +558,22 @@ static SendProgressDialog *send_progress_dialog_create(void)
|
|||
g_signal_connect(G_OBJECT(progress->window), "delete_event",
|
||||
G_CALLBACK(gtk_true), NULL);
|
||||
gtk_window_set_modal(GTK_WINDOW(progress->window), TRUE);
|
||||
g_signal_connect(G_OBJECT(progress->window), "size_allocate",
|
||||
G_CALLBACK(send_progress_dialog_size_allocate_cb), NULL);
|
||||
manage_window_set_transient(GTK_WINDOW(progress->window));
|
||||
|
||||
progress_dialog_get_fraction(progress);
|
||||
|
||||
if (!geometry.min_height) {
|
||||
geometry.min_width = 460;
|
||||
geometry.min_height = 250;
|
||||
}
|
||||
|
||||
gtk_window_set_geometry_hints(GTK_WINDOW(progress->window), NULL, &geometry,
|
||||
GDK_HINT_MIN_SIZE);
|
||||
gtk_widget_set_size_request(progress->window, prefs_common.sendwin_width,
|
||||
prefs_common.sendwin_height);
|
||||
|
||||
if (prefs_common.send_dialog_mode == SEND_DIALOG_ALWAYS) {
|
||||
gtk_widget_show_now(progress->window);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue