summaryrefslogtreecommitdiff
path: root/riscos/dialog.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2006-02-23 15:06:54 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2006-02-23 15:06:54 +0000
commitd4d3e5ee1c9edb67844b693be0202ee5968d61c3 (patch)
treef8583d475d39172ff3b19473812ff6ce72de8452 /riscos/dialog.c
parent70fbf97688666f6ab37c4cc427f1e8c9929cc4b1 (diff)
downloadnetsurf-d4d3e5ee1c9edb67844b693be0202ee5968d61c3.tar.gz
netsurf-d4d3e5ee1c9edb67844b693be0202ee5968d61c3.tar.bz2
[project @ 2006-02-23 15:06:53 by jmb]
Handle invalid SSL certificates better - UI still needs work. Modify fetch callback data parameter type to remove compiler warnings. Constify things. Lose global ssl_verify_certificates option. Fix issue when closing a dialog without input focus. svn path=/import/netsurf/; revision=2092
Diffstat (limited to 'riscos/dialog.c')
-rw-r--r--riscos/dialog.c44
1 files changed, 26 insertions, 18 deletions
diff --git a/riscos/dialog.c b/riscos/dialog.c
index e41dfb9b5..3a5225e8b 100644
--- a/riscos/dialog.c
+++ b/riscos/dialog.c
@@ -91,6 +91,11 @@ void ro_gui_dialog_init(void)
ro_gui_401login_init();
#endif
+ /* certificate verification window */
+#ifdef WITH_SSL
+ ro_gui_cert_init();
+#endif
+
/* hotlist window */
ro_gui_hotlist_initialise();
@@ -353,6 +358,15 @@ void ro_gui_dialog_close(wimp_w close)
wimp_caret caret;
os_error *error;
+ /* Check if we're a persistent window */
+ for (i = 0; i < MAX_PERSISTENT; i++) {
+ if (persistent_dialog[i].dialog == close) {
+ /* We are => invalidate record */
+ persistent_dialog[i].dialog = NULL;
+ break;
+ }
+ }
+
/* Give the caret back to the parent window. This code relies on
the fact that only tree windows and browser windows open
persistent dialogues, as the caret gets placed to no icon.
@@ -363,24 +377,18 @@ void ro_gui_dialog_close(wimp_w close)
error->errnum, error->errmess));
warn_user("WimpError", error->errmess);
} else if (caret.w == close) {
- /* Check if we are a persistent window
- */
- for (i = 0; i < MAX_PERSISTENT; i++) {
- if (persistent_dialog[i].dialog == close) {
- persistent_dialog[i].dialog = NULL;
- error = xwimp_set_caret_position(
- persistent_dialog[i].parent,
- wimp_ICON_WINDOW, -100, -100,
- 32, -1);
- /* parent may have been closed first */
- if ((error) && (error->errnum != 0x287)) {
- LOG(("xwimp_set_caret_position: "
- "0x%x: %s",
- error->errnum,
- error->errmess));
- warn_user("WimpError", error->errmess);
- }
- break;
+ /* Check if we are a persistent window */
+ if (i < MAX_PERSISTENT) {
+ error = xwimp_set_caret_position(
+ persistent_dialog[i].parent,
+ wimp_ICON_WINDOW, -100, -100,
+ 32, -1);
+ /* parent may have been closed first */
+ if ((error) && (error->errnum != 0x287)) {
+ LOG(("xwimp_set_caret_position: 0x%x: %s",
+ error->errnum,
+ error->errmess));
+ warn_user("WimpError", error->errmess);
}
}
}