コード例 #1
0
ファイル: hidden.c プロジェクト: sabotage-linux/netbsd-curses
int
panel_hidden(PANEL *p)
{

    if (p == NULL)
        return ERR;

    if (PANEL_HIDDEN(p))
        return TRUE;
    else
        return FALSE;
}
コード例 #2
0
ファイル: show.c プロジェクト: sabotage-linux/netbsd-curses
int
show_panel(PANEL *p)
{

	if (__predict_false(p == NULL))
		return ERR;

	/* unlike top_panel() */
	if (__predict_false(!PANEL_HIDDEN(p)))
		return ERR;

	DECK_INSERT_TOP(p);
	return OK;
}
コード例 #3
0
ファイル: bottom.c プロジェクト: ajinkya93/netbsd-src
int
bottom_panel(PANEL *p)
{

	if (__predict_false(p == NULL))
		return ERR;

	if (__predict_false(PANEL_HIDDEN(p)))
		return ERR;

	(void) hide_panel(p);

	DECK_INSERT_BOTTOM(p);
	return OK;
}
コード例 #4
0
ファイル: move.c プロジェクト: sabotage-linux/netbsd-curses
int
move_panel(PANEL *p, int y, int x)
{
	int oldy, oldx;

	if (__predict_false(p == NULL))
		return ERR;

	getbegyx(p->win, oldy, oldx);
	if (__predict_false(y == oldy && x == oldx))
		return OK;

	if (!PANEL_HIDDEN(p)) {
		PANEL *other;

		/* touch exposed areas at the old location now */
		FOREACH_PANEL (other) {
			if (other != p) {
				touchoverlap(p->win, other->win);
			}
		}
	}