Prevent ASL from causing delayed menus

This commit is contained in:
Chris Young 2013-05-25 13:59:42 +01:00
parent 9751a10705
commit b66775dc53
5 changed files with 15 additions and 1 deletions

View File

@ -728,6 +728,8 @@ static uint32 ami_context_menu_hook(struct Hook *hook,Object *item,APTR reserved
{
case CMID_SELECTFILE:
if(AslRequestTags(filereq,
ASLFR_Window, gwin->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText,messages_get("NetSurf"),
ASLFR_Screen,scrn,
ASLFR_DoSaveMode,FALSE,

View File

@ -105,6 +105,8 @@ struct gui_download_window *gui_download_window_create(download_context *ctx,
else
{
if(AslRequestTags(savereq,
ASLFR_Window, gui->shared->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText,messages_get("NetSurf"),
ASLFR_Screen,scrn,
ASLFR_InitialFile, download_context_get_filename(ctx),
@ -351,6 +353,8 @@ gui_window_save_link(struct gui_window *g, const char *url, const char *title)
linkname = ASPrintf("Link_to_%s",FilePart(url));
if(AslRequestTags(savereq,
ASLFR_Window, g->shared->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText,messages_get("NetSurf"),
ASLFR_Screen,scrn,
ASLFR_InitialFile,linkname,

View File

@ -83,6 +83,8 @@ void ami_file_open(struct gui_window_2 *gwin)
if(AslRequestTags(filereq,
ASLFR_TitleText, messages_get("NetSurf"),
ASLFR_Window, gwin->win,
ASLFR_SleepWindow, TRUE,
ASLFR_Screen, scrn,
ASLFR_DoSaveMode, FALSE,
ASLFR_RejectIcons, TRUE,
@ -213,7 +215,7 @@ void ami_file_save(int type, char *fname, struct Window *win,
FWrite(fh, source_data, 1, strlen(source_data));
FClose(fh);
}
free(source_data);
free((void *)source_data);
}
break;
}
@ -229,6 +231,8 @@ void ami_file_save_req(int type, struct gui_window_2 *gwin,
char *fname = AllocVec(1024, MEMF_CLEAR | MEMF_PRIVATE);
if(AslRequestTags(savereq,
ASLFR_Window, gwin->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText, messages_get("NetSurf"),
ASLFR_Screen, scrn,
ASLFR_InitialFile, object ? FilePart(nsurl_access(hlcache_handle_get_url(object))) : "",

View File

@ -963,6 +963,8 @@ static void ami_menu_item_arexx_execute(struct Hook *hook, APTR window, struct I
GetAttr(WINDOW_UserData, (Object *)window, (ULONG *)&gwin);
if(AslRequestTags(filereq,
ASLFR_Window, gwin->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText, messages_get("NetSurf"),
ASLFR_Screen, scrn,
ASLFR_DoSaveMode, FALSE,

View File

@ -1000,6 +1000,8 @@ BOOL ami_tree_event(struct treeview_window *twin)
{
case 0: // export
if(AslRequestTags(savereq,
ASLFR_Window, twin->win,
ASLFR_SleepWindow, TRUE,
ASLFR_TitleText,messages_get("NetSurf"),
ASLFR_Screen,scrn,
ASLFR_InitialFile,"tree_export.html",