summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Lebl <jirka@5z.com>2002-07-11 17:27:28 +0000
committerGeorge Lebl <jirka@src.gnome.org>2002-07-11 17:27:28 +0000
commitaf710c073bbac40a45d9e702c87199cee9bbf5d0 (patch)
treef78135fe690dc3d58d54d751a45fbbba6228a8b8
parentce49de37240211dca3769d2a652d600de108dce1 (diff)
downloadgdm-af710c073bbac40a45d9e702c87199cee9bbf5d0.tar.gz
some indenting foo
Thu Jul 11 10:39:18 2002 George Lebl <jirka@5z.com> * daemon/gdm-net.c, daemon/xdmcp.c: some indenting foo * gui/gdmlogin.c, gui/gdmchooser.c, gui/greeter/greeter.c: Set the IO channels to be unbuffered just like in the daemon and set their encoding to NULL. We want to be as raw as possible * gui/gdmlogin.c, gui/greeter/greeter_item_pam.c: initially leave the prompt entry insensitive. Also initially set the entry to "..." in the greeter since otherwise it will be a little unresponsive to the first keystroke. Fixes #83187
-rw-r--r--ChangeLog13
-rw-r--r--daemon/gdm-net.c8
-rw-r--r--daemon/xdmcp.c2
-rw-r--r--gui/gdmchooser.c2
-rw-r--r--gui/gdmlogin.c8
-rw-r--r--gui/greeter/greeter.c2
-rw-r--r--gui/greeter/greeter_item_pam.c9
7 files changed, 39 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index d6c5d314..9c5eb65c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+Thu Jul 11 10:39:18 2002 George Lebl <jirka@5z.com>
+
+ * daemon/gdm-net.c, daemon/xdmcp.c: some indenting foo
+
+ * gui/gdmlogin.c, gui/gdmchooser.c, gui/greeter/greeter.c: Set
+ the IO channels to be unbuffered just like in the daemon and
+ set their encoding to NULL. We want to be as raw as possible
+
+ * gui/gdmlogin.c, gui/greeter/greeter_item_pam.c: initially leave
+ the prompt entry insensitive. Also initially set the entry to
+ "..." in the greeter since otherwise it will be a little
+ unresponsive to the first keystroke. Fixes #83187
+
Thu Jul 11 09:41:55 2002 George Lebl <jirka@5z.com>
* daemon/gdm-net.c, daemon/xdmcp.c: Apply patch from
diff --git a/daemon/gdm-net.c b/daemon/gdm-net.c
index 722940c9..0297b9e8 100644
--- a/daemon/gdm-net.c
+++ b/daemon/gdm-net.c
@@ -221,7 +221,7 @@ gdm_socket_handler (GIOChannel *source,
}
unixchan = g_io_channel_unix_new (newconn->fd);
- g_io_channel_set_encoding(unixchan, NULL, NULL);
+ g_io_channel_set_encoding (unixchan, NULL, NULL);
g_io_channel_set_buffered (unixchan, FALSE);
newconn->source = g_io_add_watch_full
@@ -275,7 +275,7 @@ gdm_connection_open_unix (const char *sockname, mode_t mode)
conn->n_subconnections = 0;
unixchan = g_io_channel_unix_new (conn->fd);
- g_io_channel_set_encoding(unixchan, NULL, NULL);
+ g_io_channel_set_encoding (unixchan, NULL, NULL);
g_io_channel_set_buffered (unixchan, FALSE);
conn->source = g_io_add_watch_full
@@ -309,7 +309,7 @@ gdm_connection_open_fd (int fd)
conn->n_subconnections = 0;
unixchan = g_io_channel_unix_new (conn->fd);
- g_io_channel_set_encoding (unixchan, NULL, NULL);
+ g_io_channel_set_encoding (unixchan, NULL, NULL);
g_io_channel_set_buffered (unixchan, FALSE);
conn->source = g_io_add_watch_full
@@ -360,7 +360,7 @@ gdm_connection_open_fifo (const char *fifo, mode_t mode)
conn->n_subconnections = 0;
fifochan = g_io_channel_unix_new (conn->fd);
- g_io_channel_set_encoding (fifochan, NULL, NULL);
+ g_io_channel_set_encoding (fifochan, NULL, NULL);
g_io_channel_set_buffered (fifochan, FALSE);
conn->source = g_io_add_watch_full
diff --git a/daemon/xdmcp.c b/daemon/xdmcp.c
index dea249fc..f43df8b4 100644
--- a/daemon/xdmcp.c
+++ b/daemon/xdmcp.c
@@ -286,7 +286,7 @@ gdm_xdmcp_run (void)
GIOChannel *xdmcpchan;
xdmcpchan = g_io_channel_unix_new (gdm_xdmcpfd);
- g_io_channel_set_encoding (xdmcpchan, NULL, NULL);
+ g_io_channel_set_encoding (xdmcpchan, NULL, NULL);
g_io_channel_set_buffered (xdmcpchan, FALSE);
xdmcp_source = g_io_add_watch_full
diff --git a/gui/gdmchooser.c b/gui/gdmchooser.c
index bf0291c7..d993d1ab 100644
--- a/gui/gdmchooser.c
+++ b/gui/gdmchooser.c
@@ -648,6 +648,8 @@ gdm_chooser_xdmcp_init (char **hosts)
gdm_chooser_add_hosts (hosts);
channel = g_io_channel_unix_new (sockfd);
+ g_io_channel_set_encoding (channel, NULL, NULL);
+ g_io_channel_set_buffered (channel, FALSE);
g_io_add_watch_full (channel, G_PRIORITY_DEFAULT,
G_IO_IN|G_IO_PRI|G_IO_ERR|G_IO_HUP|G_IO_NVAL,
gdm_chooser_decode_packet,
diff --git a/gui/gdmlogin.c b/gui/gdmlogin.c
index 400058db..43d56d27 100644
--- a/gui/gdmlogin.c
+++ b/gui/gdmlogin.c
@@ -3335,6 +3335,12 @@ gdm_login_gui_init (void)
G_CALLBACK (gdm_login_focus_out),
NULL);
+ /* normally disable the prompt first */
+ if ( ! DOING_GDM_DEVELOPMENT) {
+ gtk_widget_set_sensitive (entry, FALSE);
+ gtk_widget_set_sensitive (ok_button, FALSE);
+ }
+
gtk_widget_show_all (GTK_WIDGET (login));
}
@@ -4068,6 +4074,8 @@ main (int argc, char *argv[])
if ( ! DOING_GDM_DEVELOPMENT) {
ctrlch = g_io_channel_unix_new (STDIN_FILENO);
+ g_io_channel_set_encoding (ctrlch, NULL, NULL);
+ g_io_channel_set_buffered (ctrlch, FALSE);
g_io_channel_init (ctrlch);
g_io_add_watch (ctrlch,
G_IO_IN | G_IO_PRI | G_IO_ERR | G_IO_HUP | G_IO_NVAL,
diff --git a/gui/greeter/greeter.c b/gui/greeter/greeter.c
index 88a8d6ac..38613ec4 100644
--- a/gui/greeter/greeter.c
+++ b/gui/greeter/greeter.c
@@ -900,6 +900,8 @@ main (int argc, char *argv[])
if (! DOING_GDM_DEVELOPMENT) {
ctrlch = g_io_channel_unix_new (STDIN_FILENO);
+ g_io_channel_set_encoding (ctrlch, NULL, NULL);
+ g_io_channel_set_buffered (ctrlch, FALSE);
g_io_channel_init (ctrlch);
g_io_add_watch (ctrlch,
G_IO_IN | G_IO_PRI | G_IO_ERR | G_IO_HUP | G_IO_NVAL,
diff --git a/gui/greeter/greeter_item_pam.c b/gui/greeter/greeter_item_pam.c
index 2a7ae007..d5f89677 100644
--- a/gui/greeter/greeter_item_pam.c
+++ b/gui/greeter/greeter_item_pam.c
@@ -83,6 +83,15 @@ greeter_item_pam_setup (void)
entry = GNOME_CANVAS_WIDGET (entry_info->item)->widget;
gtk_widget_grab_focus (entry);
+ /* hack. For some reason if we leave it blank,
+ * we'll get a little bit of activity on first keystroke,
+ * this way we get rid of it, it will be cleared for the
+ * first prompt anyway. */
+ gtk_entry_set_text (GTK_ENTRY (entry), "...");
+
+ /* initially insensitive */
+ gtk_widget_set_sensitive (entry, FALSE);
+
g_signal_connect (entry, "activate",
GTK_SIGNAL_FUNC (user_pw_activate), entry_info);
}