当前位置: 首页>>代码示例>>C++>>正文


C++ del_panel函数代码示例

本文整理汇总了C++中del_panel函数的典型用法代码示例。如果您正苦于以下问题:C++ del_panel函数的具体用法?C++ del_panel怎么用?C++ del_panel使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了del_panel函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: rmpanel

void rmpanel(PANEL *pan)
{
    WINDOW *win = pan->win;

    del_panel(pan);
    delwin(win);
}
开发者ID:ryoon,项目名称:eCos,代码行数:7,代码来源:ptest.c

示例2: curses_form_free

/*
 * Deallocate the memory used for the given curses form and all of the
 * widgets it contains.  Note that this only frees any data at the form's
 * userdata pointer IFF cleanup is non-zero.  Also, it does not cause the
 * screen to be refreshed - call curses_form_refresh(NULL) afterwards to
 * make the form disappear.
 */
void
curses_form_free(struct curses_form *cf)
{
	struct curses_widget *w, *t;

	w = cf->widget_head;
	while (w != NULL) {
		t = w->next;
		curses_widget_free(w);
		w = t;
	}

	if (cf->help_text != NULL) {
		free(cf->help_text);
	}

	if (cf->cleanup && cf->userdata != NULL) {
		free(cf->userdata);
	}

	if (cf->win != NULL) {
		del_panel(cf->pan);
		delwin(cf->win);
	}

	free(cf->title);
	AURA_FREE(cf, curses_form);
}
开发者ID:AhmadTux,项目名称:DragonFlyBSD,代码行数:35,代码来源:curses_form.c

示例3: tx_errbox

void tx_errbox(char *message, char *prompt, int *response)
{
    WINDOW *win;
    PANEL *panel;

    win = newwin(4, 70, (LINES - 4) / 2, (COLS - 70) / 2);
    panel = new_panel(win);

    wattrset(win, ERR_BORDER_ATTR);
    tx_colorwin(win);
    tx_box(win, ACS_VLINE, ACS_HLINE);
    wmove(win, 2, 2);
    wattrset(win, ERR_PROMPT_ATTR);
    wprintw(win, "%s", prompt);
    wattrset(win, ERR_TEXT_ATTR);
    wmove(win, 1, 2);
    wprintw(win, "%s", message);
    update_panels();
    doupdate();

    do {
        *response = wgetch(win);
        if (*response == 12)
            tx_refresh_screen();
    } while (*response == 12);

    del_panel(panel);
    delwin(win);
    update_panels();
    doupdate();
}                                
开发者ID:SvenDowideit,项目名称:clearlinux,代码行数:31,代码来源:msgboxes.c

示例4: closeWindow

/**
 * Close window and free allocated ram
 */
void closeWindow(struct panelw *p)
{
        wborder(p->win, ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ');
	delwin(p->win);
        del_panel(p->panel);
        refresh();
}
开发者ID:lucidm,项目名称:i2lcd,代码行数:10,代码来源:editlcd.c

示例5: close_panel

static void close_panel(PANEL *p)
{
	if (p) {
		del_panel(p);
		p = NULL;
	}
}
开发者ID:383530895,项目名称:linux,代码行数:7,代码来源:tui.c

示例6: rbncurs_c_del_panel

static VALUE rbncurs_c_del_panel(VALUE rb_panel) {
    VALUE panels_hash   = rb_iv_get(mPanel, "@panels_hash");
    PANEL* panel       = get_panel(rb_panel);
    VALUE panel_adress  = INT2NUM((long)(panel));
    rb_funcall(panels_hash, rb_intern("delete"), 1, panel_adress);
    rb_iv_set(rb_panel, "@destroyed", Qtrue);
    return INT2NUM(del_panel(panel));
}
开发者ID:sup-heliotrope,项目名称:ncursesw-ruby,代码行数:8,代码来源:panel_wrap.c

示例7: destroy_ui

void destroy_ui(ui_t *ui) {
  // chat panel and window
  del_panel(CHAT);
  delwin(ui->screen);
  ui_history_destroy(&chat_history);
  // log panel and window
  del_panel(LOG);
  delwin(ui->log);
  ui_history_destroy(&log_history);
  // alert panel and window
  del_panel(ALERT);
  delwin(ui->alert);
  // prompt window
  delwin(ui->prompt);

  endwin();
  free(ui);
}
开发者ID:draganglumac,项目名称:whisper-shell,代码行数:18,代码来源:ui.c

示例8: lui_destroy_window

/*
  window.__gc
  destroy the window

  Stack:
  1: the instance table
  2: the accessed key
*/
int		lui_destroy_window(lua_State *L)
{
    PANEL		*p;
    WINDOW	*w;

    p = check_window(L, 1);
    w = panel_window(p);
    del_panel(p);
    delwin(w);
    return 0;
}
开发者ID:Sarcasm,项目名称:luasoul,代码行数:19,代码来源:window.c

示例9: mydelwin

void mydelwin(NEWWIN *win)
{
	if (win)
	{
		if (win -> pwin && ERR == del_panel(win -> pwin))
			error_exit(TRUE, "del_panel() failed\n");

		if (win -> win && ERR == delwin(win -> win))
			error_exit(TRUE, "delwin() failed\n");
	}
}
开发者ID:Toeger,项目名称:f-irc,代码行数:11,代码来源:term.c

示例10: del_panel

//--------------------------------------------------------------------
void ConWindow::close()
{
    if (pan) {
        del_panel(pan);
        pan = NULL;
    }

    if (win) {
        delwin(win);
        win = NULL;
    }
} // end ConWindow::close
开发者ID:modulexcite,项目名称:vbindiff,代码行数:13,代码来源:ConWin.cpp

示例11: SafeDelete

CWidget::~CWidget()
{
	SafeDelete(_fwdDataSelect);

	del_panel(_panel);
	delwin(_window);

	_window = 0;
	_panel = 0;

	SafeDelete(_layout);
}
开发者ID:ProDotaTrY,项目名称:ghostcb,代码行数:12,代码来源:widget.cpp

示例12: panel_stack_rm

void panel_stack_rm(PANEL *panel) {
	WINDOW *win;
	
	if( (win = panel_window(panel) ) == NULL ) 
		err_exit(0, "could not get window from panel");

	if( del_panel(panel) == ERR ) 
		err_exit(0, "could not delete panel");
	
	if( delwin(win) == ERR )
		err_exit(0, "could not delete window");

}
开发者ID:cantora,项目名称:aug,代码行数:13,代码来源:panel_stack.c

示例13: value_list_free

static int value_list_free(struct value_list *vl)
{
	if (vl->panel) {
		del_panel(vl->panel);
	}
	if (vl->sub) {
		delwin(vl->sub);
	}
	if (vl->window) {
		delwin(vl->window);
	}

	return 0;
}
开发者ID:DanilKorotenko,项目名称:samba,代码行数:14,代码来源:regedit_valuelist.c

示例14: settimeout

static void settimeout(time_t *value, const char *units, int allow_zero,
		       int *aborted)
{
	WINDOW *dlgwin;
	PANEL *dlgpanel;
	struct FIELDLIST field;
	time_t tmval = 0;

	dlgwin = newwin(7, 40, (LINES - 7) / 2, (COLS - 40) / 4);
	dlgpanel = new_panel(dlgwin);

	wattrset(dlgwin, DLGBOXATTR);
	tx_colorwin(dlgwin);
	tx_box(dlgwin, ACS_VLINE, ACS_HLINE);

	wattrset(dlgwin, DLGTEXTATTR);
	wmove(dlgwin, 2, 2);
	wprintw(dlgwin, "Enter value in %s", units);
	wmove(dlgwin, 5, 2);
	stdkeyhelp(dlgwin);

	tx_initfields(&field, 1, 10, (LINES - 7) / 2 + 3, (COLS - 40) / 4 + 2,
		      DLGTEXTATTR, FIELDATTR);
	tx_addfield(&field, 3, 0, 0, "");

	do {
		tx_fillfields(&field, aborted);

		if (!(*aborted)) {
			unsigned int tm;

			tmval = 0;
			int ret = strtoul_ui(field.list->buf, 10, &tm);
			if ((ret == -1) || (!allow_zero && (tm == 0)))
				tui_error(ANYKEY_MSG, "Invalid timeout value");
			else
				tmval = tm;
		}
	} while (((!allow_zero) && (tmval == 0)) && (!(*aborted)));

	if (!(*aborted))
		*value = tmval;

	del_panel(dlgpanel);
	delwin(dlgwin);

	tx_destroyfields(&field);
	update_panels();
	doupdate();
}
开发者ID:rogerhu,项目名称:dd-wrt,代码行数:50,代码来源:options.c

示例15: call_raw_destroy

void
call_raw_destroy(PANEL *panel)
{
    call_raw_info_t *info;

    if ((info = call_raw_info(panel))) {
        // Delete panel windows
        delwin(info->pad);
        sng_free(info);
    }
    // Delete panel window
    delwin(panel_window(panel));
    // Delete panel
    del_panel(panel);
}
开发者ID:jungle-boogie,项目名称:sngrep,代码行数:15,代码来源:ui_call_raw.c


注:本文中的del_panel函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。