summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoryokota <yokota@FreeBSD.org>1999-08-27 09:20:41 +0000
committeryokota <yokota@FreeBSD.org>1999-08-27 09:20:41 +0000
commit07f04c3d8d4544ec504742727e6d62bd6b64cdeb (patch)
tree662af41f7e23b433679e1397fe8fd249621bc8d9
parent5b04d658f26de05ff337e4eaa751dec988f525fa (diff)
downloadFreeBSD-src-07f04c3d8d4544ec504742727e6d62bd6b64cdeb.zip
FreeBSD-src-07f04c3d8d4544ec504742727e6d62bd6b64cdeb.tar.gz
- Retain the previous vty and history buffers when setting up
the graphics mode. This was the behavior prior to syscons.c rev 1.278, but broken in scvidctl.c rev 1.1.
-rw-r--r--sys/dev/syscons/scvidctl.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/sys/dev/syscons/scvidctl.c b/sys/dev/syscons/scvidctl.c
index 3951425..1187657 100644
--- a/sys/dev/syscons/scvidctl.c
+++ b/sys/dev/syscons/scvidctl.c
@@ -23,7 +23,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: scvidctl.c,v 1.9 1999/06/22 14:13:29 yokota Exp $
+ * $Id: scvidctl.c,v 1.10 1999/07/07 13:48:49 yokota Exp $
*/
#include "sc.h"
@@ -243,7 +243,6 @@ sc_set_graphics_mode(scr_stat *scp, struct tty *tp, int mode)
#else
video_info_t info;
sc_rndr_sw_t *rndr;
- int prev_ysize;
int error;
int s;
@@ -264,12 +263,13 @@ sc_set_graphics_mode(scr_stat *scp, struct tty *tp, int mode)
}
/* set up scp */
- prev_ysize = scp->ysize;
scp->status |= (UNKNOWN_MODE | GRAPHICS_MODE);
scp->status &= ~PIXEL_MODE;
scp->mode = mode;
- scp->xsize = info.vi_width/8;
- scp->ysize = info.vi_height/info.vi_cheight;
+ /*
+ * Don't change xsize and ysize; preserve the previous vty
+ * and history buffers.
+ */
scp->xoff = 0;
scp->yoff = 0;
scp->xpixel = info.vi_width;
@@ -280,9 +280,6 @@ sc_set_graphics_mode(scr_stat *scp, struct tty *tp, int mode)
/* move the mouse cursor at the center of the screen */
sc_mouse_move(scp, scp->xpixel / 2, scp->ypixel / 2);
#endif
-#ifndef SC_NO_HISTORY
- sc_free_history_buffer(scp, prev_ysize);
-#endif
scp->rndr = rndr;
splx(s);
OpenPOWER on IntegriCloud