diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-01-12 23:22:15 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-01-12 23:22:15 +0000 |
commit | 6ee254699bf787d78835419be2b3241fb037d444 (patch) | |
tree | 07fe67dab517e4990f344fe2c00e65cef4d25b81 /lib/libcurses/base/lib_mvwin.c | |
parent | 0b62f5dc36fc7203a74cdc812c4234ae188fdfd2 (diff) |
Update to ncurses 5.7, with local changes reapplied.
This is around eight years worth of changes (previously we were around ncurses
5.2), too many to list - many bug fixes and also a few new functions.
A major bump for libcurses, libpanel, libform and libmenu.
ok deraadt
Diffstat (limited to 'lib/libcurses/base/lib_mvwin.c')
-rw-r--r-- | lib/libcurses/base/lib_mvwin.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/lib/libcurses/base/lib_mvwin.c b/lib/libcurses/base/lib_mvwin.c index dbd28576f1b..3a6e9d54fb3 100644 --- a/lib/libcurses/base/lib_mvwin.c +++ b/lib/libcurses/base/lib_mvwin.c @@ -1,7 +1,7 @@ -/* $OpenBSD: lib_mvwin.c,v 1.2 2001/01/22 18:01:41 millert Exp $ */ +/* $OpenBSD: lib_mvwin.c,v 1.3 2010/01/12 23:22:06 nicm Exp $ */ /**************************************************************************** - * Copyright (c) 1998,2000 Free Software Foundation, Inc. * + * Copyright (c) 1998-2001,2006 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -42,7 +42,7 @@ #include <curses.priv.h> -MODULE_ID("$From: lib_mvwin.c,v 1.9 2000/12/10 02:43:27 tom Exp $") +MODULE_ID("$Id: lib_mvwin.c,v 1.3 2010/01/12 23:22:06 nicm Exp $") NCURSES_EXPORT(int) mvwin(WINDOW *win, int by, int bx) @@ -52,6 +52,11 @@ mvwin(WINDOW *win, int by, int bx) if (!win || (win->_flags & _ISPAD)) returnCode(ERR); + /* + * mvwin() should only modify the indices. See test/demo_menus.c and + * test/movewindow.c for examples. + */ +#if 0 /* Copying subwindows is allowed, but it is expensive... */ if (win->_flags & _SUBWIN) { int err = ERR; @@ -71,7 +76,8 @@ mvwin(WINDOW *win, int by, int bx) /* now we have the clone, so relocate win */ werase(win); /* Erase the original place */ - wbkgd(win, parent->_bkgd); /* fill with parents background */ + /* fill with parents background */ + wbkgrnd(win, CHREF(parent->_nc_bkgd)); wsyncup(win); /* Tell the parent(s) */ err = mvderwin(win, @@ -90,6 +96,7 @@ mvwin(WINDOW *win, int by, int bx) } returnCode(err); } +#endif if (by + win->_maxy > screen_lines - 1 || bx + win->_maxx > screen_columns - 1 |