diff options
author | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2014-11-10 23:25:43 +0000 |
---|---|---|
committer | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2014-11-10 23:25:43 +0000 |
commit | 5776b39b8d6cb45e38c6c7a05ef03fccccc176dc (patch) | |
tree | a0d0360a6a4111d993c3e8fd43876c1318904df4 /amiga/misc.c | |
parent | ad414165f9a3bb872d61dd0ad4bf7ede88ba0fb7 (diff) | |
download | netsurf-5776b39b8d6cb45e38c6c7a05ef03fccccc176dc.tar.gz netsurf-5776b39b8d6cb45e38c6c7a05ef03fccccc176dc.tar.bz2 |
Use TimedDosRequester so we're not relying on requester.class being open.
Diffstat (limited to 'amiga/misc.c')
-rwxr-xr-x | amiga/misc.c | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/amiga/misc.c b/amiga/misc.c index 530110f49..cda75d684 100755 --- a/amiga/misc.c +++ b/amiga/misc.c @@ -47,35 +47,27 @@ #include "amiga/misc.h" #include "amiga/utf8.h" -static LONG ami_misc_req(const char *message, int type) +static LONG ami_misc_req(const char *message, uint32 type) { - Object *req = NULL; LONG ret = 0; LOG(("%s", message)); - req = NewObject(REQUESTER_GetClass(), NULL, - REQ_Type, REQTYPE_INFO, - REQ_TitleText, messages_get("NetSurf"), - REQ_BodyText, message, - REQ_GadgetText, messages_get("OK"), + ret = TimedDosRequesterTags( + TDR_TitleString, messages_get("NetSurf"), + TDR_FormatString, message, + TDR_GadgetString, messages_get("OK"), #ifdef __amigaos4__ - REQ_Image, (struct Image *)type, - /* REQ_CharSet, 106, */ + TDR_ImageType, type, #endif TAG_DONE); - if (req) { - ret = IDoMethod(req, RM_OPENREQ, NULL, NULL, scrn); - DisposeObject(req); - } - return ret; } void ami_misc_fatal_error(const char *message) { - ami_misc_req(message, REQIMAGE_ERROR); + ami_misc_req(message, TDRIMAGE_ERROR); } void warn_user(const char *warning, const char *detail) @@ -84,7 +76,7 @@ void warn_user(const char *warning, const char *detail) STRPTR bodytext = ASPrintf("\33b%s\33n\n%s", utf8warning != NULL ? utf8warning : warning, detail); - ami_misc_req(bodytext, REQIMAGE_WARNING); + ami_misc_req(bodytext, TDRIMAGE_WARNING); if(bodytext) FreeVec(bodytext); if(utf8warning) free(utf8warning); |