home *** CD-ROM | disk | FTP | other *** search
- #include "DeskLib:WimpSWIs.h"
-
- #include "Update.h"
-
-
- void ForceRegionUpdate( app_block *app, int pos, int size)
- {
- window_redrawblock redrawblock;
- Shell_convertpoint convert;
- wimp_rect workrect;
- BOOL more;
- wimp_point rectsize;
-
- rectsize.x = app->heaprect->rect.max.x - app->heaprect->rect.min.x;
- rectsize.y = app->heaprect->rect.max.y - app->heaprect->rect.min.y;
-
- redrawblock.window = app->heaprect->window;
-
- redrawblock.rect.min.x = app->heaprect->rect.min.x;
- redrawblock.rect.max.x = app->heaprect->rect.max.x;
- redrawblock.rect.min.y = ( pos - app->min_mem) / app->words_per_os - 4;
- redrawblock.rect.max.y = ( (pos+size) - app->min_mem) / app->words_per_os + 4;
-
- Wimp_UpdateWindow( &redrawblock, &more);
-
- convert.x = redrawblock.rect.min.x - redrawblock.scroll.x + app->heaprect->rect.min.x;
- convert.y = redrawblock.rect.max.y - redrawblock.scroll.y + app->heaprect->rect.min.y;
-
- for (
- ;
- more;
- Wimp_GetRectangle( &redrawblock, &more)
- )
-
- {
- workrect.max.x = redrawblock.cliprect.max.x - convert.x;
- workrect.min.x = redrawblock.cliprect.min.x - convert.x;
- workrect.max.y = redrawblock.cliprect.max.y - convert.y;
- workrect.min.y = redrawblock.cliprect.min.y - convert.y;
-
- ( *(app->heaprect->redrawer) ) ( convert, rectsize, app->heaprect->reference, &workrect);
- /* Call the redrawing function for the rectangle */
-
- }
- }
-
-