summaryrefslogtreecommitdiff
path: root/nuttx
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2008-12-01 16:34:05 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2008-12-01 16:34:05 +0000
commitb679403a0a2d7f564f5ccc41436753c4293a337d (patch)
treee720bbf118348cbd8d187bd01563e4dbd8e44aeb /nuttx
parent8b2dc49a9d4b3fb69c3db170f6b6a87f0f4505f3 (diff)
downloadpx4-nuttx-b679403a0a2d7f564f5ccc41436753c4293a337d.tar.gz
px4-nuttx-b679403a0a2d7f564f5ccc41436753c4293a337d.tar.bz2
px4-nuttx-b679403a0a2d7f564f5ccc41436753c4293a337d.zip
Fix raise logic -- what was I thinking?
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1375 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx')
-rw-r--r--nuttx/graphics/nxbe/nxbe_raise.c44
1 files changed, 8 insertions, 36 deletions
diff --git a/nuttx/graphics/nxbe/nxbe_raise.c b/nuttx/graphics/nxbe/nxbe_raise.c
index 109fdaf1d..b9282ba8f 100644
--- a/nuttx/graphics/nxbe/nxbe_raise.c
+++ b/nuttx/graphics/nxbe/nxbe_raise.c
@@ -72,18 +72,6 @@ struct nxbe_raise_s
****************************************************************************/
/****************************************************************************
- * Name: nxbe_clipraise
- ****************************************************************************/
-
-static void nxbe_clipraise(FAR struct nxbe_clipops_s *cops,
- FAR struct nxbe_plane_s *plane,
- FAR const struct nxgl_rect_s *rect)
-{
- FAR struct nxbe_window_s *wnd = ((struct nxbe_raise_s *)cops)->wnd;
- nxfe_redrawreq(wnd, rect);
-}
-
-/****************************************************************************
* Public Functions
****************************************************************************/
@@ -98,36 +86,14 @@ static void nxbe_clipraise(FAR struct nxbe_clipops_s *cops,
void nxbe_raise(FAR struct nxbe_window_s *wnd)
{
FAR struct nxbe_state_s *be = wnd->be;
- struct nxgl_rect_s rect;
- struct nxbe_raise_s info;
+
+ /* If this window is already at the top of the display, then do nothing */
if (!wnd->above)
{
return;
}
- /* Redraw the bits that are currently obscured */
-
- nxgl_rectintersect(&rect, &wnd->bounds, &be->bkgd.bounds);
- if (!nxgl_nullrect(&rect))
- {
- int i;
-
- info.cops.visible = nxbe_clipnull;
- info.cops.obscured = nxbe_clipraise;
- info.wnd = wnd;
-
-#if CONFIG_NX_NPLANES > 1
- for (i = 0; i < be->vinfo.nplanes; i++)
-#else
- i = 0;
-#endif
- {
- nxbe_clipper(wnd->above, &rect, NX_CLIPORDER_DEFAULT,
- &info.cops, &be->plane[i]);
- }
- }
-
/* Remove window from the list. Note that there is always
* some below this window (it may only be the background window)
*/
@@ -142,4 +108,10 @@ void nxbe_raise(FAR struct nxbe_window_s *wnd)
be->topwnd->above = wnd;
be->topwnd = wnd;
+
+ /* This window is now at the top of the display, we know, therefore, that
+ * it is not obscured by another window
+ */
+
+ nxfe_redrawreq(wnd, &wnd->bounds);
}