graphics/: Correct logic for copy of bit maps with resolution less than 8 bits from the per-window framebuffer to the device.

This commit is contained in:
Gregory Nutt
2019-03-18 09:44:38 -06:00
parent 22f9ec6abb
commit 10b73fde9d
9 changed files with 196 additions and 46 deletions
+3 -3
View File
@@ -109,7 +109,7 @@ NXTKWINDOW nxtk_openwindow(NXHANDLE handle, uint8_t flags,
int ret;
#ifdef CONFIG_DEBUG_FEATURES
if (handle == NULL || cb == NULL)
if (handle == NULL || cb == NULL || (flags & ~NXTK_WINDOW_USER) != 0)
{
set_errno(EINVAL);
return NULL;
@@ -134,8 +134,8 @@ NXTKWINDOW nxtk_openwindow(NXHANDLE handle, uint8_t flags,
/* Then let nx_constructwindow do the rest */
ret = nx_constructwindow(handle, (NXWINDOW)&fwnd->wnd, flags, &g_nxtkcb,
NULL);
ret = nx_constructwindow(handle, (NXWINDOW)&fwnd->wnd,
flags | NXBE_WINDOW_FRAMED, &g_nxtkcb, NULL);
if (ret < 0)
{
/* An error occurred, the window has been freed */
-3
View File
@@ -99,9 +99,6 @@ int nxtk_setsize(NXTKWINDOW hfwnd, FAR const struct nxgl_size_s *size)
* callbacks. Normally the frame is updated with every redraw callback.
* However, as a minimum, the frame only has to but updated after the
* window or toolbar sizes change.
*
* REVISIT: Since this works for RAM backed windows, it should work for
* all windows. Why not simplify?
*/
if (ret >= 0 && NXBE_ISRAMBACKED(&fwnd->wnd))