cleanup and fix conditional compilation errors

This commit is contained in:
Vincent Wei
2020-02-11 21:01:48 +08:00
parent 62d9c39ac6
commit 53033675ad
2 changed files with 14 additions and 14 deletions

View File

@@ -5893,7 +5893,7 @@ typedef struct _MAINWINCREATE {
/**
* The background color of the main window.
* Note that under compositing schema, if you specify the main windows's
* surface type other than default, you must use this field
* surface type other than the default, you must use this field
* to specify the background color of the main window instead of
* the pixel value (\a iBkColor).
*
@@ -5901,7 +5901,7 @@ typedef struct _MAINWINCREATE {
* You should use a value returned by \a MakeRGBA macro for this field.
* Note that if you use the surface type \a ST_PIXEL_DEFAULT when creating
* the main window, you can still use the pixel values which compliant
* to \a HDC_SCREEN, e.g., a values in \a SysPixelIndex array.
* to \a HDC_SCREEN, e.g., values in \a SysPixelIndex array.
*/
DWORD dwBkColor;
#endif
@@ -8452,7 +8452,7 @@ typedef struct _WNDCLASS {
*
* \code
* #ifdef _MGSCHEMA_COMPOSITING
* MyClass.dwBkColor = COLOR_lightwhite;
* MyClass.dwBkColor = RGBA_lightwhite;
* #else
* MyClass.iBkColor = PIXEL_lightwhite;
* #endif

View File

@@ -801,6 +801,16 @@ static void mark_surface_dirty (GAL_Surface* surface,
}
#endif /* defined _MGSCHEMA_COMPOSITING */
#ifdef _MGSCHEMA_COMPOSITING
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/sem.h>
#include "sharedres.h"
#include "ourhdr.h"
#include "drawsemop.h"
#endif
#ifdef _MGUSE_SYNC_UPDATE
static inline void add_rects_to_update_region (CLIPRGN* region,
@@ -885,16 +895,6 @@ int __mg_convert_region_to_rects (const CLIPRGN * rgn,
return nr;
}
#ifdef _MGSCHEMA_COMPOSITING
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/sem.h>
#include "sharedres.h"
#include "ourhdr.h"
#include "drawsemop.h"
#endif
BOOL GAL_SyncUpdate (GAL_Surface *surface)
{
GAL_VideoDevice *this = (GAL_VideoDevice *)surface->video;
@@ -949,7 +949,7 @@ void GAL_UpdateRects (GAL_Surface *surface, int numrects, GAL_Rect *rects)
#endif
if (this) {
if (this->info.mlt_surfaces == 0 && this->UpdateRects)
if (this->info.mlt_surfaces == 0 && this->UpdateRects) {
this->UpdateRects (this, numrects, rects);
}
else if (this->UpdateSurfaceRects) {