Subversion Repositories SvarDOS

Rev

Rev 1557 | Rev 1560 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1557 Rev 1559
Line 664... Line 664...
664
  if (fname == NULL) goto SKIPLOADING;
664
  if (fname == NULL) goto SKIPLOADING;
665
 
665
 
666
  /* make the filename canonical (DOS 3+ only, on earlier versions it just copies the filename) */
666
  /* make the filename canonical (DOS 3+ only, on earlier versions it just copies the filename) */
667
  mdr_dos_truename(db->fname, fname);
667
  mdr_dos_truename(db->fname, fname);
668
 
668
 
669
  err = mdr_dos_fopen(fname, &fd);
669
  /* fopen file */
-
 
670
  fd = 0;
-
 
671
  _asm {
-
 
672
    push cx
-
 
673
    push dx
-
 
674
 
-
 
675
    mov ax, 0x3d00
-
 
676
    mov dx, fname   // works only in SMALL memory model!
-
 
677
    xor cl, cl
-
 
678
    int 0x21
-
 
679
    mov fd, ax
-
 
680
    jnc done
-
 
681
    mov err, al
-
 
682
    done:
-
 
683
 
-
 
684
    pop dx
-
 
685
    pop cx
-
 
686
  }
-
 
687
 
670
  if (err != 0) goto SKIPLOADING;
688
  if (err != 0) goto SKIPLOADING;
671
 
689
 
672
  db->lfonly = 1;
690
  db->lfonly = 1;
673
 
691
 
674
  for (eolfound = 0;;) {
692
  for (eolfound = 0;;) {
Line 967... Line 985...
967
  static struct file dbarr[10];
985
  static struct file dbarr[10];
968
  struct file *db = dbarr; /* visible file is the first slot by default */
986
  struct file *db = dbarr; /* visible file is the first slot by default */
969
  static struct line far *clipboard;
987
  static struct line far *clipboard;
970
  static unsigned char original_breakflag;
988
  static unsigned char original_breakflag;
971
 
989
 
972
  mdr_coutraw_puts("glob_monomode:");
-
 
973
  mdr_coutraw_char('0' + glob_monomode);
-
 
974
  mdr_coutraw_crlf();
-
 
975
 
-
 
976
  mdr_coutraw_puts("original_breakflag:");
-
 
977
  mdr_coutraw_char('0' + original_breakflag);
-
 
978
  mdr_coutraw_crlf();
-
 
979
 
-
 
980
  { /* load NLS resource */
990
  { /* load NLS resource */
981
    unsigned short i = 0;
991
    unsigned short i = 0;
982
    const char far *selfptr;
992
    const char far *selfptr;
983
    char lang[8];
993
    char lang[8];
984
    selfptr = mdr_dos_selfexe();
994
    selfptr = mdr_dos_selfexe();
Line 1012... Line 1022...
1012
    SCHEME_STBAR2 = 0x78;
1022
    SCHEME_STBAR2 = 0x78;
1013
    SCHEME_STBAR3 = 0x3f;
1023
    SCHEME_STBAR3 = 0x3f;
1014
    SCHEME_SCROLL = 0x70;
1024
    SCHEME_SCROLL = 0x70;
1015
    SCHEME_MSG = 0x6f;
1025
    SCHEME_MSG = 0x6f;
1016
    SCHEME_ERR = 0x4f;
1026
    SCHEME_ERR = 0x4f;
1017
  } else {
-
 
1018
    // FIXME
-
 
1019
    mdr_coutraw_char('0' + glob_monomode);
-
 
1020
    _asm int 0x20
-
 
1021
  }
1027
  }
1022
  screenlastrow = screenh - 1;
1028
  screenlastrow = screenh - 1;
1023
  screenlastcol = screenw - 1;
1029
  screenlastcol = screenw - 1;
1024
 
1030
 
1025
  /* instruct DOS to stop detecting CTRL+C because user needs it for
1031
  /* instruct DOS to stop detecting CTRL+C because user needs it for