=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/cmd-split-window.c,v retrieving revision 1.14 retrieving revision 1.15 diff -c -r1.14 -r1.15 *** src/usr.bin/tmux/cmd-split-window.c 2009/11/13 19:53:29 1.14 --- src/usr.bin/tmux/cmd-split-window.c 2009/11/20 19:12:39 1.15 *************** *** 1,4 **** ! /* $OpenBSD: cmd-split-window.c,v 1.14 2009/11/13 19:53:29 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott --- 1,4 ---- ! /* $OpenBSD: cmd-split-window.c,v 1.15 2009/11/20 19:12:39 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott *************** *** 174,189 **** else cwd = ctx->cmdclient->cwd; size = -1; if (data->size != -1) size = data->size; ! else if (data->percentage != -1) ! size = (w->active->sy * data->percentage) / 100; hlimit = options_get_number(&s->options, "history-limit"); - - type = LAYOUT_TOPBOTTOM; - if (data->flag_horizontal) - type = LAYOUT_LEFTRIGHT; shell = options_get_string(&s->options, "default-shell"); if (*shell == '\0' || areshell(shell)) --- 174,193 ---- else cwd = ctx->cmdclient->cwd; + type = LAYOUT_TOPBOTTOM; + if (data->flag_horizontal) + type = LAYOUT_LEFTRIGHT; + size = -1; if (data->size != -1) size = data->size; ! else if (data->percentage != -1) { ! if (type == LAYOUT_TOPBOTTOM) ! size = (w->active->sy * data->percentage) / 100; ! else ! size = (w->active->sx * data->percentage) / 100; ! } hlimit = options_get_number(&s->options, "history-limit"); shell = options_get_string(&s->options, "default-shell"); if (*shell == '\0' || areshell(shell))