Mercurial > vim
comparison src/gui.c @ 19181:94eda51ba9ba v8.2.0149
patch 8.2.0149: maintaining a Vim9 branch separately is more work
Commit: https://github.com/vim/vim/commit/8a7d6542b33e5d2b352262305c3bfdb2d14e1cf8
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jan 26 15:56:19 2020 +0100
patch 8.2.0149: maintaining a Vim9 branch separately is more work
Problem: Maintaining a Vim9 branch separately is more work.
Solution: Merge the Vim9 script changes.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 26 Jan 2020 16:00:05 +0100 |
parents | 7abe2444d1e1 |
children | 2ef19eed524a |
comparison
equal
deleted
inserted
replaced
19180:8edf0aeb71b9 | 19181:94eda51ba9ba |
---|---|
517 */ | 517 */ |
518 #if defined(SYS_MENU_FILE) && defined(FEAT_MENU) | 518 #if defined(SYS_MENU_FILE) && defined(FEAT_MENU) |
519 if (vim_strchr(p_go, GO_NOSYSMENU) == NULL) | 519 if (vim_strchr(p_go, GO_NOSYSMENU) == NULL) |
520 { | 520 { |
521 sys_menu = TRUE; | 521 sys_menu = TRUE; |
522 do_source((char_u *)SYS_MENU_FILE, FALSE, DOSO_NONE); | 522 do_source((char_u *)SYS_MENU_FILE, FALSE, DOSO_NONE, NULL); |
523 sys_menu = FALSE; | 523 sys_menu = FALSE; |
524 } | 524 } |
525 #endif | 525 #endif |
526 | 526 |
527 /* | 527 /* |
538 */ | 538 */ |
539 if (use_gvimrc != NULL) | 539 if (use_gvimrc != NULL) |
540 { | 540 { |
541 if (STRCMP(use_gvimrc, "NONE") != 0 | 541 if (STRCMP(use_gvimrc, "NONE") != 0 |
542 && STRCMP(use_gvimrc, "NORC") != 0 | 542 && STRCMP(use_gvimrc, "NORC") != 0 |
543 && do_source(use_gvimrc, FALSE, DOSO_NONE) != OK) | 543 && do_source(use_gvimrc, FALSE, DOSO_NONE, NULL) != OK) |
544 semsg(_("E230: Cannot read from \"%s\""), use_gvimrc); | 544 semsg(_("E230: Cannot read from \"%s\""), use_gvimrc, NULL); |
545 } | 545 } |
546 else | 546 else |
547 { | 547 { |
548 /* | 548 /* |
549 * Get system wide defaults for gvim, only when file name defined. | 549 * Get system wide defaults for gvim, only when file name defined. |
550 */ | 550 */ |
551 #ifdef SYS_GVIMRC_FILE | 551 #ifdef SYS_GVIMRC_FILE |
552 do_source((char_u *)SYS_GVIMRC_FILE, FALSE, DOSO_NONE); | 552 do_source((char_u *)SYS_GVIMRC_FILE, FALSE, DOSO_NONE, NULL); |
553 #endif | 553 #endif |
554 | 554 |
555 /* | 555 /* |
556 * Try to read GUI initialization commands from the following | 556 * Try to read GUI initialization commands from the following |
557 * places: | 557 * places: |
561 * - the third user gvimrc file ($VIM/.gvimrc for Amiga) | 561 * - the third user gvimrc file ($VIM/.gvimrc for Amiga) |
562 * The first that exists is used, the rest is ignored. | 562 * The first that exists is used, the rest is ignored. |
563 */ | 563 */ |
564 if (process_env((char_u *)"GVIMINIT", FALSE) == FAIL | 564 if (process_env((char_u *)"GVIMINIT", FALSE) == FAIL |
565 && do_source((char_u *)USR_GVIMRC_FILE, TRUE, | 565 && do_source((char_u *)USR_GVIMRC_FILE, TRUE, |
566 DOSO_GVIMRC) == FAIL | 566 DOSO_GVIMRC, NULL) == FAIL |
567 #ifdef USR_GVIMRC_FILE2 | 567 #ifdef USR_GVIMRC_FILE2 |
568 && do_source((char_u *)USR_GVIMRC_FILE2, TRUE, | 568 && do_source((char_u *)USR_GVIMRC_FILE2, TRUE, |
569 DOSO_GVIMRC) == FAIL | 569 DOSO_GVIMRC, NULL) == FAIL |
570 #endif | 570 #endif |
571 #ifdef USR_GVIMRC_FILE3 | 571 #ifdef USR_GVIMRC_FILE3 |
572 && do_source((char_u *)USR_GVIMRC_FILE3, TRUE, | 572 && do_source((char_u *)USR_GVIMRC_FILE3, TRUE, |
573 DOSO_GVIMRC) == FAIL | 573 DOSO_GVIMRC, NULL) == FAIL |
574 #endif | 574 #endif |
575 ) | 575 ) |
576 { | 576 { |
577 #ifdef USR_GVIMRC_FILE4 | 577 #ifdef USR_GVIMRC_FILE4 |
578 (void)do_source((char_u *)USR_GVIMRC_FILE4, TRUE, DOSO_GVIMRC); | 578 (void)do_source((char_u *)USR_GVIMRC_FILE4, TRUE, |
579 DOSO_GVIMRC, NULL); | |
579 #endif | 580 #endif |
580 } | 581 } |
581 | 582 |
582 /* | 583 /* |
583 * Read initialization commands from ".gvimrc" in current | 584 * Read initialization commands from ".gvimrc" in current |
621 #ifdef USR_GVIMRC_FILE4 | 622 #ifdef USR_GVIMRC_FILE4 |
622 && fullpathcmp((char_u *)USR_GVIMRC_FILE4, | 623 && fullpathcmp((char_u *)USR_GVIMRC_FILE4, |
623 (char_u *)GVIMRC_FILE, FALSE, TRUE) != FPC_SAME | 624 (char_u *)GVIMRC_FILE, FALSE, TRUE) != FPC_SAME |
624 #endif | 625 #endif |
625 ) | 626 ) |
626 do_source((char_u *)GVIMRC_FILE, TRUE, DOSO_GVIMRC); | 627 do_source((char_u *)GVIMRC_FILE, TRUE, DOSO_GVIMRC, NULL); |
627 | 628 |
628 if (secure == 2) | 629 if (secure == 2) |
629 need_wait_return = TRUE; | 630 need_wait_return = TRUE; |
630 secure = 0; | 631 secure = 0; |
631 } | 632 } |