Switch to unified view

a/src/qtgui/preview_w.cpp b/src/qtgui/preview_w.cpp
1
#ifndef lint
1
#ifndef lint
2
static char rcsid[] = "@(#$Id: preview_w.cpp,v 1.4 2006-09-23 07:39:55 dockes Exp $ (C) 2005 J.F.Dockes";
2
static char rcsid[] = "@(#$Id: preview_w.cpp,v 1.5 2006-11-09 19:04:28 dockes Exp $ (C) 2005 J.F.Dockes";
3
#endif
3
#endif
4
/*
4
/*
5
 *   This program is free software; you can redistribute it and/or modify
5
 *   This program is free software; you can redistribute it and/or modify
6
 *   it under the terms of the GNU General Public License as published by
6
 *   it under the terms of the GNU General Public License as published by
7
 *   the Free Software Foundation; either version 2 of the License, or
7
 *   the Free Software Foundation; either version 2 of the License, or
...
...
425
        *statusp = -1;
425
        *statusp = -1;
426
        return;
426
        return;
427
    }
427
    }
428
    FileInterner interner(filename, rclconfig, tmpdir, mtype);
428
    FileInterner interner(filename, rclconfig, tmpdir, mtype);
429
    try {
429
    try {
430
      if (interner.internfile(*out, ipath) != FileInterner::FIDone) {
430
      FileInterner::Status ret = interner.internfile(*out, ipath);
431
      if (ret == FileInterner::FIDone || ret == FileInterner::FIAgain) {
432
      // FIAgain is actually not nice here. It means that the record
433
      // for the *file* of a multidoc was selected. Actually this
434
      // shouldn't have had a preview link at all, but we don't know
435
      // how to handle it now. Better to show the first doc than
436
      // a mysterious error. Happens when the file name matches a
437
      // a search term of course.
438
      *statusp = 0;
439
      } else {
431
        *statusp = -1;
440
        *statusp = -1;
432
      } else {
433
      *statusp = 0;
434
        }
441
        }
435
    } catch (CancelExcept) {
442
    } catch (CancelExcept) {
436
        *statusp = -1;
443
        *statusp = -1;
437
    }
444
    }
438
    }
445
    }