Mercurial > vim
comparison src/gui.c @ 706:ef3b59af4207
updated for version 7.0213
author | vimboss |
---|---|
date | Fri, 03 Mar 2006 22:50:42 +0000 |
parents | 07d199fe02ed |
children | c0f1b710ce07 |
comparison
equal
deleted
inserted
replaced
705:69e8006af734 | 706:ef3b59af4207 |
---|---|
3095 #ifdef FEAT_TOOLBAR | 3095 #ifdef FEAT_TOOLBAR |
3096 static int prev_toolbar = -1; | 3096 static int prev_toolbar = -1; |
3097 int using_toolbar = FALSE; | 3097 int using_toolbar = FALSE; |
3098 #endif | 3098 #endif |
3099 #ifdef FEAT_GUI_TABLINE | 3099 #ifdef FEAT_GUI_TABLINE |
3100 static int prev_has_tabline = FALSE; | |
3101 int using_tabline; | 3100 int using_tabline; |
3102 #endif | 3101 #endif |
3103 #ifdef FEAT_FOOTER | 3102 #ifdef FEAT_FOOTER |
3104 static int prev_footer = -1; | 3103 static int prev_footer = -1; |
3105 int using_footer = FALSE; | 3104 int using_footer = FALSE; |
3197 | 3196 |
3198 #ifdef FEAT_GUI_TABLINE | 3197 #ifdef FEAT_GUI_TABLINE |
3199 /* Update the GUI tab line, it may appear or disappear. This may | 3198 /* Update the GUI tab line, it may appear or disappear. This may |
3200 * cause the non-GUI tab line to disappear or appear. */ | 3199 * cause the non-GUI tab line to disappear or appear. */ |
3201 using_tabline = gui_has_tabline(); | 3200 using_tabline = gui_has_tabline(); |
3202 if (prev_has_tabline != using_tabline) | 3201 if (!gui_mch_showing_tabline() != !using_tabline) |
3203 { | 3202 { |
3204 prev_has_tabline = using_tabline; | |
3205 gui_update_tabline(); | 3203 gui_update_tabline(); |
3206 need_set_size = TRUE; | 3204 need_set_size = TRUE; |
3207 if (using_tabline) | 3205 if (using_tabline) |
3208 fix_size = TRUE; | 3206 fix_size = TRUE; |
3209 if (!gui_use_tabline()) | 3207 if (!gui_use_tabline()) |
3367 if (*p_gtl != NUL) | 3365 if (*p_gtl != NUL) |
3368 { | 3366 { |
3369 int use_sandbox = FALSE; | 3367 int use_sandbox = FALSE; |
3370 int save_called_emsg = called_emsg; | 3368 int save_called_emsg = called_emsg; |
3371 char_u res[MAXPATHL]; | 3369 char_u res[MAXPATHL]; |
3370 tabpage_T *save_curtab; | |
3372 | 3371 |
3373 called_emsg = FALSE; | 3372 called_emsg = FALSE; |
3374 | 3373 |
3375 printer_page_num = tabpage_index(tp); | 3374 printer_page_num = tabpage_index(tp); |
3376 # ifdef FEAT_EVAL | 3375 # ifdef FEAT_EVAL |
3377 set_vim_var_nr(VV_LNUM, printer_page_num); | 3376 set_vim_var_nr(VV_LNUM, printer_page_num); |
3378 use_sandbox = was_set_insecurely((char_u *)"guitablabel", 0); | 3377 use_sandbox = was_set_insecurely((char_u *)"guitablabel", 0); |
3379 # endif | 3378 # endif |
3379 /* It's almost as going to the tabpage, but without autocommands. */ | |
3380 curtab->tp_firstwin = firstwin; | |
3381 curtab->tp_lastwin = lastwin; | |
3382 curtab->tp_curwin = curwin; | |
3383 save_curtab = curtab; | |
3384 curtab = tp; | |
3385 topframe = curtab->tp_topframe; | |
3386 firstwin = curtab->tp_firstwin; | |
3387 lastwin = curtab->tp_lastwin; | |
3388 curwin = curtab->tp_curwin; | |
3389 curbuf = curwin->w_buffer; | |
3390 | |
3380 /* Can't use NameBuff directly, build_stl_str_hl() uses it. */ | 3391 /* Can't use NameBuff directly, build_stl_str_hl() uses it. */ |
3381 build_stl_str_hl(tp == curtab ? curwin : tp->tp_curwin, | 3392 build_stl_str_hl(curwin, res, MAXPATHL, p_gtl, use_sandbox, |
3382 res, MAXPATHL, p_gtl, use_sandbox, | 3393 0, (int)Columns, NULL, NULL); |
3383 0, (int)Columns, NULL, NULL); | |
3384 STRCPY(NameBuff, res); | 3394 STRCPY(NameBuff, res); |
3395 | |
3396 /* Back to the original curtab. */ | |
3397 curtab = save_curtab; | |
3398 topframe = curtab->tp_topframe; | |
3399 firstwin = curtab->tp_firstwin; | |
3400 lastwin = curtab->tp_lastwin; | |
3401 curwin = curtab->tp_curwin; | |
3402 curbuf = curwin->w_buffer; | |
3385 | 3403 |
3386 if (called_emsg) | 3404 if (called_emsg) |
3387 set_string_option_direct((char_u *)"guitablabel", -1, | 3405 set_string_option_direct((char_u *)"guitablabel", -1, |
3388 (char_u *)"", OPT_FREE, SID_ERROR); | 3406 (char_u *)"", OPT_FREE, SID_ERROR); |
3389 called_emsg |= save_called_emsg; | 3407 called_emsg |= save_called_emsg; |