mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.2.3313: unused code in win_exchange() and frame_remove()
Problem: Unused code in win_exchange() and frame_remove(). Solution: Remove the code. (closes #8728)
This commit is contained in:
@@ -755,6 +755,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
3313,
|
||||||
/**/
|
/**/
|
||||||
3312,
|
3312,
|
||||||
/**/
|
/**/
|
||||||
|
27
src/window.c
27
src/window.c
@@ -1684,24 +1684,10 @@ win_exchange(long Prenum)
|
|||||||
curwin->w_vsep_width = wp->w_vsep_width;
|
curwin->w_vsep_width = wp->w_vsep_width;
|
||||||
wp->w_vsep_width = temp;
|
wp->w_vsep_width = temp;
|
||||||
|
|
||||||
// If the windows are not in the same frame, exchange the sizes to avoid
|
frame_fix_height(curwin);
|
||||||
// messing up the window layout. Otherwise fix the frame sizes.
|
frame_fix_height(wp);
|
||||||
if (curwin->w_frame->fr_parent != wp->w_frame->fr_parent)
|
frame_fix_width(curwin);
|
||||||
{
|
frame_fix_width(wp);
|
||||||
temp = curwin->w_height;
|
|
||||||
curwin->w_height = wp->w_height;
|
|
||||||
wp->w_height = temp;
|
|
||||||
temp = curwin->w_width;
|
|
||||||
curwin->w_width = wp->w_width;
|
|
||||||
wp->w_width = temp;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
frame_fix_height(curwin);
|
|
||||||
frame_fix_height(wp);
|
|
||||||
frame_fix_width(curwin);
|
|
||||||
frame_fix_width(wp);
|
|
||||||
}
|
|
||||||
|
|
||||||
(void)win_comp_pos(); // recompute window positions
|
(void)win_comp_pos(); // recompute window positions
|
||||||
|
|
||||||
@@ -5275,12 +5261,7 @@ frame_remove(frame_T *frp)
|
|||||||
if (frp->fr_prev != NULL)
|
if (frp->fr_prev != NULL)
|
||||||
frp->fr_prev->fr_next = frp->fr_next;
|
frp->fr_prev->fr_next = frp->fr_next;
|
||||||
else
|
else
|
||||||
{
|
|
||||||
frp->fr_parent->fr_child = frp->fr_next;
|
frp->fr_parent->fr_child = frp->fr_next;
|
||||||
// special case: topframe->fr_child == frp
|
|
||||||
if (topframe->fr_child == frp)
|
|
||||||
topframe->fr_child = frp->fr_next;
|
|
||||||
}
|
|
||||||
if (frp->fr_next != NULL)
|
if (frp->fr_next != NULL)
|
||||||
frp->fr_next->fr_prev = frp->fr_prev;
|
frp->fr_next->fr_prev = frp->fr_prev;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user