Mercurial > vim
comparison src/buffer.c @ 961:c06c658691e2 v7.0.087
updated for version 7.0-087
author | vimboss |
---|---|
date | Tue, 05 Sep 2006 14:31:54 +0000 |
parents | e70aad5761b5 |
children | 994ea4e6f023 |
comparison
equal
deleted
inserted
replaced
960:8c8d07318d8d | 961:c06c658691e2 |
---|---|
432 | 432 |
433 #ifdef FEAT_NETBEANS_INTG | 433 #ifdef FEAT_NETBEANS_INTG |
434 if (usingNetbeans) | 434 if (usingNetbeans) |
435 netbeans_file_closed(buf); | 435 netbeans_file_closed(buf); |
436 #endif | 436 #endif |
437 #ifdef FEAT_AUTOCHDIR | 437 /* Change directories when the 'acd' option is set. */ |
438 /* Change directories when the acd option is set on. */ | 438 DO_AUTOCHDIR |
439 if (p_acd && curbuf->b_ffname != NULL | |
440 && vim_chdirfile(curbuf->b_ffname) == OK) | |
441 shorten_fnames(TRUE); | |
442 #endif | |
443 | 439 |
444 /* | 440 /* |
445 * Remove the buffer from the list. | 441 * Remove the buffer from the list. |
446 */ | 442 */ |
447 if (wipe_buf) | 443 if (wipe_buf) |
1420 /* Send fileOpened event because we've changed buffers. */ | 1416 /* Send fileOpened event because we've changed buffers. */ |
1421 if (usingNetbeans && isNetbeansBuffer(curbuf)) | 1417 if (usingNetbeans && isNetbeansBuffer(curbuf)) |
1422 netbeans_file_activated(curbuf); | 1418 netbeans_file_activated(curbuf); |
1423 #endif | 1419 #endif |
1424 | 1420 |
1425 #ifdef FEAT_AUTOCHDIR | 1421 /* Change directories when the 'acd' option is set. */ |
1426 /* Change directories when the acd option is set on. */ | 1422 DO_AUTOCHDIR |
1427 if (p_acd && curbuf->b_ffname != NULL | |
1428 && vim_chdirfile(curbuf->b_ffname) == OK) | |
1429 shorten_fnames(TRUE); | |
1430 #endif | |
1431 | 1423 |
1432 #ifdef FEAT_KEYMAP | 1424 #ifdef FEAT_KEYMAP |
1433 if (curbuf->b_kmap_state & KEYMAP_INIT) | 1425 if (curbuf->b_kmap_state & KEYMAP_INIT) |
1434 keymap_init(); | 1426 keymap_init(); |
1435 #endif | 1427 #endif |
1436 redraw_later(NOT_VALID); | 1428 redraw_later(NOT_VALID); |
1437 } | 1429 } |
1430 | |
1431 #if defined(FEAT_AUTOCHDIR) || defined(PROTO) | |
1432 /* | |
1433 * Change to the directory of the current buffer. | |
1434 */ | |
1435 void | |
1436 do_autochdir() | |
1437 { | |
1438 if (curbuf->b_ffname != NULL && vim_chdirfile(curbuf->b_ffname) == OK) | |
1439 shorten_fnames(TRUE); | |
1440 } | |
1441 #endif | |
1438 | 1442 |
1439 /* | 1443 /* |
1440 * functions for dealing with the buffer list | 1444 * functions for dealing with the buffer list |
1441 */ | 1445 */ |
1442 | 1446 |