[Kazehakase-cvs] kazehakase-svn [2997] * module/embed/khtml/kz-khtml.c: Handle req-auth-prompt.

Back to archive index

svnno****@sourc***** svnno****@sourc*****
Sun Mar 25 10:42:32 JST 2007


Revision: 2997
          http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=kazehakase&view=rev&rev=2997
Author:   ikezoe
Date:     2007-03-25 10:42:32 +0900 (Sun, 25 Mar 2007)

Log Message:
-----------
* module/embed/khtml/kz-khtml.c: Handle req-auth-prompt.

Modified Paths:
--------------
    kazehakase/trunk/ChangeLog
    kazehakase/trunk/module/embed/khtml/kz-khtml.c

Modified: kazehakase/trunk/ChangeLog
===================================================================
--- kazehakase/trunk/ChangeLog	2007-03-25 01:24:23 UTC (rev 2996)
+++ kazehakase/trunk/ChangeLog	2007-03-25 01:42:32 UTC (rev 2997)
@@ -3,6 +3,7 @@
 	* module/embed/khtml/kz-khtml.c: Handle req-new-window and
 	close-window signals.
 	* module/embed/khtml/kz-khtml.c: Fix an argument of req-new-window.
+	* module/embed/khtml/kz-khtml.c: Handle req-auth-prompt.
 
 2007-03-24  Kouhei Sutou  <kou****@cozmi*****>
 

Modified: kazehakase/trunk/module/embed/khtml/kz-khtml.c
===================================================================
--- kazehakase/trunk/module/embed/khtml/kz-khtml.c	2007-03-25 01:24:23 UTC (rev 2996)
+++ kazehakase/trunk/module/embed/khtml/kz-khtml.c	2007-03-25 01:42:32 UTC (rev 2997)
@@ -27,6 +27,7 @@
 #include "kz-khtml.h"
 #include "kz-embed-prefs.h"
 #include "kz-embed.h"
+#include "kz-prompt-dialog.h"
 #include "gobject-utils.h"
 
 typedef struct _KzKHTMLPrivate	KzKHTMLPrivate;
@@ -518,7 +519,20 @@
 static void
 kz_khtml_req_auth_prompt (Webi *khtml, WebiAuthArgs* args)
 {
+	KzPromptDialog *prompt;
+
 	g_return_if_fail(KZ_IS_KHTML(khtml));
+
+	prompt= KZ_PROMPT_DIALOG(kz_prompt_dialog_new(TYPE_PROMPT_USER_PASS));
+
+	kz_prompt_dialog_set_title(prompt, _("Authentication"));
+	kz_prompt_dialog_run(prompt);
+
+	args->out_ok_pressed = kz_prompt_dialog_get_confirm_value(prompt);
+	args->out_username = g_strdup(kz_prompt_dialog_get_user(prompt));
+	args->out_password = g_strdup(kz_prompt_dialog_get_password(prompt));
+
+	gtk_widget_destroy(GTK_WIDGET(prompt));
 }
 
 




More information about the Kazehakase-cvs mailing list
Back to archive index