Mercurial > vim
comparison src/screen.c @ 19526:22f0dda71638 v8.2.0320
patch 8.2.0320: no Haiku support
Commit: https://github.com/vim/vim/commit/b3f740695a0199d22cd97aee314f06c7ae32d2ea
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Feb 26 16:16:53 2020 +0100
patch 8.2.0320: no Haiku support
Problem: No Haiku support.
Solution: Add support for Haiku. (Emir Sari, closes https://github.com/vim/vim/issues/5605)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 26 Feb 2020 16:30:04 +0100 |
parents | d34ec6fe207d |
children | 09a621bdb0bc |
comparison
equal
deleted
inserted
replaced
19525:619eb9bc3249 | 19526:22f0dda71638 |
---|---|
2546 * thus we must not redraw here! | 2546 * thus we must not redraw here! |
2547 */ | 2547 */ |
2548 ++RedrawingDisabled; | 2548 ++RedrawingDisabled; |
2549 | 2549 |
2550 win_new_shellsize(); // fit the windows in the new sized shell | 2550 win_new_shellsize(); // fit the windows in the new sized shell |
2551 | |
2552 #ifdef FEAT_GUI_HAIKU | |
2553 vim_lock_screen(); // be safe, put it here | |
2554 #endif | |
2551 | 2555 |
2552 comp_col(); // recompute columns for shown command and ruler | 2556 comp_col(); // recompute columns for shown command and ruler |
2553 | 2557 |
2554 /* | 2558 /* |
2555 * We're changing the size of the screen. | 2559 * We're changing the size of the screen. |
2797 msg_col = Columns - 1; // put cursor at last column | 2801 msg_col = Columns - 1; // put cursor at last column |
2798 } | 2802 } |
2799 #endif | 2803 #endif |
2800 clear_TabPageIdxs(); | 2804 clear_TabPageIdxs(); |
2801 | 2805 |
2806 #ifdef FEAT_GUI_HAIKU | |
2807 vim_unlock_screen(); | |
2808 #endif | |
2809 | |
2802 entered = FALSE; | 2810 entered = FALSE; |
2803 --RedrawingDisabled; | 2811 --RedrawingDisabled; |
2804 | 2812 |
2805 /* | 2813 /* |
2806 * Do not apply autocommands more than 3 times to avoid an endless loop | 2814 * Do not apply autocommands more than 3 times to avoid an endless loop |
3644 clip_clear_selection(&clip_star); | 3652 clip_clear_selection(&clip_star); |
3645 else | 3653 else |
3646 clip_scroll_selection(-line_count); | 3654 clip_scroll_selection(-line_count); |
3647 #endif | 3655 #endif |
3648 | 3656 |
3657 #ifdef FEAT_GUI_HAIKU | |
3658 vim_lock_screen(); | |
3659 #endif | |
3660 | |
3649 #ifdef FEAT_GUI | 3661 #ifdef FEAT_GUI |
3650 // Don't update the GUI cursor here, ScreenLines[] is invalid until the | 3662 // Don't update the GUI cursor here, ScreenLines[] is invalid until the |
3651 // scrolling is actually carried out. | 3663 // scrolling is actually carried out. |
3652 gui_dont_update_cursor(row + off <= gui.cursor_row); | 3664 gui_dont_update_cursor(row + off <= gui.cursor_row); |
3653 #endif | 3665 #endif |
3697 lineclear(temp, (int)Columns, clear_attr); | 3709 lineclear(temp, (int)Columns, clear_attr); |
3698 else | 3710 else |
3699 lineinvalid(temp, (int)Columns); | 3711 lineinvalid(temp, (int)Columns); |
3700 } | 3712 } |
3701 } | 3713 } |
3714 | |
3715 #ifdef FEAT_GUI_HAIKU | |
3716 vim_unlock_screen(); | |
3717 #endif | |
3702 | 3718 |
3703 screen_stop_highlight(); | 3719 screen_stop_highlight(); |
3704 windgoto(cursor_row, cursor_col); | 3720 windgoto(cursor_row, cursor_col); |
3705 if (clear_attr != 0) | 3721 if (clear_attr != 0) |
3706 screen_start_highlight(clear_attr); | 3722 screen_start_highlight(clear_attr); |
3926 else | 3942 else |
3927 lineinvalid(temp, (int)Columns); | 3943 lineinvalid(temp, (int)Columns); |
3928 } | 3944 } |
3929 } | 3945 } |
3930 | 3946 |
3947 #ifdef FEAT_GUI_HAIKU | |
3948 vim_unlock_screen(); | |
3949 #endif | |
3950 | |
3931 if (screen_attr != clear_attr) | 3951 if (screen_attr != clear_attr) |
3932 screen_stop_highlight(); | 3952 screen_stop_highlight(); |
3933 if (clear_attr != 0) | 3953 if (clear_attr != 0) |
3934 screen_start_highlight(clear_attr); | 3954 screen_start_highlight(clear_attr); |
3935 | 3955 |