X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a5001e9361fe01a134b45fa5caf55477e8368d26..12bb29f5432174ecbd65549bda832d70d34a98ae:/src/dfb/wrapdfb.cpp diff --git a/src/dfb/wrapdfb.cpp b/src/dfb/wrapdfb.cpp index e05ad09541..6159b7df16 100644 --- a/src/dfb/wrapdfb.cpp +++ b/src/dfb/wrapdfb.cpp @@ -36,7 +36,7 @@ bool wxDfbCheckReturn(DFBResult code) // these are programming errors, assert: #define DFB_ASSERT(code) \ case code: \ - wxFAIL_MSG( "DirectFB error: " _T(#code) ); \ + wxFAIL_MSG( "DirectFB error: " wxT(#code) ); \ return false \ DFB_ASSERT(DFB_DEAD); @@ -61,7 +61,7 @@ bool wxDfbCheckReturn(DFBResult code) default: // FIXME: should handle the errors individually - wxLogError(_("DirectFB error %d occured."), (int)code); + wxLogError(_("DirectFB error %d occurred."), (int)code); return false; } } @@ -105,7 +105,13 @@ wxIDirectFBSurfacePtr wxIDirectFB::GetPrimarySurface() { DFBSurfaceDescription desc; desc.flags = DSDESC_CAPS; - desc.caps = DSCAPS_PRIMARY; + // NB: see dcscreen.cpp for why we request double-buffered surface + // + // This assumes the cooperative level is DFSCL_NORMAL (that's the + // default and wx doesn't modify it anywhere); if we ever support + // other cooperative levels, DSCAPS_DOUBLE should *not* be used with + // them. + desc.caps = DFBSurfaceCapabilities(DSCAPS_PRIMARY | DSCAPS_DOUBLE); return CreateSurface(&desc); }