home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / x / volume21 / xmcd / part10 < prev    next >
Encoding:
Text File  |  1993-12-19  |  78.2 KB  |  2,859 lines

  1. Newsgroups: comp.sources.x
  2. From: ti@bazooka.amb.org (Ti Kan)
  3. Subject: v21i072:  xmcd - X11/Motif CD audio player, Part10/13
  4. Message-ID: <1993Dec19.194033.24775@sparky.sterling.com>
  5. X-Md4-Signature: 74c99b43ce5c4844febdca1174579a00
  6. Sender: chris@sparky.sterling.com (Chris Olson)
  7. Organization: Sterling Software
  8. Date: Sun, 19 Dec 1993 19:40:33 GMT
  9. Approved: chris@sterling.com
  10.  
  11. Submitted-by: ti@bazooka.amb.org (Ti Kan)
  12. Posting-number: Volume 21, Issue 72
  13. Archive-name: xmcd/part10
  14. Environment: X11, OSF/Motif
  15.  
  16. #! /bin/sh
  17. # This is a shell archive.  Remove anything before this line, then unpack
  18. # it by saving it into a file and typing "sh file".  To overwrite existing
  19. # files, type "sh file -c".  You can also feed this as standard input via
  20. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  21. # will see the following message at the end:
  22. #        "End of archive 10 (of 13)."
  23. # Contents:  lib_svr4.c lib_tosh.c main.c util.c bitmaps bitmaps/ab.xbm
  24. #   bitmaps/btnlbl.xbm bitmaps/dbprog.xbm bitmaps/eject.xbm
  25. #   bitmaps/ff.xbm bitmaps/help.xbm bitmaps/keypad.xbm
  26. #   bitmaps/lock.xbm bitmaps/logo.xbm bitmaps/nextidx.xbm
  27. #   bitmaps/nexttrk.xbm bitmaps/playpaus.xbm bitmaps/poweroff.xbm
  28. #   bitmaps/previdx.xbm bitmaps/prevtrk.xbm bitmaps/repeat.xbm
  29. #   bitmaps/rew.xbm bitmaps/sample.xbm bitmaps/shuffle.xbm
  30. #   bitmaps/stop.xbm bitmaps/time.xbm bitmaps/xmcd.xbm
  31. # Wrapped by ti@bazooka on Mon Nov  8 10:35:22 1993
  32. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  33. if test -f 'lib_svr4.c' -a "${1}" != "-c" ; then 
  34.   echo shar: Will not clobber existing file \"'lib_svr4.c'\"
  35. else
  36. echo shar: Extracting \"'lib_svr4.c'\" \(13997 characters\)
  37. sed "s/^X//" >'lib_svr4.c' <<'END_OF_FILE'
  38. X/*
  39. X *   xmcd - Motif(tm) CD Audio Player
  40. X *
  41. X *   Copyright (C) 1993  Ti Kan
  42. X *   E-mail: ti@amb.org
  43. X *
  44. X *   This program is free software; you can redistribute it and/or modify
  45. X *   it under the terms of the GNU General Public License as published by
  46. X *   the Free Software Foundation; either version 2 of the License, or
  47. X *   (at your option) any later version.
  48. X *
  49. X *   This program is distributed in the hope that it will be useful,
  50. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  51. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  52. X *   GNU General Public License for more details.
  53. X *
  54. X *   You should have received a copy of the GNU General Public License
  55. X *   along with this program; if not, write to the Free Software
  56. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  57. X *
  58. X */
  59. X#ifndef LINT
  60. Xstatic char *_lib_svr4_c_ident_ = "@(#)lib_svr4.c    1.61 93/11/05";
  61. X#endif
  62. X
  63. X#ifndef OSI_VERS
  64. X#define OSI_VERS    "1.0"        /* Version */
  65. X#endif
  66. X
  67. X#include <Xm/Xm.h>
  68. X#include "xmcd.h"
  69. X#include "util.h"
  70. X#include "cdfunc.h"
  71. X#include "lib_scsipt.h"
  72. X
  73. X#if defined(SVR4) && !defined(sun) && !defined(SIMULATED_CDROM)
  74. X
  75. X
  76. Xextern AppData        app_data;
  77. Xextern bool_t        notrom_error;
  78. X
  79. X#ifndef LINT
  80. Xbool_t            lib_svr4 = TRUE;
  81. X#endif
  82. X
  83. XSTATIC int        fd = -1;    /* Passthrough device file desc */
  84. X
  85. X
  86. X#ifdef i386
  87. X/*
  88. X *   Intel x86 UNIX SVR4 support
  89. X *   Portable Device Interface/SCSI Device Interface
  90. X *
  91. X *   This software fragment contains code that interfaces xmcd to
  92. X *   the UNIX System V Release 4 operating system for the Intel
  93. X *   x86 hardware platforms from UNIX System Laboratories.
  94. X *   The name "USL", "UNIX" and "Intel" are used here for
  95. X *   identification purposes.  This software and its author are
  96. X *   not affiliated with USL or Intel.
  97. X */
  98. X
  99. X
  100. XSTATIC char        ptpath[FILE_PATH_SZ] = { '\0' };
  101. X                    /* Passthrough device path */
  102. XSTATIC req_sense_data_t    sense_data;    /* Request sense data buffer */
  103. X
  104. X
  105. X/*
  106. X * pthru_send
  107. X *    Build SCSI CDB and sent command to the device.
  108. X *
  109. X * Args:
  110. X *    opcode - SCSI command opcode
  111. X *    addr - The "address" portion of the SCSI CDB
  112. X *    buf - Pointer to data buffer
  113. X *    size - Number of bytes to transfer
  114. X *    rsvd - The "reserved" portion of the SCSI CDB
  115. X *    length - The "length" portion of the SCSI CDB
  116. X *    param - The "param" portion of the SCSI CDB
  117. X *    control - The "control" portion of the SCSI CDB
  118. X *    rw - Data transfer direction flag (READ_OP or WRITE_OP)
  119. X *
  120. X * Return:
  121. X *    TRUE - command completed successfully
  122. X *    FALSE - command failed
  123. X */
  124. Xbool_t
  125. Xpthru_send(
  126. X    byte_t        opcode,
  127. X    word32_t    addr,
  128. X    byte_t        *buf,
  129. X    word32_t    size,
  130. X    byte_t        rsvd,
  131. X    word32_t    length,
  132. X    byte_t        param,
  133. X    byte_t        control,
  134. X    byte_t        rw
  135. X)
  136. X{
  137. X    struct sb    sb;
  138. X    struct scb    *scbp;
  139. X    union scsi_cdb    cdb;
  140. X    
  141. X    if (fd < 0 || notrom_error)
  142. X        return(FALSE);
  143. X
  144. X    memset(&sense_data, (byte_t) 0, sizeof(sense_data));
  145. X    memset(&sb, (byte_t) 0, sizeof(sb));
  146. X    memset(&cdb, (byte_t) 0, sizeof(cdb));
  147. X
  148. X    sb.sb_type = ISCB_TYPE;
  149. X    scbp = &sb.SCB;
  150. X
  151. X    /* set up SCSI CDB */
  152. X    switch (opcode & 0xf0) {
  153. X    case 0xa0:
  154. X    case 0xe0:
  155. X        /* 12-byte commands */
  156. X        cdb.scl.sl_op = opcode;
  157. X        cdb.scl.sl_res1 = param;
  158. X        cdb.scl.sl_lun = 0;
  159. X        CDB12_BLK(&cdb.scl, bswap32(addr));
  160. X        CDB12_LEN(&cdb.scl, bswap32(length));
  161. X        CDB12_RSV(&cdb.scl, rsvd);
  162. X        CDB12_CTL(&cdb.scl, control);
  163. X
  164. X        scbp->sc_cmdpt = (caddr_t) SCL_AD(&cdb);
  165. X        scbp->sc_cmdsz = SCL_SZ;
  166. X        break;
  167. X
  168. X    case 0xc0:
  169. X    case 0xd0:
  170. X    case 0x20:
  171. X    case 0x30:
  172. X    case 0x40:
  173. X        /* 10-byte commands */
  174. X        cdb.scm.sm_op = opcode;
  175. X        cdb.scm.sm_res1 = param;
  176. X        cdb.scm.sm_lun = 0;
  177. X        CDB10_BLK(&cdb.scm, bswap32(addr));
  178. X        CDB10_LEN(&cdb.scm, bswap16((word16_t) length));
  179. X        CDB10_RSV(&cdb.scm, rsvd);
  180. X        CDB10_CTL(&cdb.scm, control);
  181. X
  182. X        scbp->sc_cmdpt = (caddr_t) SCM_AD(&cdb);
  183. X        scbp->sc_cmdsz = SCM_SZ;
  184. X        break;
  185. X
  186. X    case 0x00:
  187. X    case 0x10:
  188. X        /* 6-byte commands */
  189. X        cdb.scs.ss_op = opcode;
  190. X        cdb.scs.ss_addr1 = param;
  191. X        cdb.scs.ss_lun = 0;
  192. X        CDB6_BLK(&cdb.scs, bswap16((word16_t) addr));
  193. X        CDB6_LEN(&cdb.scs, (byte_t) length);
  194. X        CDB6_CTL(&cdb.scs, control);
  195. X
  196. X        scbp->sc_cmdpt = (caddr_t) SCS_AD(&cdb);
  197. X        scbp->sc_cmdsz = SCS_SZ;
  198. X        break;
  199. X
  200. X    default:
  201. X        if (app_data.scsierr_msg)
  202. X            fprintf(stderr, "0x%02x: Unknown SCSI opcode\n",
  203. X                opcode);
  204. X        return(FALSE);
  205. X    }
  206. X
  207. X#ifdef DEBUG
  208. X    {
  209. X        byte_t    *p = (byte_t *) scbp->sc_cmdpt;
  210. X        int    i;
  211. X
  212. X        fprintf(stderr, "\nSCSI CDB bytes:");
  213. X        for (i = 0; i < scbp->sc_cmdsz; i++, p++)
  214. X            fprintf(stderr, " %02x", i, *p);
  215. X        fprintf(stderr, "\n");
  216. X    }
  217. X#endif
  218. X
  219. X    /* set up scsicmd */
  220. X    scbp->sc_datapt = (caddr_t) buf;
  221. X    scbp->sc_datasz = size;
  222. X    scbp->sc_mode = (rw == READ_OP) ? SCB_READ : SCB_WRITE;
  223. X
  224. X    /* Send the command down via the "pass-through" interface */
  225. X    if (ioctl(fd, SDI_SEND, &sb) < 0) {
  226. X        perror("SDI_SEND ioctl failed");
  227. X        return(FALSE);
  228. X    }
  229. X
  230. X    if (scbp->sc_comp_code != SDI_ASW) {
  231. X        if (opcode != OP_S_TEST && app_data.scsierr_msg) {
  232. X            fprintf(stderr, "%s: %s %s:\n%s=0x%x %s=0x%x %s=0x%x",
  233. X                PROGNAME,
  234. X                "SCSI command fault on",
  235. X                app_data.device,
  236. X                "Opcode",
  237. X                opcode,
  238. X                "Completion_code",
  239. X                scbp->sc_comp_code,
  240. X                "Target_status",
  241. X                scbp->sc_status);
  242. X        }
  243. X
  244. X        /* Send Request Sense command */
  245. X        cdb.scs.ss_op = OP_S_RSENSE;
  246. X        cdb.scs.ss_addr1 = 0;
  247. X        cdb.scs.ss_lun = 0;
  248. X        CDB6_BLK(&cdb.scs, 0);
  249. X        CDB6_LEN(&cdb.scs, SZ_RSENSE);
  250. X        CDB6_CTL(&cdb.scs, 0);
  251. X        scbp->sc_datapt = (caddr_t) AD_RSENSE(&sense_data);
  252. X        scbp->sc_datasz = SZ_RSENSE;
  253. X        scbp->sc_mode = SCB_READ;
  254. X        scbp->sc_cmdpt = (caddr_t) SCS_AD(&cdb);
  255. X        scbp->sc_cmdsz = SCS_SZ;
  256. X
  257. X        if (ioctl(fd, SDI_SEND, &sb) < 0 || sense_data.valid == 0) {
  258. X            if (opcode != OP_S_TEST && app_data.scsierr_msg)
  259. X                fprintf(stderr, "\n");
  260. X#ifdef DEBUG
  261. X            perror("SDI_SEND ioctl (Request Sense) failed");
  262. X#endif
  263. X        }
  264. X        else if (opcode != OP_S_TEST && app_data.scsierr_msg) {
  265. X            fprintf(stderr, " Key=0x%x Code=0x%x Qual=0x%x\n",
  266. X                sense_data.key,
  267. X                sense_data.code,
  268. X                sense_data.qual);
  269. X        }
  270. X
  271. X        return(FALSE);
  272. X    }
  273. X    return(TRUE);
  274. X}
  275. X
  276. X
  277. X/*
  278. X * pthru_open
  279. X *    Open SCSI passthrough device
  280. X *
  281. X * Args:
  282. X *    path - device path name string
  283. X *
  284. X * Return:
  285. X *    TRUE - open successful
  286. X *    FALSE - open failed
  287. X */
  288. Xbool_t
  289. Xpthru_open(char *path)
  290. X{
  291. X    int        devfd;
  292. X    dev_t        ptdev;
  293. X    struct stat    stbuf;
  294. X    char        errstr[STR_BUF_SZ];
  295. X
  296. X    /* Check for validity of device node */
  297. X    if (stat(path, &stbuf) < 0) {
  298. X        sprintf(errstr, app_data.str_staterr, path);
  299. X        cd_fatal_popup(app_data.str_fatal, errstr);
  300. X        return(FALSE);
  301. X    }
  302. X    if ((stbuf.st_mode & S_IFMT) != S_IFCHR) {
  303. X        sprintf(errstr, app_data.str_noderr, path);
  304. X        cd_fatal_popup(app_data.str_fatal, errstr);
  305. X        return(FALSE);
  306. X    }
  307. X
  308. X    /* Check for another copy of xmcd running on the same
  309. X     * CD-ROM device.
  310. X     */
  311. X    if (!cd_devlock(path))
  312. X        return(FALSE);
  313. X
  314. X    /* Open CD-ROM device */
  315. X    if ((devfd = open(path, O_RDONLY)) < 0)
  316. X        return(FALSE);
  317. X
  318. X    /* Get passthrough interface device number */
  319. X    if (ioctl(devfd, B_GETDEV, &ptdev) < 0) {
  320. X        close(devfd);
  321. X        return(FALSE);
  322. X    }
  323. X
  324. X    close(devfd);
  325. X
  326. X    /* Make passthrough interface device node */
  327. X    sprintf(ptpath, "/tmp/.cdpt.%x", ptdev);
  328. X
  329. X    if (mknod(ptpath, S_IFCHR | 0700, ptdev) < 0) {
  330. X        if (errno == EEXIST) {
  331. X            unlink(ptpath);
  332. X
  333. X            if (mknod(ptpath, S_IFCHR | 0700, ptdev) < 0)
  334. X                return(FALSE);
  335. X        }
  336. X        else
  337. X            return(FALSE);
  338. X    }
  339. X
  340. X    /* Open passthrough device node */
  341. X    if ((fd = open(ptpath, O_RDONLY)) < 0)
  342. X        return(FALSE);
  343. X
  344. X    return(TRUE);
  345. X}
  346. X
  347. X
  348. X/*
  349. X * pthru_close
  350. X *    Close SCSI passthrough device
  351. X *
  352. X * Args:
  353. X *    Nothing.
  354. X *
  355. X * Return:
  356. X *    Nothing.
  357. X */
  358. Xvoid
  359. Xpthru_close(void)
  360. X{
  361. X    if (fd >= 0) {
  362. X        close(fd);
  363. X        fd = -1;
  364. X    }
  365. X
  366. X    if (ptpath[0] != '\0')
  367. X        unlink(ptpath);
  368. X}
  369. X
  370. X
  371. X/*
  372. X * pthru_vers
  373. X *    Return OS Interface Module version string
  374. X *
  375. X * Args:
  376. X *    Nothing.
  377. X *
  378. X * Return:
  379. X *    Module version text string.
  380. X */
  381. Xchar *
  382. Xpthru_vers(void)
  383. X{
  384. X    static char    vers[STR_BUF_SZ];
  385. X
  386. X    sprintf(vers, "OS Interface module v%s (for UNIX SVR4-PDI/x86)\n",
  387. X        OSI_VERS);
  388. X    return(vers);
  389. X}
  390. X
  391. X#endif    /* i386 */
  392. X
  393. X#ifdef MOTOROLA
  394. X/*
  395. X *   Motorola 88k UNIX SVR4 support
  396. X *   Contributing author: Mark Scott
  397. X *   E-mail: mscott@urbana.mcd.mot.com
  398. X *
  399. X *   Note: Audio CDs sometimes produce "Blank check" warnings on the console, 
  400. X *         just ignore these.
  401. X *
  402. X *   This software fragment contains code that interfaces xmcd to
  403. X *   the System V Release 4 operating system from Motorola.
  404. X *   The name "Motorola" is used here for identification purposes.
  405. X */
  406. X
  407. X
  408. X/*
  409. X * pthru_send
  410. X *    Build SCSI CDB and sent command to the device.
  411. X *
  412. X * Args:
  413. X *    opcode - SCSI command opcode
  414. X *    addr - The "address" portion of the SCSI CDB
  415. X *    buf - Pointer to data buffer
  416. X *    size - Number of bytes to transfer
  417. X *    rsvd - The "reserved" portion of the SCSI CDB
  418. X *    length - The "length" portion of the SCSI CDB
  419. X *    param - The "param" portion of the SCSI CDB
  420. X *    control - The "control" portion of the SCSI CDB
  421. X *    rw - Data transfer direction flag (READ_OP or WRITE_OP)
  422. X *
  423. X * Return:
  424. X *    TRUE - command completed successfully
  425. X *    FALSE - command failed
  426. X */
  427. Xbool_t
  428. Xpthru_send(
  429. X    byte_t        opcode,
  430. X    word32_t    addr,
  431. X    byte_t        *buf,
  432. X    word32_t    size,
  433. X    byte_t        rsvd,
  434. X    word32_t    length,
  435. X    byte_t        param,
  436. X    byte_t        control,
  437. X    byte_t        rw
  438. X)
  439. X{
  440. X    char            scsistat = '\0',
  441. X                *tmpbuf;
  442. X    int            cdb_l = 0,
  443. X                i;
  444. X    long            residual = 0L;
  445. X    unsigned long        errinfo  = 0L,
  446. X                ccode = 0L;
  447. X    struct scsi_pass    spass,
  448. X                *sp = &spass;
  449. X    struct ext_sense    sense,
  450. X                *esp = &sense;
  451. X
  452. X    if (fd < 0 || notrom_error)
  453. X        return(FALSE);
  454. X
  455. X    /* Zero out the struct */
  456. X    memset((void *) sp, (byte_t) 0, sizeof(struct scsi_pass));
  457. X    memset((void *) esp, (byte_t) 0, sizeof(struct ext_sense));
  458. X
  459. X    /* Setup passthru structure */
  460. X    sp->resid = &residual;
  461. X    sp->sense_data = esp;
  462. X    sp->status = &scsistat;
  463. X    sp->error_info = &errinfo;
  464. X    sp->ctlr_code = &ccode;
  465. X    sp->xfer_len = (unsigned long) size;
  466. X
  467. X    /* Align on a page boundary */
  468. X    tmpbuf = NULL;
  469. X    if (sp->xfer_len > 0) {
  470. X        tmpbuf = (char *) MEM_ALLOC(2 * NBPP);
  471. X        sp->data = tmpbuf;
  472. X        sp->data += NBPP - ((unsigned int) sp->data & (NBPP - 1));
  473. X    }
  474. X    else
  475. X        sp->data = tmpbuf;
  476. X
  477. X
  478. X    if (rw == WRITE_OP && sp->xfer_len > 0)    /* Write operation */
  479. X        memcpy(sp->data, buf, sp->xfer_len);
  480. X
  481. X    /* Set up SCSI CDB */
  482. X    switch (opcode & SPT_CDB_LEN) {
  483. X    case 0xa0:
  484. X    case 0xe0:
  485. X        /* 12-byte commands */
  486. X        cdb_l = 0xc0;
  487. X        sp->cdb[0] = opcode;
  488. X        sp->cdb[1] = param;
  489. X        sp->cdb[2] = (addr >> 24) & 0xff;
  490. X        sp->cdb[3] = (addr >> 16) & 0xff;
  491. X        sp->cdb[4] = (addr >> 8) & 0xff;
  492. X        sp->cdb[5] = (addr & 0xff);
  493. X        sp->cdb[6] = (length >> 24) & 0xff;
  494. X        sp->cdb[7] = (length >> 16) & 0xff;
  495. X        sp->cdb[8] = (length >> 8) & 0xff;
  496. X        sp->cdb[9] = length & 0xff;
  497. X        sp->cdb[10] = rsvd;
  498. X        sp->cdb[11] = control;
  499. X        break;
  500. X
  501. X    case 0xc0:
  502. X    case 0xd0:
  503. X    case 0x20:
  504. X    case 0x30:
  505. X    case 0x40:
  506. X        /* 10-byte commands */
  507. X        cdb_l = 0xa0;
  508. X        sp->cdb[0] = opcode;
  509. X        sp->cdb[1] = param;
  510. X        sp->cdb[2] = (addr >> 24) & 0xff;
  511. X        sp->cdb[3] = (addr >> 16) & 0xff;
  512. X        sp->cdb[4] = (addr >> 8) & 0xff;
  513. X        sp->cdb[5] = addr & 0xff;
  514. X        sp->cdb[6] = rsvd;
  515. X        sp->cdb[7] = (length >> 8) & 0xff;
  516. X        sp->cdb[8] = length & 0xff;
  517. X        sp->cdb[9] = control;
  518. X        break;
  519. X
  520. X    case 0x00:
  521. X    case 0x10:
  522. X        /* 6-byte commands */
  523. X        cdb_l = 0x60;
  524. X        sp->cdb[0] = opcode;
  525. X        sp->cdb[1] = param;
  526. X        sp->cdb[2] = (addr >> 8) & 0xff;
  527. X        sp->cdb[3] = addr & 0xff;
  528. X        sp->cdb[4] = length & 0xff;
  529. X        sp->cdb[5] = control;
  530. X        break;
  531. X
  532. X    default:
  533. X        if (app_data.scsierr_msg)
  534. X            fprintf(stderr, "0x%02x: Unknown SCSI opcode\n",
  535. X                opcode);
  536. X        if (tmpbuf != NULL)
  537. X            MEM_FREE(tmpbuf);
  538. X
  539. X        return(FALSE);
  540. X    }
  541. X
  542. X
  543. X    /* Check CDB length & flags */
  544. X
  545. X    if (!SPT_CHK_CDB_LEN(cdb_l))
  546. X        fprintf(stderr, "%d: invalid CDB length\n", cdb_l);
  547. X
  548. X    sp->flags = cdb_l | SPT_ERROR_QUIET;
  549. X    if (rw == READ_OP)
  550. X        sp->flags |= SPT_READ;
  551. X
  552. X    if (SPT_CHK_FLAGS(cdb_l))
  553. X        fprintf(stderr, "0x%2x: bad CDB flags\n", sp->flags);
  554. X
  555. X
  556. X    /* Send the command down via the "pass-through" interface */
  557. X    if (ioctl(fd, DKPASSTHRU, sp) < 0) {
  558. X        if (opcode != OP_S_TEST)
  559. X            perror("DKPASSTHRU ioctl failed");
  560. X
  561. X        if (tmpbuf != NULL)
  562. X            MEM_FREE(tmpbuf);
  563. X
  564. X        return(FALSE);
  565. X    }
  566. X
  567. X    if (*sp->error_info != SPTERR_NONE) {
  568. X        if (*sp->error_info != SPTERR_SCSI &&
  569. X            *sp->status != 2 &&
  570. X            opcode != OP_S_TEST) {
  571. X            /* Request Sense is done automatically by the driver */
  572. X
  573. X            fprintf(stderr, "%s %s\n",
  574. X                "xmcd SCSI command fault on",
  575. X                app_data.device);
  576. X
  577. X            fprintf(stderr,
  578. X                "00-01-02-03-04-05-06-07-08-09-10-11\n");
  579. X            for (i = 0; i < 12; i++)
  580. X                fprintf(stderr,"%02x ", sp->cdb[i]);
  581. X
  582. X            fprintf(stderr,
  583. X                "\nxfer_len=%d errinfo=%d ctlr_code=%d ",
  584. X                sp->xfer_len,
  585. X                *sp->error_info,
  586. X                *sp->ctlr_code);
  587. X            fprintf(stderr, "status=%d resid=%d\n",
  588. X                *sp->status,
  589. X                *sp->resid);
  590. X        }
  591. X        if (tmpbuf != NULL)
  592. X            MEM_FREE(tmpbuf);
  593. X
  594. X        return(FALSE);
  595. X    }
  596. X
  597. X    /* pass the data back to caller */
  598. X    if (sp->xfer_len > 0 && rw == READ_OP)    /* read operation */
  599. X        memcpy(buf, sp->data, sp->xfer_len);
  600. X
  601. X    if (tmpbuf != NULL)
  602. X        MEM_FREE(tmpbuf);
  603. X
  604. X    return(TRUE);
  605. X}
  606. X
  607. X
  608. X/*
  609. X * pthru_open
  610. X *    Open SCSI passthrough device
  611. X *
  612. X * Args:
  613. X *    path - device path name string
  614. X *
  615. X * Return:
  616. X *    TRUE - open successful
  617. X *    FALSE - open failed
  618. X */
  619. Xbool_t
  620. Xpthru_open(char *path)
  621. X{
  622. X    struct stat    stbuf;
  623. X    char        errstr[STR_BUF_SZ];
  624. X
  625. X    /* Check for validity of device node */
  626. X    if (stat(path, &stbuf) < 0) {
  627. X        sprintf(errstr, app_data.str_staterr, path);
  628. X        cd_fatal_popup(app_data.str_fatal, errstr);
  629. X        return(FALSE);
  630. X    }
  631. X    if ((stbuf.st_mode & S_IFMT) != S_IFCHR) {
  632. X        sprintf(errstr, app_data.str_noderr, path);
  633. X        cd_fatal_popup(app_data.str_fatal, errstr);
  634. X        return(FALSE);
  635. X    }
  636. X
  637. X    /* Check for another copy of xmcd running on the same CD-ROM device */
  638. X    if (!cd_devlock(path))
  639. X        return(FALSE);
  640. X
  641. X    /* Open CD-ROM device */
  642. X    if ((fd = open(path, O_RDONLY | O_NDELAY | O_EXCL)) < 0)
  643. X        return(FALSE);
  644. X
  645. X    return(TRUE);
  646. X}
  647. X
  648. X
  649. X/*
  650. X * pthru_close
  651. X *    Close SCSI passthrough device
  652. X *
  653. X * Args:
  654. X *    Nothing.
  655. X *
  656. X * Return:
  657. X *    Nothing.
  658. X */
  659. Xvoid
  660. Xpthru_close(void)
  661. X{
  662. X    if (fd >= 0) {
  663. X        close(fd);
  664. X        fd = -1;
  665. X    }
  666. X}
  667. X
  668. X
  669. X/*
  670. X * pthru_vers
  671. X *    Return OS Interface Module version string
  672. X *
  673. X * Args:
  674. X *    Nothing.
  675. X *
  676. X * Return:
  677. X *    Module version text string.
  678. X */
  679. Xchar *
  680. Xpthru_vers(void)
  681. X{
  682. X    static char    vers[STR_BUF_SZ];
  683. X
  684. X    sprintf(vers, "OS Interface module v%s (for UNIX SVR4-m88k)\n",
  685. X        OSI_VERS);
  686. X    return(vers);
  687. X}
  688. X
  689. X#endif    /* MOTOROLA */
  690. X
  691. X#else    /* !SVR4 || sun || SIMULATED_CDROM */
  692. X
  693. X#ifndef LINT
  694. Xbool_t            lib_svr4 = FALSE;
  695. X#endif
  696. X
  697. X#endif    /* SVR4 sun SIMULATED_CDROM */
  698. X
  699. END_OF_FILE
  700. if test 13997 -ne `wc -c <'lib_svr4.c'`; then
  701.     echo shar: \"'lib_svr4.c'\" unpacked with wrong size!
  702. fi
  703. # end of 'lib_svr4.c'
  704. fi
  705. if test -f 'lib_tosh.c' -a "${1}" != "-c" ; then 
  706.   echo shar: Will not clobber existing file \"'lib_tosh.c'\"
  707. else
  708. echo shar: Extracting \"'lib_tosh.c'\" \(9549 characters\)
  709. sed "s/^X//" >'lib_tosh.c' <<'END_OF_FILE'
  710. X/*
  711. X *   xmcd - Motif(tm) CD Audio Player
  712. X *
  713. X *   Copyright (C) 1993  Ti Kan
  714. X *   E-mail: ti@amb.org
  715. X *
  716. X *   This program is free software; you can redistribute it and/or modify
  717. X *   it under the terms of the GNU General Public License as published by
  718. X *   the Free Software Foundation; either version 2 of the License, or
  719. X *   (at your option) any later version.
  720. X *
  721. X *   This program is distributed in the hope that it will be useful,
  722. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  723. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  724. X *   GNU General Public License for more details.
  725. X *
  726. X *   You should have received a copy of the GNU General Public License
  727. X *   along with this program; if not, write to the Free Software
  728. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  729. X *
  730. X *   The name "Toshiba" is a trademark of Toshiba Corporation, and is
  731. X *   used here for identification purposes.  This software and its
  732. X *   author are not affiliated in any way with Toshiba.
  733. X *
  734. X */
  735. X#ifndef LINT
  736. Xstatic char *_lib_tosh_c_ident_ = "@(#)lib_tosh.c    1.34 93/09/28";
  737. X#endif
  738. X
  739. X#include <Xm/Xm.h>
  740. X#include "xmcd.h"
  741. X#include "util.h"
  742. X#include "cdfunc.h"
  743. X#include "lib_scsipt.h"
  744. X
  745. X#ifdef TOSHIBA
  746. X
  747. X
  748. X#ifndef LINT
  749. Xbool_t        lib_tosh = TRUE;
  750. X#endif
  751. X
  752. XSTATIC bool_t    tosh_audio_muted = FALSE;    /* Is audio muted? */
  753. X
  754. X
  755. X/*
  756. X * tosh_playaudio
  757. X *    Play audio function: send vendor-unique play audio command
  758. X *    to the drive.
  759. X *
  760. X * Args:
  761. X *    addr_fmt - Flags indicating which address formats are passed in
  762. X *    If ADDR_BLK, then:
  763. X *        start_addr - The logical block starting address
  764. X *        end_addr - The logical block ending address
  765. X *    If ADD_MSF, then:
  766. X *        start_msf - Pointer to the starting MSF address structure
  767. X *        end_msf - Pointer to the ending MSF address structure
  768. X *    If ADDR_TRKIDX, then:
  769. X *        trk - The starting track number
  770. X *        idx - The starting index number
  771. X *    If ADDR_OPTEND, then the ending address, if specified, can be
  772. X *    ignored if possible.
  773. X *
  774. X * Return:
  775. X *    TRUE - success
  776. X *    FALSE - failure
  777. X */
  778. X/*ARGSUSED*/
  779. Xbool_t
  780. Xtosh_playaudio(
  781. X    byte_t        addr_fmt,
  782. X    word32_t    start_addr,
  783. X    word32_t    end_addr,
  784. X    msf_t        *start_msf,
  785. X    msf_t        *end_msf,
  786. X    byte_t        trk,
  787. X    byte_t        idx
  788. X)
  789. X{
  790. X    bool_t        ret = FALSE;
  791. X    word32_t    addr = 0;
  792. X    taudio_arg_t    *p;
  793. X
  794. X    p = (taudio_arg_t *) &addr;
  795. X
  796. X    if (!ret && addr_fmt & ADDR_MSF) {
  797. X        if (addr_fmt & ADDR_OPTEND) {
  798. X            /* Position laser head at desired location
  799. X             * and start play.
  800. X             */
  801. X            p->addr_min = (byte_t) ltobcd(start_msf->min);
  802. X            p->addr_sec = (byte_t) ltobcd(start_msf->sec);
  803. X            p->addr_frame = (byte_t) ltobcd(start_msf->frame);
  804. X
  805. X            ret = pthru_send(
  806. X                OP_VT_AUDSRCH,
  807. X                addr, NULL, 0, 0, 0,
  808. X                0x1, 0x1 << 6, READ_OP
  809. X            );
  810. X        }
  811. X        else {
  812. X            /* Position laser head at desired location */
  813. X            p->addr_min = (byte_t) ltobcd(start_msf->min);
  814. X            p->addr_sec = (byte_t) ltobcd(start_msf->sec);
  815. X            p->addr_frame = (byte_t) ltobcd(start_msf->frame);
  816. X
  817. X            if (!pthru_send(OP_VT_AUDSRCH,
  818. X                    addr, NULL, 0, 0, 0,
  819. X                    0x0, 0x1 << 6, READ_OP))
  820. X                return(FALSE);
  821. X
  822. X            /* Specify end location, muting, and start play */
  823. X            p->addr_min = (byte_t) ltobcd(end_msf->min);
  824. X            p->addr_sec = (byte_t) ltobcd(end_msf->sec);
  825. X            p->addr_frame = (byte_t) ltobcd(end_msf->frame);
  826. X
  827. X            ret = pthru_send(
  828. X                OP_VT_AUDPLAY,
  829. X                addr, NULL, 0, 0, 0,
  830. X                (byte_t) (tosh_audio_muted ? 0x0 : 0x3),
  831. X                0x1 << 6, READ_OP
  832. X            );
  833. X        }
  834. X    }
  835. X
  836. X    if (!ret && addr_fmt & ADDR_BLK) {
  837. X        if (addr_fmt & ADDR_OPTEND) {
  838. X            /* Position laser head at desired location
  839. X             * and start play.
  840. X             */
  841. X            p->addr_logical = start_addr;
  842. X
  843. X            ret = pthru_send(
  844. X                OP_VT_AUDSRCH,
  845. X                addr, NULL, 0, 0, 0,
  846. X                0x1, 0x0, READ_OP
  847. X            );
  848. X        }
  849. X        else {
  850. X            /* Position laser head at desired location */
  851. X            p->addr_logical = start_addr;
  852. X
  853. X            if (!pthru_send(OP_VT_AUDSRCH,
  854. X                    addr, NULL, 0, 0, 0,
  855. X                    0x0, 0x0, READ_OP))
  856. X                return(FALSE);
  857. X
  858. X            /* Specify end location, muting, and start play */
  859. X            p->addr_logical = end_addr;
  860. X
  861. X            ret = pthru_send(
  862. X                OP_VT_AUDPLAY,
  863. X                addr, NULL, 0, 0, 0,
  864. X                (byte_t) (tosh_audio_muted ? 0x0 : 0x3),
  865. X                0x0, READ_OP
  866. X            );
  867. X        }
  868. X    }
  869. X
  870. X    return(ret);
  871. X}
  872. X
  873. X
  874. X/*
  875. X * tosh_pause_resume
  876. X *    Pause/resume function: send vendor-unique commands to implement
  877. X *    the pause and resume capability.
  878. X *
  879. X * Args:
  880. X *    resume - TRUE: resume, FALSE: pause
  881. X *
  882. X * Return:
  883. X *    TRUE - success
  884. X *    FALSE - failure
  885. X */
  886. Xbool_t
  887. Xtosh_pause_resume(bool_t resume)
  888. X{
  889. X    if (resume) {
  890. X        return(
  891. X            pthru_send(
  892. X                OP_VT_AUDPLAY, 0, NULL, 0, 0, 0,
  893. X                (byte_t) (tosh_audio_muted ? 0x0 : 0x3),
  894. X                0x3 << 6, READ_OP
  895. X            )
  896. X        );
  897. X    }
  898. X    else {
  899. X        return(
  900. X            pthru_send(
  901. X                OP_VT_STILL, 0, NULL, 0, 0, 0,
  902. X                0, 0, READ_OP
  903. X            )
  904. X        );
  905. X    }
  906. X}
  907. X
  908. X
  909. X/*
  910. X * tosh_get_playstatus
  911. X *    Send vendor-unique command to obtain current audio playback
  912. X *    status.
  913. X *
  914. X * Args:
  915. X *    s - Pointer to the curstat_t structure
  916. X *    audio_status - Address where a current status code (SCSI-2
  917. X *               style) is to be returned.
  918. X *
  919. X * Return:
  920. X *    TRUE - success
  921. X *    FALSE - failure
  922. X */
  923. Xbool_t
  924. Xtosh_get_playstatus(curstat_t *s, byte_t *audio_status)
  925. X{
  926. X    int        i,
  927. X            trkno,
  928. X            idxno;
  929. X    byte_t        buf[sizeof(tsubq_data_t)];
  930. X    tsubq_data_t    *d;
  931. X
  932. X
  933. X    memset(buf, (byte_t) 0, sizeof(buf));
  934. X
  935. X    if (!pthru_send(OP_VT_RDSUBQ, 0, buf, SZ_VT_RDSUBQ, 0, 0,
  936. X               SZ_VT_RDSUBQ, 0, READ_OP))
  937. X        return(FALSE);
  938. X
  939. X    d = (tsubq_data_t *)(void *) buf;
  940. X
  941. X    trkno = bcdtol((word32_t) d->trkno);
  942. X    if (s->cur_trk != trkno) {
  943. X        s->cur_trk = trkno;
  944. X        dpy_track(s);
  945. X    }
  946. X
  947. X    idxno = bcdtol((word32_t) d->idxno);
  948. X    if (s->cur_idx != idxno) {
  949. X        s->cur_idx = idxno;
  950. X        s->sav_iaddr = s->cur_tot_addr;
  951. X        dpy_index(s);
  952. X    }
  953. X
  954. X    if ((i = curtrk_pos(s)) >= 0)
  955. X        s->trkinfo[i].type = (d->trktype == 0) ? TYP_AUDIO : TYP_DATA;
  956. X
  957. X    s->cur_tot_min = (byte_t) bcdtol(d->abs_min);
  958. X    s->cur_tot_sec = (byte_t) bcdtol(d->abs_sec);
  959. X    s->cur_tot_frame = (byte_t) bcdtol(d->abs_frame);
  960. X    s->cur_trk_min = (byte_t) bcdtol(d->rel_min);
  961. X    s->cur_trk_sec = (byte_t) bcdtol(d->rel_sec);
  962. X    s->cur_trk_frame = (byte_t) bcdtol(d->rel_frame);
  963. X    msftoblk(
  964. X        s->cur_tot_min, s->cur_tot_sec, s->cur_tot_frame,
  965. X        &s->cur_tot_addr, MSF_OFFSET(s)
  966. X    );
  967. X    msftoblk(
  968. X        s->cur_trk_min, s->cur_trk_sec, s->cur_trk_frame,
  969. X        &s->cur_trk_addr, 0
  970. X    );
  971. X
  972. X    /* Translate Toshiba audio status to SCSI-2 audio status */
  973. X    switch (d->audio_status) {
  974. X    case TAUD_PLAYING:
  975. X        *audio_status = AUDIO_PLAYING;
  976. X        break;
  977. X
  978. X    case TAUD_SRCH_PAUSED:
  979. X    case TAUD_PAUSED:
  980. X        *audio_status = AUDIO_PAUSED;
  981. X        break;
  982. X
  983. X    case TAUD_OTHER:
  984. X        *audio_status = AUDIO_COMPLETED;
  985. X        break;
  986. X    }
  987. X
  988. X    return(TRUE);
  989. X}
  990. X
  991. X
  992. X/*
  993. X * tosh_get_toc
  994. X *    Send vendor-unique command to obtain the disc table-of-contents
  995. X *
  996. X * Args:
  997. X *    s - Pointer to the curstat_t structure, which contains the TOC
  998. X *        table to be updated.
  999. X *
  1000. X * Return:
  1001. X *    TRUE - success
  1002. X *    FALSE - failure
  1003. X */
  1004. Xbool_t
  1005. Xtosh_get_toc(curstat_t *s)
  1006. X{
  1007. X    int        i,
  1008. X            j;
  1009. X    byte_t        buf[SZ_VT_RDINFO];
  1010. X    tinfo_00_t    *t0;
  1011. X    tinfo_01_t    *t1;
  1012. X    tinfo_02_t    *t2;
  1013. X
  1014. X
  1015. X    memset(buf, (byte_t) 0, sizeof(buf));
  1016. X
  1017. X    /* Find number of tracks */
  1018. X    if (!pthru_send(OP_VT_RDINFO, 0, buf, SZ_VT_RDINFO,
  1019. X            0, 0, 0, 0, READ_OP))
  1020. X        return(FALSE);
  1021. X
  1022. X    t0 = (tinfo_00_t *) buf;
  1023. X    s->first_trk = (byte_t) bcdtol(t0->first_trk);
  1024. X    s->last_trk = (byte_t) bcdtol(t0->last_trk);
  1025. X
  1026. X    /* Get the starting position of each track */
  1027. X    for (i = 0, j = (int) s->first_trk; j <= (int) s->last_trk; i++, j++) {
  1028. X        memset(buf, (byte_t) 0, sizeof(buf));
  1029. X
  1030. X        if (!pthru_send(OP_VT_RDINFO, ltobcd(j) << 24,
  1031. X                buf, SZ_VT_RDINFO, 0, 0, 2,
  1032. X                0, READ_OP))
  1033. X            return(FALSE);
  1034. X
  1035. X        t2 = (tinfo_02_t *) buf;
  1036. X
  1037. X        s->trkinfo[i].trkno = j;
  1038. X        s->trkinfo[i].min = (byte_t) bcdtol(t2->min);
  1039. X        s->trkinfo[i].sec = (byte_t) bcdtol(t2->sec);
  1040. X        s->trkinfo[i].frame = (byte_t) bcdtol(t2->frame);
  1041. X        msftoblk(
  1042. X            s->trkinfo[i].min,
  1043. X            s->trkinfo[i].sec,
  1044. X            s->trkinfo[i].frame,
  1045. X            &s->trkinfo[i].addr,
  1046. X            MSF_OFFSET(s)
  1047. X        );
  1048. X    }
  1049. X    s->tot_trks = (byte_t) i;
  1050. X
  1051. X    memset(buf, (byte_t) 0, sizeof(buf));
  1052. X
  1053. X    /* Get the lead out track position */
  1054. X    if (!pthru_send(OP_VT_RDINFO, 0,
  1055. X            buf, SZ_VT_RDINFO, 0, 0, 1,
  1056. X            0, READ_OP))
  1057. X        return(FALSE);
  1058. X
  1059. X    t1 = (tinfo_01_t *) buf;
  1060. X
  1061. X    s->trkinfo[i].trkno = LEAD_OUT_TRACK;
  1062. X    s->tot_min = s->trkinfo[i].min = (byte_t) bcdtol(t1->min);
  1063. X    s->tot_sec = s->trkinfo[i].sec = (byte_t) bcdtol(t1->sec);
  1064. X    s->tot_frame = s->trkinfo[i].frame = (byte_t) bcdtol(t1->frame);
  1065. X    msftoblk(
  1066. X        s->trkinfo[i].min,
  1067. X        s->trkinfo[i].sec,
  1068. X        s->trkinfo[i].frame,
  1069. X        &s->trkinfo[i].addr,
  1070. X        MSF_OFFSET(s)
  1071. X    );
  1072. X    s->tot_addr = s->trkinfo[i].addr;
  1073. X
  1074. X    return(TRUE);
  1075. X}
  1076. X
  1077. X
  1078. X/*
  1079. X * tosh_mute
  1080. X *    Send vendor-unique command to mute/unmute the audio
  1081. X *
  1082. X * Args:
  1083. X *    mute - TRUE: mute audio, FALSE: unmute audio
  1084. X *
  1085. X * Return:
  1086. X *    TRUE - success
  1087. X *    FALSE - failure
  1088. X */
  1089. Xbool_t
  1090. Xtosh_mute(bool_t mute)
  1091. X{
  1092. X    curstat_t    *s = curstat_addr();
  1093. X
  1094. X    if (tosh_audio_muted != mute) {
  1095. X        switch (s->mode) {
  1096. X        case M_NODISC:
  1097. X        case M_STOP:
  1098. X        case M_PAUSE:
  1099. X            break;
  1100. X
  1101. X        default:
  1102. X            if (!pthru_send(OP_VT_AUDPLAY, 0, NULL, 0, 0, 0,
  1103. X                    (byte_t) (mute ? 0x0 : 0x3),
  1104. X                    0x3 << 6, READ_OP))
  1105. X                return(FALSE);
  1106. X            break;
  1107. X        }
  1108. X
  1109. X        tosh_audio_muted = mute;
  1110. X    }
  1111. X
  1112. X    return(TRUE);
  1113. X}
  1114. X
  1115. X
  1116. X/*
  1117. X * tosh_eject
  1118. X *    Send vendor-unique command to eject the caddy
  1119. X *
  1120. X * Args:
  1121. X *    Nothing.
  1122. X *
  1123. X * Return:
  1124. X *    TRUE - success
  1125. X *    FALSE - failure
  1126. X */
  1127. Xbool_t
  1128. Xtosh_eject(void)
  1129. X{
  1130. X    return(pthru_send(OP_VT_EJECT, 0, NULL, 0, 0, 0, 1, 0, READ_OP));
  1131. X}
  1132. X
  1133. X
  1134. X/*
  1135. X * tosh_init
  1136. X *    Initialize the vendor-unique support module
  1137. X *
  1138. X * Args:
  1139. X *    Nothing.
  1140. X *
  1141. X * Return:
  1142. X *    Nothing.
  1143. X */
  1144. Xvoid
  1145. Xtosh_init(void)
  1146. X{
  1147. X    /* Do nothing */
  1148. X}
  1149. X
  1150. X
  1151. X/*
  1152. X * tosh_halt
  1153. X *    Shut down the vendor-unique support module
  1154. X *
  1155. X * Args:
  1156. X *    Nothing.
  1157. X *
  1158. X * Return:
  1159. X *    Nothing.
  1160. X */
  1161. Xvoid
  1162. Xtosh_halt(void)
  1163. X{
  1164. X    /* Do nothing */
  1165. X}
  1166. X
  1167. X#else    /* !TOSHIBA */
  1168. X
  1169. X#ifndef LINT
  1170. Xbool_t        lib_tosh = FALSE;
  1171. X#endif
  1172. X
  1173. X#endif    /* TOSHIBA */
  1174. X
  1175. END_OF_FILE
  1176. if test 9549 -ne `wc -c <'lib_tosh.c'`; then
  1177.     echo shar: \"'lib_tosh.c'\" unpacked with wrong size!
  1178. fi
  1179. # end of 'lib_tosh.c'
  1180. fi
  1181. if test -f 'main.c' -a "${1}" != "-c" ; then 
  1182.   echo shar: Will not clobber existing file \"'main.c'\"
  1183. else
  1184. echo shar: Extracting \"'main.c'\" \(2954 characters\)
  1185. sed "s/^X//" >'main.c' <<'END_OF_FILE'
  1186. X/*
  1187. X *   xmcd - Motif(tm) CD Audio Player
  1188. X *
  1189. X *   Copyright (C) 1993  Ti Kan
  1190. X *   E-mail: ti@amb.org
  1191. X *
  1192. X *   This program is free software; you can redistribute it and/or modify
  1193. X *   it under the terms of the GNU General Public License as published by
  1194. X *   the Free Software Foundation; either version 2 of the License, or
  1195. X *   (at your option) any later version.
  1196. X *
  1197. X *   This program is distributed in the hope that it will be useful,
  1198. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1199. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1200. X *   GNU General Public License for more details.
  1201. X *
  1202. X *   You should have received a copy of the GNU General Public License
  1203. X *   along with this program; if not, write to the Free Software
  1204. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1205. X *
  1206. X */
  1207. X#ifndef LINT
  1208. Xstatic char *_main_c_ident_ = "@(#)main.c    1.30 93/09/28";
  1209. X#endif
  1210. X
  1211. X#include <Xm/Xm.h>
  1212. X#include "xmcd.h"
  1213. X#include "resource.h"
  1214. X#include "util.h"
  1215. X#include "widget.h"
  1216. X#include "cdfunc.h"
  1217. X#include "cdlib.h"
  1218. X
  1219. X
  1220. X/* Global data */
  1221. Xchar            *progname;    /* The path name we are invoked with */
  1222. Xbool_t            exit_flag;    /* Flag indicating end of application */
  1223. XAppData            app_data;    /* Options data */
  1224. Xwidgets_t        widgets;    /* Holder of all widgets */
  1225. Xpixmaps_t        pixmaps;    /* Holder of all pixmaps */
  1226. X
  1227. X/* Data global to this module only */
  1228. XSTATIC curstat_t    status;        /* Current CD player status */
  1229. X
  1230. X
  1231. X/*
  1232. X * main
  1233. X *    The main function
  1234. X */
  1235. Xvoid
  1236. Xmain(int argc, char **argv)
  1237. X{
  1238. X    XtAppContext    app;
  1239. X    XEvent        ev;
  1240. X
  1241. X    /* Initialize variables */
  1242. X    progname = argv[0];
  1243. X    exit_flag = FALSE;
  1244. X
  1245. X    /* Handle some signals */
  1246. X    signal(SIGINT, onsig);
  1247. X    signal(SIGHUP, onsig);
  1248. X    signal(SIGTERM, onsig);
  1249. X
  1250. X    /* Initialize X toolkit */
  1251. X    widgets.toplevel = XtVaAppInitialize(
  1252. X        &app,
  1253. X        "XMcd",
  1254. X        options, XtNumber(options),
  1255. X        &argc, argv,
  1256. X        fallbacks,
  1257. X        XmNmappedWhenManaged, False,
  1258. X        NULL
  1259. X    );
  1260. X
  1261. X    /* Get application options */
  1262. X    XtVaGetApplicationResources(
  1263. X        widgets.toplevel,
  1264. X        (XtPointer) &app_data,
  1265. X        resources,
  1266. X        XtNumber(resources),
  1267. X        NULL
  1268. X    );
  1269. X        
  1270. X    /* Check command line for unknown arguments */
  1271. X    if (argc > 1) {
  1272. X        usage(argc, argv);
  1273. X        exit(1);
  1274. X    }
  1275. X
  1276. X    /* Create all widgets */
  1277. X    create_widgets(&widgets);
  1278. X
  1279. X    /* Configure resources before realizing widgets */
  1280. X    pre_realize_config(&widgets);
  1281. X
  1282. X    /* Display widgets */
  1283. X    XtRealizeWidget(widgets.toplevel);
  1284. X
  1285. X    /* Configure resources after realizing widgets */
  1286. X    post_realize_config(&widgets, &pixmaps);
  1287. X
  1288. X    /* Register callback routines */
  1289. X    register_callbacks(&widgets, &status);
  1290. X
  1291. X    /* Initialize and start various subsystems */
  1292. X    cd_init(&status);
  1293. X    cd_start(&status);
  1294. X
  1295. X    /* Make the main window visible */
  1296. X    XtMapWidget(widgets.toplevel);
  1297. X
  1298. X    /* Event processing loop */
  1299. X    while (!exit_flag) {
  1300. X        XtAppNextEvent(app, &ev);
  1301. X        XtDispatchEvent(&ev);
  1302. X    }
  1303. X
  1304. X    exit(0);
  1305. X}
  1306. X
  1307. X
  1308. X/*
  1309. X * curstat_addr
  1310. X *    Return the address of the curstat_t structure.
  1311. X *
  1312. X * Args:
  1313. X *    Nothing.
  1314. X *
  1315. X * Return:
  1316. X *    Nothing.
  1317. X */
  1318. Xcurstat_t *
  1319. Xcurstat_addr(void)
  1320. X{
  1321. X    return(&status);
  1322. X}
  1323. END_OF_FILE
  1324. if test 2954 -ne `wc -c <'main.c'`; then
  1325.     echo shar: \"'main.c'\" unpacked with wrong size!
  1326. fi
  1327. # end of 'main.c'
  1328. fi
  1329. if test -f 'util.c' -a "${1}" != "-c" ; then 
  1330.   echo shar: Will not clobber existing file \"'util.c'\"
  1331. else
  1332. echo shar: Extracting \"'util.c'\" \(8022 characters\)
  1333. sed "s/^X//" >'util.c' <<'END_OF_FILE'
  1334. X/*
  1335. X *   xmcd - Motif(tm) CD Audio Player
  1336. X *
  1337. X *   Copyright (C) 1993  Ti Kan
  1338. X *   E-mail: ti@amb.org
  1339. X *
  1340. X *   This program is free software; you can redistribute it and/or modify
  1341. X *   it under the terms of the GNU General Public License as published by
  1342. X *   the Free Software Foundation; either version 2 of the License, or
  1343. X *   (at your option) any later version.
  1344. X *
  1345. X *   This program is distributed in the hope that it will be useful,
  1346. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1347. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1348. X *   GNU General Public License for more details.
  1349. X *
  1350. X *   You should have received a copy of the GNU General Public License
  1351. X *   along with this program; if not, write to the Free Software
  1352. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1353. X *
  1354. X */
  1355. X#ifndef LINT
  1356. Xstatic char *_util_c_ident_ = "@(#)util.c    1.38 93/09/28";
  1357. X#endif
  1358. X
  1359. X#include "xmcd.h"
  1360. X#include "util.h"
  1361. X
  1362. Xextern char        *progname;
  1363. Xextern AppData        app_data;
  1364. X
  1365. X
  1366. X/*
  1367. X * usage
  1368. X *    Display command line usage syntax
  1369. X *
  1370. X * Args:
  1371. X *    argc, argv
  1372. X *
  1373. X * Return:
  1374. X *    Nothing.
  1375. X */
  1376. Xvoid
  1377. Xusage(int argc, char **argv)
  1378. X{
  1379. X    int    i;
  1380. X
  1381. X    fprintf(stderr, "%s\n", app_data.str_badopts);
  1382. X    for (i = 1; i < argc; i++)
  1383. X        fprintf(stderr, "%s ", argv[i]);
  1384. X
  1385. X    fprintf(stderr,
  1386. X        "\n\n%s %s %s %s\n",
  1387. X        app_data.str_usage,
  1388. X        progname,
  1389. X        "[-dev path1]",
  1390. X        "[-dbdir path2]");
  1391. X
  1392. X    fprintf(stderr,
  1393. X        "\nwhere,\n%s\n%s\n",
  1394. X        "\tpath1\tCD-ROM device file path",
  1395. X        "\tpath2\tCD database directory path");
  1396. X     fprintf(stderr,
  1397. X        "\nStandard Xt Intrinsics and Motif options are supported.\n");
  1398. X}
  1399. X
  1400. X
  1401. X/*
  1402. X * ltobcd
  1403. X *    32-bit integer to BCD conversion routine
  1404. X *
  1405. X * Args:
  1406. X *    n - 32-bit integer
  1407. X *
  1408. X * Return:
  1409. X *    BCD representation of n
  1410. X */
  1411. Xsword32_t
  1412. Xltobcd(sword32_t n)
  1413. X{
  1414. X    return((n % 10) | ((n / 10) << 4));
  1415. X}
  1416. X
  1417. X
  1418. X/*
  1419. X * bcdtol
  1420. X *    BCD to 32-bit integer conversion routine
  1421. X *
  1422. X * Args:
  1423. X *    n - BCD value
  1424. X *
  1425. X * Return:
  1426. X *    integer representation of n
  1427. X */
  1428. Xsword32_t
  1429. Xbcdtol(sword32_t n)
  1430. X{
  1431. X    return((n & 0x0f) + ((n >> 4) * 10));
  1432. X}
  1433. X
  1434. X
  1435. X/*
  1436. X * stob
  1437. X *    String to boolean conversion routine
  1438. X *
  1439. X * Args:
  1440. X *    s - text string "True", "true", "False" or "false"
  1441. X *
  1442. X * Return:
  1443. X *    Boolean value representing the string
  1444. X */
  1445. Xbool_t
  1446. Xstob(char *s)
  1447. X{
  1448. X    if (strcmp(s, "True") == 0 || strcmp(s, "true") == 0 ||
  1449. X        strcmp(s, "TRUE") == 0)
  1450. X        return(TRUE);
  1451. X
  1452. X    return(FALSE);
  1453. X}
  1454. X
  1455. X
  1456. X/*
  1457. X * basename
  1458. X *    Return the basename of a file path
  1459. X *
  1460. X * Args:
  1461. X *    path - The file path string
  1462. X *
  1463. X * Return:
  1464. X *    The basename string
  1465. X */
  1466. Xchar *
  1467. Xbasename(char *path)
  1468. X{
  1469. X    char    *p;
  1470. X
  1471. X    if ((p = strrchr(path, '/')) == NULL)
  1472. X        return(path);
  1473. X    
  1474. X    return(p + 1);
  1475. X}
  1476. X
  1477. X
  1478. X/*
  1479. X * dirname
  1480. X *    Return the dirname of a file path
  1481. X *
  1482. X * Args:
  1483. X *    path - The file path string
  1484. X *
  1485. X * Return:
  1486. X *    The dirname string
  1487. X */
  1488. Xchar *
  1489. Xdirname(char *path)
  1490. X{
  1491. X    char        *p;
  1492. X    static char    buf[FILE_PATH_SZ];
  1493. X
  1494. X    if ((int) strlen(path) >= FILE_PATH_SZ)
  1495. X        /* Error: path name too long */
  1496. X        return(NULL);
  1497. X
  1498. X    strcpy(buf, path);
  1499. X
  1500. X    if ((p = strrchr(buf, '/')) == NULL)
  1501. X        return(buf);
  1502. X    
  1503. X    *p = '\0';
  1504. X    return(buf);
  1505. X}
  1506. X
  1507. X
  1508. X/*
  1509. X * homedir
  1510. X *    Return the home directory path of a user given the uid
  1511. X *
  1512. X * Args:
  1513. X *    uid - The uid of the user
  1514. X *
  1515. X * Return:
  1516. X *    The home directory path name string
  1517. X */
  1518. Xchar *
  1519. Xhomedir(uid_t uid)
  1520. X{
  1521. X    struct passwd    *pw;
  1522. X    char        *cp;
  1523. X
  1524. X    /* Get home directory from the password file if possible */
  1525. X    if ((pw = getpwuid(uid)) != NULL)
  1526. X        return(pw->pw_dir);
  1527. X
  1528. X    /* Try the HOME environment variable */
  1529. X    if ((cp = getenv("HOME")) != NULL)
  1530. X        return(cp);
  1531. X
  1532. X    /* If we still can't get the home directory, just set it to the
  1533. X     * current directory (shrug).
  1534. X     */
  1535. X    return(".");
  1536. X}
  1537. X
  1538. X
  1539. X/*
  1540. X * isqrt
  1541. X *    Fast integer-based square root routine
  1542. X *
  1543. X * Args:
  1544. X *    n - The integer value whose square-root is to be taken
  1545. X *
  1546. X * Return:
  1547. X *    Resultant square-root integer value
  1548. X */
  1549. Xint
  1550. Xisqrt(int n)
  1551. X{
  1552. X    int    a, b, c, as, bs;
  1553. X
  1554. X    a = 1;
  1555. X    b = 1;
  1556. X    while (a <= n) {
  1557. X        a = a << 2;
  1558. X        b = b << 1;
  1559. X    }
  1560. X    as = 0;
  1561. X    bs = 0;
  1562. X    while (b > 1 && n > 0) {
  1563. X        a = a >> 2;
  1564. X        b = b >> 1;
  1565. X        c = n - (as | a);
  1566. X        if (c >= 0) {
  1567. X            n = c;
  1568. X            as |= (a << 1);
  1569. X            bs |= b;
  1570. X        }
  1571. X        as >>= 1;
  1572. X    }
  1573. X
  1574. X    return(bs);
  1575. X}
  1576. X
  1577. X
  1578. X/*
  1579. X * blktomsf
  1580. X *    CD logical block to MSF conversion routine
  1581. X *
  1582. X * Args:
  1583. X *    blk - The logical block address
  1584. X *    ret_min - Minute (return)
  1585. X *    ret_sec - Second (return)
  1586. X *    ret_frame - Frame (return)
  1587. X *    offset - Additional logical block address offset
  1588. X *
  1589. X * Return:
  1590. X *    Nothing.
  1591. X */
  1592. Xvoid
  1593. Xblktomsf(word32_t blk, byte_t *ret_min, byte_t *ret_sec, byte_t *ret_frame,
  1594. X     word32_t offset)
  1595. X{
  1596. X    *ret_min = (blk + offset) / FRAME_PER_SEC / 60;
  1597. X    *ret_sec = ((blk + offset) / FRAME_PER_SEC) % 60;
  1598. X    *ret_frame = (blk + offset) % FRAME_PER_SEC;
  1599. X}
  1600. X
  1601. X
  1602. X/*
  1603. X * msftoblk
  1604. X *    CD MSF to logical block conversion routine
  1605. X *
  1606. X * Args:
  1607. X *    min - Minute
  1608. X *    sec - Second
  1609. X *    frame - Frame
  1610. X *    ret_blk - The logical block address (return)
  1611. X *    offset - Additional logical block address offset
  1612. X *
  1613. X * Return:
  1614. X *    Nothing.
  1615. X */
  1616. Xvoid
  1617. Xmsftoblk(byte_t min, byte_t sec, byte_t frame, word32_t *ret_blk,
  1618. X     word32_t offset)
  1619. X{
  1620. X    *ret_blk = FRAME_PER_SEC * (min * 60 + sec) + frame - offset;
  1621. X}
  1622. X
  1623. X
  1624. X/*
  1625. X * bswap16
  1626. X *    16-bit little-endian to big-endian byte-swap routine.
  1627. X *    On a big-endian system architecture this routines has no effect.
  1628. X *
  1629. X * Args:
  1630. X *    x - The data to be swapped
  1631. X *
  1632. X * Return:
  1633. X *    The swapped data.
  1634. X */
  1635. Xword16_t
  1636. Xbswap16(word16_t x)
  1637. X{
  1638. X#if BYTE_ORDER == LITTLE_ENDIAN
  1639. X    word16_t    ret;
  1640. X
  1641. X    ret  = (x & 0x00ff) << 8;
  1642. X    ret |= (word16_t) (x & 0xff00) >> 8;
  1643. X    return(ret);
  1644. X#else
  1645. X    return(x);
  1646. X#endif
  1647. X}
  1648. X
  1649. X
  1650. X/*
  1651. X * bswap24
  1652. X *    24-bit little-endian to big-endian byte-swap routine.
  1653. X *    On a big-endian system architecture this routines has no effect.
  1654. X *
  1655. X * Args:
  1656. X *    x - The data to be swapped
  1657. X *
  1658. X * Return:
  1659. X *    The swapped data.
  1660. X */
  1661. Xword32_t
  1662. Xbswap24(word32_t x)
  1663. X{
  1664. X#if BYTE_ORDER == LITTLE_ENDIAN
  1665. X    word32_t    ret;
  1666. X
  1667. X    ret  = (x & 0x0000ff) << 16;
  1668. X    ret |= (x & 0x00ff00);
  1669. X    ret |= (x & 0xff0000) >> 16;
  1670. X    return(ret);
  1671. X#else
  1672. X    return(x);
  1673. X#endif
  1674. X}
  1675. X
  1676. X
  1677. X/*
  1678. X * bswap32
  1679. X *    32-bit little-endian to big-endian byte-swap routine.
  1680. X *    On a big-endian system architecture this routines has no effect.
  1681. X *
  1682. X * Args:
  1683. X *    x - The data to be swapped
  1684. X *
  1685. X * Return:
  1686. X *    The swapped data.
  1687. X */
  1688. Xword32_t
  1689. Xbswap32(word32_t x)
  1690. X{
  1691. X#if BYTE_ORDER == LITTLE_ENDIAN
  1692. X    word32_t    ret;
  1693. X
  1694. X    ret  = (x & 0x000000ff) << 24;
  1695. X    ret |= (x & 0x0000ff00) << 8;
  1696. X    ret |= (x & 0x00ff0000) >> 8;
  1697. X    ret |= (x & 0xff000000) >> 24;
  1698. X    return(ret);
  1699. X#else
  1700. X    return(x);
  1701. X#endif
  1702. X}
  1703. X
  1704. X
  1705. X/*
  1706. X * lswap16
  1707. X *    16-bit big-endian to little-endian byte-swap routine.
  1708. X *    On a little-endian system architecture this routines has no effect.
  1709. X *
  1710. X * Args:
  1711. X *    x - The data to be swapped
  1712. X *
  1713. X * Return:
  1714. X *    The swapped data.
  1715. X */
  1716. Xword16_t
  1717. Xlswap16(word16_t x)
  1718. X{
  1719. X#if BYTE_ORDER == LITTLE_ENDIAN
  1720. X    return(x);
  1721. X#else
  1722. X    word16_t    ret;
  1723. X
  1724. X    ret  = (x & 0x00ff) << 8;
  1725. X    ret |= (word16_t) (x & 0xff00) >> 8;
  1726. X    return(ret);
  1727. X#endif
  1728. X}
  1729. X
  1730. X
  1731. X/*
  1732. X * lswap24
  1733. X *    24-bit big-endian to little-endian byte-swap routine.
  1734. X *    On a little-endian system architecture this routines has no effect.
  1735. X *
  1736. X * Args:
  1737. X *    x - The data to be swapped
  1738. X *
  1739. X * Return:
  1740. X *    The swapped data.
  1741. X */
  1742. Xword32_t
  1743. Xlswap24(word32_t x)
  1744. X{
  1745. X#if BYTE_ORDER == LITTLE_ENDIAN
  1746. X    return(x);
  1747. X#else
  1748. X    word32_t    ret;
  1749. X
  1750. X    ret  = (x & 0x0000ff) << 16;
  1751. X    ret |= (x & 0x00ff00);
  1752. X    ret |= (x & 0xff0000) >> 16;
  1753. X    return(ret);
  1754. X#endif
  1755. X}
  1756. X
  1757. X
  1758. X/*
  1759. X * lswap32
  1760. X *    32-bit big-endian to little-endian byte-swap routine.
  1761. X *    On a little-endian system architecture this routines has no effect.
  1762. X *
  1763. X * Args:
  1764. X *    x - The data to be swapped
  1765. X *
  1766. X * Return:
  1767. X *    The swapped data.
  1768. X */
  1769. Xword32_t
  1770. Xlswap32(word32_t x)
  1771. X{
  1772. X#if BYTE_ORDER == LITTLE_ENDIAN
  1773. X    return(x);
  1774. X#else
  1775. X    word32_t    ret;
  1776. X
  1777. X    ret  = (x & 0x000000ff) << 24;
  1778. X    ret |= (x & 0x0000ff00) << 8;
  1779. X    ret |= (x & 0x00ff0000) >> 8;
  1780. X    ret |= (x & 0xff000000) >> 24;
  1781. X    return(ret);
  1782. X#endif
  1783. X}
  1784. X
  1785. X
  1786. X/* Debugging routines */
  1787. X
  1788. X#ifdef DEBUG
  1789. X
  1790. XFILE *
  1791. Xdbfile_open(char *path)
  1792. X{
  1793. X    return(fopen(path, "w"));
  1794. X}
  1795. X
  1796. Xint
  1797. Xdbfile_close(FILE *fp)
  1798. X{
  1799. X    return(fclose(fp));
  1800. X}
  1801. X
  1802. Xvoid
  1803. Xdbfile_dump(FILE *fp, char *title, byte_t data[], int len)
  1804. X{
  1805. X    int    i;
  1806. X
  1807. X    if (fp == NULL)
  1808. X        return;
  1809. X
  1810. X    fprintf(fp, "\n%s", title);
  1811. X
  1812. X    for (i = 0; i < len; i++) {
  1813. X        if (i % 16 == 0)
  1814. X            fprintf(fp, "\n%03u:\t", i);
  1815. X
  1816. X        fprintf(fp, "%02x  ", data[i]);
  1817. X    }
  1818. X    fprintf(fp, "\n");
  1819. X}
  1820. X
  1821. X#endif    /* DEBUG */
  1822. X
  1823. END_OF_FILE
  1824. if test 8022 -ne `wc -c <'util.c'`; then
  1825.     echo shar: \"'util.c'\" unpacked with wrong size!
  1826. fi
  1827. # end of 'util.c'
  1828. fi
  1829. if test ! -d 'bitmaps' ; then
  1830.     echo shar: Creating directory \"'bitmaps'\"
  1831.     mkdir 'bitmaps'
  1832. fi
  1833. if test -f 'bitmaps/ab.xbm' -a "${1}" != "-c" ; then 
  1834.   echo shar: Will not clobber existing file \"'bitmaps/ab.xbm'\"
  1835. else
  1836. echo shar: Extracting \"'bitmaps/ab.xbm'\" \(1186 characters\)
  1837. sed "s/^X//" >'bitmaps/ab.xbm' <<'END_OF_FILE'
  1838. X/*
  1839. X *   xmcd - Motif(tm) CD Audio Player
  1840. X *
  1841. X *   Copyright (C) 1993  Ti Kan
  1842. X *   E-mail: ti@amb.org
  1843. X *
  1844. X *   This program is free software; you can redistribute it and/or modify
  1845. X *   it under the terms of the GNU General Public License as published by
  1846. X *   the Free Software Foundation; either version 2 of the License, or
  1847. X *   (at your option) any later version.
  1848. X *
  1849. X *   This program is distributed in the hope that it will be useful,
  1850. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1851. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1852. X *   GNU General Public License for more details.
  1853. X *
  1854. X *   You should have received a copy of the GNU General Public License
  1855. X *   along with this program; if not, write to the Free Software
  1856. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1857. X *
  1858. X */
  1859. X#ifndef LINT
  1860. Xstatic char *_ab_xbm_ident_ = "@(#)ab.xbm    1.8 93/09/28";
  1861. X#endif
  1862. X
  1863. X#define ab_width 16
  1864. X#define ab_height 16
  1865. Xstatic unsigned char ab_bits[] = {
  1866. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02,
  1867. X   0x03, 0xc6, 0xf3, 0xcf, 0xf3, 0xcf, 0x03, 0xc6, 0x00, 0x02, 0x00, 0x00,
  1868. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  1869. X};
  1870. END_OF_FILE
  1871. if test 1186 -ne `wc -c <'bitmaps/ab.xbm'`; then
  1872.     echo shar: \"'bitmaps/ab.xbm'\" unpacked with wrong size!
  1873. fi
  1874. # end of 'bitmaps/ab.xbm'
  1875. fi
  1876. if test -f 'bitmaps/btnlbl.xbm' -a "${1}" != "-c" ; then 
  1877.   echo shar: Will not clobber existing file \"'bitmaps/btnlbl.xbm'\"
  1878. else
  1879. echo shar: Extracting \"'bitmaps/btnlbl.xbm'\" \(1206 characters\)
  1880. sed "s/^X//" >'bitmaps/btnlbl.xbm' <<'END_OF_FILE'
  1881. X/*
  1882. X *   xmcd - Motif(tm) CD Audio Player
  1883. X *
  1884. X *   Copyright (C) 1993  Ti Kan
  1885. X *   E-mail: ti@amb.org
  1886. X *
  1887. X *   This program is free software; you can redistribute it and/or modify
  1888. X *   it under the terms of the GNU General Public License as published by
  1889. X *   the Free Software Foundation; either version 2 of the License, or
  1890. X *   (at your option) any later version.
  1891. X *
  1892. X *   This program is distributed in the hope that it will be useful,
  1893. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1894. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1895. X *   GNU General Public License for more details.
  1896. X *
  1897. X *   You should have received a copy of the GNU General Public License
  1898. X *   along with this program; if not, write to the Free Software
  1899. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1900. X *
  1901. X */
  1902. X#ifndef LINT
  1903. Xstatic char *_btnlbl_xbm_ident_ = "@(#)btnlbl.xbm    1.6 93/09/28";
  1904. X#endif
  1905. X
  1906. X#define btnlbl_width 16
  1907. X#define btnlbl_height 16
  1908. Xstatic unsigned char btnlbl_bits[] = {
  1909. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x04, 0x20, 0x84, 0x21,
  1910. X   0x44, 0x22, 0x44, 0x22, 0xc4, 0x23, 0x44, 0x22, 0x44, 0x22, 0x04, 0x20,
  1911. X   0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  1912. X};
  1913. END_OF_FILE
  1914. if test 1206 -ne `wc -c <'bitmaps/btnlbl.xbm'`; then
  1915.     echo shar: \"'bitmaps/btnlbl.xbm'\" unpacked with wrong size!
  1916. fi
  1917. # end of 'bitmaps/btnlbl.xbm'
  1918. fi
  1919. if test -f 'bitmaps/dbprog.xbm' -a "${1}" != "-c" ; then 
  1920.   echo shar: Will not clobber existing file \"'bitmaps/dbprog.xbm'\"
  1921. else
  1922. echo shar: Extracting \"'bitmaps/dbprog.xbm'\" \(1806 characters\)
  1923. sed "s/^X//" >'bitmaps/dbprog.xbm' <<'END_OF_FILE'
  1924. X/*
  1925. X *   xmcd - Motif(tm) CD Audio Player
  1926. X *
  1927. X *   Copyright (C) 1993  Ti Kan
  1928. X *   E-mail: ti@amb.org
  1929. X *
  1930. X *   This program is free software; you can redistribute it and/or modify
  1931. X *   it under the terms of the GNU General Public License as published by
  1932. X *   the Free Software Foundation; either version 2 of the License, or
  1933. X *   (at your option) any later version.
  1934. X *
  1935. X *   This program is distributed in the hope that it will be useful,
  1936. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1937. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1938. X *   GNU General Public License for more details.
  1939. X *
  1940. X *   You should have received a copy of the GNU General Public License
  1941. X *   along with this program; if not, write to the Free Software
  1942. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1943. X *
  1944. X */
  1945. X#ifndef LINT
  1946. Xstatic char *_dbprog_xbm_ident_ = "@(#)dbprog.xbm    1.6 93/09/28";
  1947. X#endif
  1948. X
  1949. X#define dbprog_width 32
  1950. X#define dbprog_height 32
  1951. Xstatic unsigned char dbprog_bits[] = {
  1952. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x03,
  1953. X   0x40, 0x00, 0x00, 0x02, 0x40, 0xff, 0xff, 0x02, 0x40, 0x01, 0x80, 0x02,
  1954. X   0x40, 0xc1, 0x83, 0x02, 0x40, 0x41, 0x82, 0x02, 0x40, 0xc1, 0x83, 0x02,
  1955. X   0x40, 0x01, 0x80, 0x02, 0x40, 0x01, 0x80, 0x02, 0x40, 0x21, 0x84, 0x02,
  1956. X   0x40, 0xe1, 0x87, 0x02, 0x40, 0x01, 0x80, 0x02, 0x40, 0x01, 0x80, 0x02,
  1957. X   0x40, 0xff, 0xff, 0x02, 0x40, 0x01, 0x80, 0x02, 0x40, 0xc1, 0x83, 0x02,
  1958. X   0x40, 0x41, 0x82, 0x02, 0x40, 0xc1, 0x83, 0x02, 0x40, 0x01, 0x80, 0x02,
  1959. X   0x40, 0x01, 0x80, 0x02, 0x40, 0x21, 0x84, 0x02, 0x40, 0xe1, 0x87, 0x02,
  1960. X   0x40, 0x01, 0x80, 0x02, 0x40, 0x01, 0x80, 0x02, 0x40, 0xff, 0xff, 0x02,
  1961. X   0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0xc0, 0xff, 0xff, 0x03,
  1962. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  1963. X};
  1964. END_OF_FILE
  1965. if test 1806 -ne `wc -c <'bitmaps/dbprog.xbm'`; then
  1966.     echo shar: \"'bitmaps/dbprog.xbm'\" unpacked with wrong size!
  1967. fi
  1968. # end of 'bitmaps/dbprog.xbm'
  1969. fi
  1970. if test -f 'bitmaps/eject.xbm' -a "${1}" != "-c" ; then 
  1971.   echo shar: Will not clobber existing file \"'bitmaps/eject.xbm'\"
  1972. else
  1973. echo shar: Extracting \"'bitmaps/eject.xbm'\" \(1201 characters\)
  1974. sed "s/^X//" >'bitmaps/eject.xbm' <<'END_OF_FILE'
  1975. X/*
  1976. X *   xmcd - Motif(tm) CD Audio Player
  1977. X *
  1978. X *   Copyright (C) 1993  Ti Kan
  1979. X *   E-mail: ti@amb.org
  1980. X *
  1981. X *   This program is free software; you can redistribute it and/or modify
  1982. X *   it under the terms of the GNU General Public License as published by
  1983. X *   the Free Software Foundation; either version 2 of the License, or
  1984. X *   (at your option) any later version.
  1985. X *
  1986. X *   This program is distributed in the hope that it will be useful,
  1987. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  1988. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1989. X *   GNU General Public License for more details.
  1990. X *
  1991. X *   You should have received a copy of the GNU General Public License
  1992. X *   along with this program; if not, write to the Free Software
  1993. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1994. X *
  1995. X */
  1996. X#ifndef LINT
  1997. Xstatic char *_eject_xbm_ident_ = "@(#)eject.xbm    1.6 93/09/28";
  1998. X#endif
  1999. X
  2000. X#define eject_width 16
  2001. X#define eject_height 16
  2002. Xstatic unsigned char eject_bits[] = {
  2003. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xc0, 0x03, 0xe0, 0x07,
  2004. X   0xf0, 0x0f, 0xf8, 0x1f, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f,
  2005. X   0xfc, 0x3f, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00
  2006. X};
  2007. END_OF_FILE
  2008. if test 1201 -ne `wc -c <'bitmaps/eject.xbm'`; then
  2009.     echo shar: \"'bitmaps/eject.xbm'\" unpacked with wrong size!
  2010. fi
  2011. # end of 'bitmaps/eject.xbm'
  2012. fi
  2013. if test -f 'bitmaps/ff.xbm' -a "${1}" != "-c" ; then 
  2014.   echo shar: Will not clobber existing file \"'bitmaps/ff.xbm'\"
  2015. else
  2016. echo shar: Extracting \"'bitmaps/ff.xbm'\" \(1186 characters\)
  2017. sed "s/^X//" >'bitmaps/ff.xbm' <<'END_OF_FILE'
  2018. X/*
  2019. X *   xmcd - Motif(tm) CD Audio Player
  2020. X *
  2021. X *   Copyright (C) 1993  Ti Kan
  2022. X *   E-mail: ti@amb.org
  2023. X *
  2024. X *   This program is free software; you can redistribute it and/or modify
  2025. X *   it under the terms of the GNU General Public License as published by
  2026. X *   the Free Software Foundation; either version 2 of the License, or
  2027. X *   (at your option) any later version.
  2028. X *
  2029. X *   This program is distributed in the hope that it will be useful,
  2030. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2031. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2032. X *   GNU General Public License for more details.
  2033. X *
  2034. X *   You should have received a copy of the GNU General Public License
  2035. X *   along with this program; if not, write to the Free Software
  2036. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2037. X *
  2038. X */
  2039. X#ifndef LINT
  2040. Xstatic char *_ff_xbm_ident_ = "@(#)ff.xbm    1.6 93/09/28";
  2041. X#endif
  2042. X
  2043. X#define ff_width 16
  2044. X#define ff_height 16
  2045. Xstatic unsigned char ff_bits[] = {
  2046. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x02, 0x18, 0x06, 0x38, 0x0e,
  2047. X   0x78, 0x1e, 0xf8, 0x3e, 0xf8, 0x3e, 0x78, 0x1e, 0x38, 0x0e, 0x18, 0x06,
  2048. X   0x08, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2049. X};
  2050. END_OF_FILE
  2051. if test 1186 -ne `wc -c <'bitmaps/ff.xbm'`; then
  2052.     echo shar: \"'bitmaps/ff.xbm'\" unpacked with wrong size!
  2053. fi
  2054. # end of 'bitmaps/ff.xbm'
  2055. fi
  2056. if test -f 'bitmaps/help.xbm' -a "${1}" != "-c" ; then 
  2057.   echo shar: Will not clobber existing file \"'bitmaps/help.xbm'\"
  2058. else
  2059. echo shar: Extracting \"'bitmaps/help.xbm'\" \(1196 characters\)
  2060. sed "s/^X//" >'bitmaps/help.xbm' <<'END_OF_FILE'
  2061. X/*
  2062. X *   xmcd - Motif(tm) CD Audio Player
  2063. X *
  2064. X *   Copyright (C) 1993  Ti Kan
  2065. X *   E-mail: ti@amb.org
  2066. X *
  2067. X *   This program is free software; you can redistribute it and/or modify
  2068. X *   it under the terms of the GNU General Public License as published by
  2069. X *   the Free Software Foundation; either version 2 of the License, or
  2070. X *   (at your option) any later version.
  2071. X *
  2072. X *   This program is distributed in the hope that it will be useful,
  2073. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2074. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2075. X *   GNU General Public License for more details.
  2076. X *
  2077. X *   You should have received a copy of the GNU General Public License
  2078. X *   along with this program; if not, write to the Free Software
  2079. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2080. X *
  2081. X */
  2082. X#ifndef LINT
  2083. Xstatic char *_help_xbm_ident_ = "@(#)help.xbm    1.3 93/09/28";
  2084. X#endif
  2085. X
  2086. X#define help_width 16
  2087. X#define help_height 16
  2088. Xstatic unsigned char help_bits[] = {
  2089. X   0x00, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x30, 0x03, 0x18, 0x06, 0x18, 0x06,
  2090. X   0x00, 0x06, 0x00, 0x03, 0xc0, 0x01, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00,
  2091. X   0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00
  2092. X};
  2093. END_OF_FILE
  2094. if test 1196 -ne `wc -c <'bitmaps/help.xbm'`; then
  2095.     echo shar: \"'bitmaps/help.xbm'\" unpacked with wrong size!
  2096. fi
  2097. # end of 'bitmaps/help.xbm'
  2098. fi
  2099. if test -f 'bitmaps/keypad.xbm' -a "${1}" != "-c" ; then 
  2100.   echo shar: Will not clobber existing file \"'bitmaps/keypad.xbm'\"
  2101. else
  2102. echo shar: Extracting \"'bitmaps/keypad.xbm'\" \(1206 characters\)
  2103. sed "s/^X//" >'bitmaps/keypad.xbm' <<'END_OF_FILE'
  2104. X/*
  2105. X *   xmcd - Motif(tm) CD Audio Player
  2106. X *
  2107. X *   Copyright (C) 1993  Ti Kan
  2108. X *   E-mail: ti@amb.org
  2109. X *
  2110. X *   This program is free software; you can redistribute it and/or modify
  2111. X *   it under the terms of the GNU General Public License as published by
  2112. X *   the Free Software Foundation; either version 2 of the License, or
  2113. X *   (at your option) any later version.
  2114. X *
  2115. X *   This program is distributed in the hope that it will be useful,
  2116. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2117. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2118. X *   GNU General Public License for more details.
  2119. X *
  2120. X *   You should have received a copy of the GNU General Public License
  2121. X *   along with this program; if not, write to the Free Software
  2122. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2123. X *
  2124. X */
  2125. X#ifndef LINT
  2126. Xstatic char *_keypad_xbm_ident_ = "@(#)keypad.xbm    1.6 93/09/28";
  2127. X#endif
  2128. X
  2129. X#define keypad_width 16
  2130. X#define keypad_height 16
  2131. Xstatic unsigned char keypad_bits[] = {
  2132. X   0x00, 0x00, 0xf8, 0x1f, 0x48, 0x12, 0x48, 0x12, 0xf8, 0x1f, 0x48, 0x12,
  2133. X   0x48, 0x12, 0xf8, 0x1f, 0x48, 0x12, 0x48, 0x12, 0xf8, 0x1f, 0x48, 0x10,
  2134. X   0x48, 0x10, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00
  2135. X};
  2136. END_OF_FILE
  2137. if test 1206 -ne `wc -c <'bitmaps/keypad.xbm'`; then
  2138.     echo shar: \"'bitmaps/keypad.xbm'\" unpacked with wrong size!
  2139. fi
  2140. # end of 'bitmaps/keypad.xbm'
  2141. fi
  2142. if test -f 'bitmaps/lock.xbm' -a "${1}" != "-c" ; then 
  2143.   echo shar: Will not clobber existing file \"'bitmaps/lock.xbm'\"
  2144. else
  2145. echo shar: Extracting \"'bitmaps/lock.xbm'\" \(1196 characters\)
  2146. sed "s/^X//" >'bitmaps/lock.xbm' <<'END_OF_FILE'
  2147. X/*
  2148. X *   xmcd - Motif(tm) CD Audio Player
  2149. X *
  2150. X *   Copyright (C) 1993  Ti Kan
  2151. X *   E-mail: ti@amb.org
  2152. X *
  2153. X *   This program is free software; you can redistribute it and/or modify
  2154. X *   it under the terms of the GNU General Public License as published by
  2155. X *   the Free Software Foundation; either version 2 of the License, or
  2156. X *   (at your option) any later version.
  2157. X *
  2158. X *   This program is distributed in the hope that it will be useful,
  2159. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2160. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2161. X *   GNU General Public License for more details.
  2162. X *
  2163. X *   You should have received a copy of the GNU General Public License
  2164. X *   along with this program; if not, write to the Free Software
  2165. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2166. X *
  2167. X */
  2168. X#ifndef LINT
  2169. Xstatic char *_lock_xbm_ident_ = "@(#)lock.xbm    1.7 93/09/28";
  2170. X#endif
  2171. X
  2172. X#define lock_width 16
  2173. X#define lock_height 16
  2174. Xstatic unsigned char lock_bits[] = {
  2175. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x20, 0x04, 0x20, 0x04,
  2176. X   0x20, 0x04, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f,
  2177. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2178. X};
  2179. END_OF_FILE
  2180. if test 1196 -ne `wc -c <'bitmaps/lock.xbm'`; then
  2181.     echo shar: \"'bitmaps/lock.xbm'\" unpacked with wrong size!
  2182. fi
  2183. # end of 'bitmaps/lock.xbm'
  2184. fi
  2185. if test -f 'bitmaps/logo.xbm' -a "${1}" != "-c" ; then 
  2186.   echo shar: Will not clobber existing file \"'bitmaps/logo.xbm'\"
  2187. else
  2188. echo shar: Extracting \"'bitmaps/logo.xbm'\" \(2795 characters\)
  2189. sed "s/^X//" >'bitmaps/logo.xbm' <<'END_OF_FILE'
  2190. X/*
  2191. X *   xmcd - Motif(tm) CD Audio Player
  2192. X *
  2193. X *   Copyright (C) 1993  Ti Kan
  2194. X *   E-mail: ti@amb.org
  2195. X *
  2196. X *   This program is free software; you can redistribute it and/or modify
  2197. X *   it under the terms of the GNU General Public License as published by
  2198. X *   the Free Software Foundation; either version 2 of the License, or
  2199. X *   (at your option) any later version.
  2200. X *
  2201. X *   This program is distributed in the hope that it will be useful,
  2202. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2203. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2204. X *   GNU General Public License for more details.
  2205. X *
  2206. X *   You should have received a copy of the GNU General Public License
  2207. X *   along with this program; if not, write to the Free Software
  2208. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2209. X *
  2210. X */
  2211. X#ifndef LINT
  2212. Xstatic char *_logo_xbm_ident_ = "@(#)logo.xbm    1.6 93/09/28";
  2213. X#endif
  2214. X
  2215. X#define logo_width 48
  2216. X#define logo_height 48
  2217. Xstatic unsigned char logo_bits[] = {
  2218. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2219. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2220. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2221. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2222. X   0x00, 0x00, 0x63, 0xa2, 0x23, 0xe6, 0x00, 0x9f, 0x94, 0xb6, 0x54, 0x49,
  2223. X   0x00, 0x91, 0x90, 0xaa, 0x54, 0x41, 0x00, 0x91, 0x94, 0xaa, 0x73, 0x49,
  2224. X   0x00, 0x11, 0x63, 0xa2, 0x50, 0x46, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00,
  2225. X   0x00, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00,
  2226. X   0xfc, 0x91, 0x0f, 0xff, 0xc3, 0x3f, 0x02, 0x90, 0x88, 0x00, 0x22, 0x40,
  2227. X   0x01, 0x90, 0x48, 0x00, 0x12, 0x80, 0xe1, 0x90, 0x48, 0x00, 0x12, 0x86,
  2228. X   0x11, 0x91, 0x48, 0xfc, 0x13, 0x89, 0x11, 0x91, 0x48, 0x02, 0x10, 0x89,
  2229. X   0x11, 0x91, 0x48, 0xfc, 0x10, 0x89, 0x11, 0x91, 0x48, 0x00, 0x11, 0xf9,
  2230. X   0x11, 0x91, 0x48, 0x00, 0x12, 0x01, 0x11, 0x91, 0x88, 0x00, 0x12, 0xf9,
  2231. X   0x11, 0x91, 0x08, 0x3f, 0x12, 0x89, 0x11, 0x91, 0x08, 0x40, 0x12, 0x89,
  2232. X   0x11, 0x91, 0xc8, 0x3f, 0x12, 0x89, 0xe1, 0x90, 0x48, 0x00, 0x12, 0x86,
  2233. X   0x01, 0x90, 0x48, 0x00, 0x12, 0x80, 0x02, 0x90, 0x48, 0x00, 0x21, 0x40,
  2234. X   0xfc, 0x9f, 0xcf, 0xff, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2235. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2236. X   0x27, 0xd7, 0x49, 0x20, 0xe9, 0x64, 0xa9, 0x90, 0x54, 0x50, 0x29, 0x95,
  2237. X   0xa9, 0x96, 0x54, 0x50, 0x29, 0x95, 0xa9, 0x94, 0x5c, 0x70, 0x29, 0x95,
  2238. X   0x27, 0x97, 0xd4, 0x51, 0xe6, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2239. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2240. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2241. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2242. X};
  2243. END_OF_FILE
  2244. if test 2795 -ne `wc -c <'bitmaps/logo.xbm'`; then
  2245.     echo shar: \"'bitmaps/logo.xbm'\" unpacked with wrong size!
  2246. fi
  2247. # end of 'bitmaps/logo.xbm'
  2248. fi
  2249. if test -f 'bitmaps/nextidx.xbm' -a "${1}" != "-c" ; then 
  2250.   echo shar: Will not clobber existing file \"'bitmaps/nextidx.xbm'\"
  2251. else
  2252. echo shar: Extracting \"'bitmaps/nextidx.xbm'\" \(1211 characters\)
  2253. sed "s/^X//" >'bitmaps/nextidx.xbm' <<'END_OF_FILE'
  2254. X/*
  2255. X *   xmcd - Motif(tm) CD Audio Player
  2256. X *
  2257. X *   Copyright (C) 1993  Ti Kan
  2258. X *   E-mail: ti@amb.org
  2259. X *
  2260. X *   This program is free software; you can redistribute it and/or modify
  2261. X *   it under the terms of the GNU General Public License as published by
  2262. X *   the Free Software Foundation; either version 2 of the License, or
  2263. X *   (at your option) any later version.
  2264. X *
  2265. X *   This program is distributed in the hope that it will be useful,
  2266. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2267. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2268. X *   GNU General Public License for more details.
  2269. X *
  2270. X *   You should have received a copy of the GNU General Public License
  2271. X *   along with this program; if not, write to the Free Software
  2272. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2273. X *
  2274. X */
  2275. X#ifndef LINT
  2276. Xstatic char *_nextidx_xbm_ident_ = "@(#)nextidx.xbm    1.8 93/09/28";
  2277. X#endif
  2278. X
  2279. X#define nextidx_width 16
  2280. X#define nextidx_height 16
  2281. Xstatic unsigned char nextidx_bits[] = {
  2282. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x18, 0x18, 0x18, 0x38, 0x00,
  2283. X   0x78, 0x00, 0xf8, 0x18, 0xf8, 0x18, 0x78, 0x18, 0x38, 0x18, 0x18, 0x18,
  2284. X   0x08, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2285. X};
  2286. END_OF_FILE
  2287. if test 1211 -ne `wc -c <'bitmaps/nextidx.xbm'`; then
  2288.     echo shar: \"'bitmaps/nextidx.xbm'\" unpacked with wrong size!
  2289. fi
  2290. # end of 'bitmaps/nextidx.xbm'
  2291. fi
  2292. if test -f 'bitmaps/nexttrk.xbm' -a "${1}" != "-c" ; then 
  2293.   echo shar: Will not clobber existing file \"'bitmaps/nexttrk.xbm'\"
  2294. else
  2295. echo shar: Extracting \"'bitmaps/nexttrk.xbm'\" \(1211 characters\)
  2296. sed "s/^X//" >'bitmaps/nexttrk.xbm' <<'END_OF_FILE'
  2297. X/*
  2298. X *   xmcd - Motif(tm) CD Audio Player
  2299. X *
  2300. X *   Copyright (C) 1993  Ti Kan
  2301. X *   E-mail: ti@amb.org
  2302. X *
  2303. X *   This program is free software; you can redistribute it and/or modify
  2304. X *   it under the terms of the GNU General Public License as published by
  2305. X *   the Free Software Foundation; either version 2 of the License, or
  2306. X *   (at your option) any later version.
  2307. X *
  2308. X *   This program is distributed in the hope that it will be useful,
  2309. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2310. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2311. X *   GNU General Public License for more details.
  2312. X *
  2313. X *   You should have received a copy of the GNU General Public License
  2314. X *   along with this program; if not, write to the Free Software
  2315. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2316. X *
  2317. X */
  2318. X#ifndef LINT
  2319. Xstatic char *_nexttrk_xbm_ident_ = "@(#)nexttrk.xbm    1.7 93/09/28";
  2320. X#endif
  2321. X
  2322. X#define nexttrk_width 16
  2323. X#define nexttrk_height 16
  2324. Xstatic unsigned char nexttrk_bits[] = {
  2325. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x82, 0x60, 0x86, 0x61, 0x8e, 0x63,
  2326. X   0x9e, 0x67, 0xbe, 0x6f, 0xbe, 0x6f, 0x9e, 0x67, 0x8e, 0x63, 0x86, 0x61,
  2327. X   0x82, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2328. X};
  2329. END_OF_FILE
  2330. if test 1211 -ne `wc -c <'bitmaps/nexttrk.xbm'`; then
  2331.     echo shar: \"'bitmaps/nexttrk.xbm'\" unpacked with wrong size!
  2332. fi
  2333. # end of 'bitmaps/nexttrk.xbm'
  2334. fi
  2335. if test -f 'bitmaps/playpaus.xbm' -a "${1}" != "-c" ; then 
  2336.   echo shar: Will not clobber existing file \"'bitmaps/playpaus.xbm'\"
  2337. else
  2338. echo shar: Extracting \"'bitmaps/playpaus.xbm'\" \(1420 characters\)
  2339. sed "s/^X//" >'bitmaps/playpaus.xbm' <<'END_OF_FILE'
  2340. X/*
  2341. X *   xmcd - Motif(tm) CD Audio Player
  2342. X *
  2343. X *   Copyright (C) 1993  Ti Kan
  2344. X *   E-mail: ti@amb.org
  2345. X *
  2346. X *   This program is free software; you can redistribute it and/or modify
  2347. X *   it under the terms of the GNU General Public License as published by
  2348. X *   the Free Software Foundation; either version 2 of the License, or
  2349. X *   (at your option) any later version.
  2350. X *
  2351. X *   This program is distributed in the hope that it will be useful,
  2352. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2353. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2354. X *   GNU General Public License for more details.
  2355. X *
  2356. X *   You should have received a copy of the GNU General Public License
  2357. X *   along with this program; if not, write to the Free Software
  2358. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2359. X *
  2360. X */
  2361. X#ifndef LINT
  2362. Xstatic char *_playpaus_xbm_ident_ = "@(#)playpaus.xbm    1.6 93/09/28";
  2363. X#endif
  2364. X
  2365. X#define playpause_width 32
  2366. X#define playpause_height 16
  2367. Xstatic unsigned char playpause_bits[] = {
  2368. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2369. X   0x06, 0x00, 0xc0, 0x71, 0x1e, 0x00, 0xc0, 0x71, 0x7e, 0x00, 0xc0, 0x71,
  2370. X   0xfe, 0x01, 0xc0, 0x71, 0xfe, 0x07, 0xc0, 0x71, 0xfe, 0x07, 0xc0, 0x71,
  2371. X   0xfe, 0x01, 0xc0, 0x71, 0x7e, 0x00, 0xc0, 0x71, 0x1e, 0x00, 0xc0, 0x71,
  2372. X   0x06, 0x00, 0xc0, 0x71, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  2373. X   0x00, 0x00, 0x00, 0x00
  2374. X};
  2375. END_OF_FILE
  2376. if test 1420 -ne `wc -c <'bitmaps/playpaus.xbm'`; then
  2377.     echo shar: \"'bitmaps/playpaus.xbm'\" unpacked with wrong size!
  2378. fi
  2379. # end of 'bitmaps/playpaus.xbm'
  2380. fi
  2381. if test -f 'bitmaps/poweroff.xbm' -a "${1}" != "-c" ; then 
  2382.   echo shar: Will not clobber existing file \"'bitmaps/poweroff.xbm'\"
  2383. else
  2384. echo shar: Extracting \"'bitmaps/poweroff.xbm'\" \(1216 characters\)
  2385. sed "s/^X//" >'bitmaps/poweroff.xbm' <<'END_OF_FILE'
  2386. X/*
  2387. X *   xmcd - Motif(tm) CD Audio Player
  2388. X *
  2389. X *   Copyright (C) 1993  Ti Kan
  2390. X *   E-mail: ti@amb.org
  2391. X *
  2392. X *   This program is free software; you can redistribute it and/or modify
  2393. X *   it under the terms of the GNU General Public License as published by
  2394. X *   the Free Software Foundation; either version 2 of the License, or
  2395. X *   (at your option) any later version.
  2396. X *
  2397. X *   This program is distributed in the hope that it will be useful,
  2398. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2399. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2400. X *   GNU General Public License for more details.
  2401. X *
  2402. X *   You should have received a copy of the GNU General Public License
  2403. X *   along with this program; if not, write to the Free Software
  2404. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2405. X *
  2406. X */
  2407. X#ifndef LINT
  2408. Xstatic char *_poweroff_xbm_ident_ = "@(#)poweroff.xbm    1.7 93/09/28";
  2409. X#endif
  2410. X
  2411. X#define poweroff_width 16
  2412. X#define poweroff_height 16
  2413. Xstatic unsigned char poweroff_bits[] = {
  2414. X   0x00, 0x00, 0x00, 0x00, 0xfe, 0x18, 0xfe, 0x10, 0xfe, 0x10, 0xfe, 0x10,
  2415. X   0xfe, 0x10, 0x82, 0x00, 0x82, 0x38, 0x82, 0x44, 0x82, 0x44, 0x82, 0x44,
  2416. X   0xfe, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2417. X};
  2418. END_OF_FILE
  2419. if test 1216 -ne `wc -c <'bitmaps/poweroff.xbm'`; then
  2420.     echo shar: \"'bitmaps/poweroff.xbm'\" unpacked with wrong size!
  2421. fi
  2422. # end of 'bitmaps/poweroff.xbm'
  2423. fi
  2424. if test -f 'bitmaps/previdx.xbm' -a "${1}" != "-c" ; then 
  2425.   echo shar: Will not clobber existing file \"'bitmaps/previdx.xbm'\"
  2426. else
  2427. echo shar: Extracting \"'bitmaps/previdx.xbm'\" \(1211 characters\)
  2428. sed "s/^X//" >'bitmaps/previdx.xbm' <<'END_OF_FILE'
  2429. X/*
  2430. X *   xmcd - Motif(tm) CD Audio Player
  2431. X *
  2432. X *   Copyright (C) 1993  Ti Kan
  2433. X *   E-mail: ti@amb.org
  2434. X *
  2435. X *   This program is free software; you can redistribute it and/or modify
  2436. X *   it under the terms of the GNU General Public License as published by
  2437. X *   the Free Software Foundation; either version 2 of the License, or
  2438. X *   (at your option) any later version.
  2439. X *
  2440. X *   This program is distributed in the hope that it will be useful,
  2441. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2442. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2443. X *   GNU General Public License for more details.
  2444. X *
  2445. X *   You should have received a copy of the GNU General Public License
  2446. X *   along with this program; if not, write to the Free Software
  2447. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2448. X *
  2449. X */
  2450. X#ifndef LINT
  2451. Xstatic char *_previdx_xbm_ident_ = "@(#)previdx.xbm    1.8 93/09/28";
  2452. X#endif
  2453. X
  2454. X#define previdx_width 16
  2455. X#define previdx_height 16
  2456. Xstatic unsigned char previdx_bits[] = {
  2457. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x10, 0x18, 0x18, 0x00, 0x1c,
  2458. X   0x00, 0x1e, 0x18, 0x1f, 0x18, 0x1f, 0x18, 0x1e, 0x18, 0x1c, 0x18, 0x18,
  2459. X   0x18, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2460. X};
  2461. END_OF_FILE
  2462. if test 1211 -ne `wc -c <'bitmaps/previdx.xbm'`; then
  2463.     echo shar: \"'bitmaps/previdx.xbm'\" unpacked with wrong size!
  2464. fi
  2465. # end of 'bitmaps/previdx.xbm'
  2466. fi
  2467. if test -f 'bitmaps/prevtrk.xbm' -a "${1}" != "-c" ; then 
  2468.   echo shar: Will not clobber existing file \"'bitmaps/prevtrk.xbm'\"
  2469. else
  2470. echo shar: Extracting \"'bitmaps/prevtrk.xbm'\" \(1211 characters\)
  2471. sed "s/^X//" >'bitmaps/prevtrk.xbm' <<'END_OF_FILE'
  2472. X/*
  2473. X *   xmcd - Motif(tm) CD Audio Player
  2474. X *
  2475. X *   Copyright (C) 1993  Ti Kan
  2476. X *   E-mail: ti@amb.org
  2477. X *
  2478. X *   This program is free software; you can redistribute it and/or modify
  2479. X *   it under the terms of the GNU General Public License as published by
  2480. X *   the Free Software Foundation; either version 2 of the License, or
  2481. X *   (at your option) any later version.
  2482. X *
  2483. X *   This program is distributed in the hope that it will be useful,
  2484. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2485. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2486. X *   GNU General Public License for more details.
  2487. X *
  2488. X *   You should have received a copy of the GNU General Public License
  2489. X *   along with this program; if not, write to the Free Software
  2490. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2491. X *
  2492. X */
  2493. X#ifndef LINT
  2494. Xstatic char *_prevtrk_xbm_ident_ = "@(#)prevtrk.xbm    1.7 93/09/28";
  2495. X#endif
  2496. X
  2497. X#define prevtrk_width 16
  2498. X#define prevtrk_height 16
  2499. Xstatic unsigned char prevtrk_bits[] = {
  2500. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x41, 0x86, 0x61, 0xc6, 0x71,
  2501. X   0xe6, 0x79, 0xf6, 0x7d, 0xf6, 0x7d, 0xe6, 0x79, 0xc6, 0x71, 0x86, 0x61,
  2502. X   0x06, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2503. X};
  2504. END_OF_FILE
  2505. if test 1211 -ne `wc -c <'bitmaps/prevtrk.xbm'`; then
  2506.     echo shar: \"'bitmaps/prevtrk.xbm'\" unpacked with wrong size!
  2507. fi
  2508. # end of 'bitmaps/prevtrk.xbm'
  2509. fi
  2510. if test -f 'bitmaps/repeat.xbm' -a "${1}" != "-c" ; then 
  2511.   echo shar: Will not clobber existing file \"'bitmaps/repeat.xbm'\"
  2512. else
  2513. echo shar: Extracting \"'bitmaps/repeat.xbm'\" \(1206 characters\)
  2514. sed "s/^X//" >'bitmaps/repeat.xbm' <<'END_OF_FILE'
  2515. X/*
  2516. X *   xmcd - Motif(tm) CD Audio Player
  2517. X *
  2518. X *   Copyright (C) 1993  Ti Kan
  2519. X *   E-mail: ti@amb.org
  2520. X *
  2521. X *   This program is free software; you can redistribute it and/or modify
  2522. X *   it under the terms of the GNU General Public License as published by
  2523. X *   the Free Software Foundation; either version 2 of the License, or
  2524. X *   (at your option) any later version.
  2525. X *
  2526. X *   This program is distributed in the hope that it will be useful,
  2527. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2528. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2529. X *   GNU General Public License for more details.
  2530. X *
  2531. X *   You should have received a copy of the GNU General Public License
  2532. X *   along with this program; if not, write to the Free Software
  2533. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2534. X *
  2535. X */
  2536. X#ifndef LINT
  2537. Xstatic char *_repeat_xbm_ident_ = "@(#)repeat.xbm    1.7 93/09/28";
  2538. X#endif
  2539. X
  2540. X#define repeat_width 16
  2541. X#define repeat_height 16
  2542. Xstatic unsigned char repeat_bits[] = {
  2543. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xf8, 0x13,
  2544. X   0x0c, 0x31, 0x04, 0x20, 0x04, 0x20, 0x8c, 0x30, 0xc8, 0x1f, 0x80, 0x00,
  2545. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2546. X};
  2547. END_OF_FILE
  2548. if test 1206 -ne `wc -c <'bitmaps/repeat.xbm'`; then
  2549.     echo shar: \"'bitmaps/repeat.xbm'\" unpacked with wrong size!
  2550. fi
  2551. # end of 'bitmaps/repeat.xbm'
  2552. fi
  2553. if test -f 'bitmaps/rew.xbm' -a "${1}" != "-c" ; then 
  2554.   echo shar: Will not clobber existing file \"'bitmaps/rew.xbm'\"
  2555. else
  2556. echo shar: Extracting \"'bitmaps/rew.xbm'\" \(1191 characters\)
  2557. sed "s/^X//" >'bitmaps/rew.xbm' <<'END_OF_FILE'
  2558. X/*
  2559. X *   xmcd - Motif(tm) CD Audio Player
  2560. X *
  2561. X *   Copyright (C) 1993  Ti Kan
  2562. X *   E-mail: ti@amb.org
  2563. X *
  2564. X *   This program is free software; you can redistribute it and/or modify
  2565. X *   it under the terms of the GNU General Public License as published by
  2566. X *   the Free Software Foundation; either version 2 of the License, or
  2567. X *   (at your option) any later version.
  2568. X *
  2569. X *   This program is distributed in the hope that it will be useful,
  2570. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2571. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2572. X *   GNU General Public License for more details.
  2573. X *
  2574. X *   You should have received a copy of the GNU General Public License
  2575. X *   along with this program; if not, write to the Free Software
  2576. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2577. X *
  2578. X */
  2579. X#ifndef LINT
  2580. Xstatic char *_rew_xbm_ident_ = "@(#)rew.xbm    1.6 93/09/28";
  2581. X#endif
  2582. X
  2583. X#define rew_width 16
  2584. X#define rew_height 16
  2585. Xstatic unsigned char rew_bits[] = {
  2586. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x60, 0x18, 0x70, 0x1c,
  2587. X   0x78, 0x1e, 0x7c, 0x1f, 0x7c, 0x1f, 0x78, 0x1e, 0x70, 0x1c, 0x60, 0x18,
  2588. X   0x40, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2589. X};
  2590. END_OF_FILE
  2591. if test 1191 -ne `wc -c <'bitmaps/rew.xbm'`; then
  2592.     echo shar: \"'bitmaps/rew.xbm'\" unpacked with wrong size!
  2593. fi
  2594. # end of 'bitmaps/rew.xbm'
  2595. fi
  2596. if test -f 'bitmaps/sample.xbm' -a "${1}" != "-c" ; then 
  2597.   echo shar: Will not clobber existing file \"'bitmaps/sample.xbm'\"
  2598. else
  2599. echo shar: Extracting \"'bitmaps/sample.xbm'\" \(1206 characters\)
  2600. sed "s/^X//" >'bitmaps/sample.xbm' <<'END_OF_FILE'
  2601. X/*
  2602. X *   xmcd - Motif(tm) CD Audio Player
  2603. X *
  2604. X *   Copyright (C) 1993  Ti Kan
  2605. X *   E-mail: ti@amb.org
  2606. X *
  2607. X *   This program is free software; you can redistribute it and/or modify
  2608. X *   it under the terms of the GNU General Public License as published by
  2609. X *   the Free Software Foundation; either version 2 of the License, or
  2610. X *   (at your option) any later version.
  2611. X *
  2612. X *   This program is distributed in the hope that it will be useful,
  2613. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2614. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2615. X *   GNU General Public License for more details.
  2616. X *
  2617. X *   You should have received a copy of the GNU General Public License
  2618. X *   along with this program; if not, write to the Free Software
  2619. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2620. X *
  2621. X */
  2622. X#ifndef LINT
  2623. Xstatic char *_sample_xbm_ident_ = "@(#)sample.xbm    1.7 93/09/28";
  2624. X#endif
  2625. X
  2626. X#define sample_width 16
  2627. X#define sample_height 16
  2628. Xstatic unsigned char sample_bits[] = {
  2629. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06,
  2630. X   0x26, 0x26, 0x6e, 0x6e, 0x6e, 0x6e, 0x26, 0x26, 0x06, 0x06, 0x06, 0x06,
  2631. X   0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2632. X};
  2633. END_OF_FILE
  2634. if test 1206 -ne `wc -c <'bitmaps/sample.xbm'`; then
  2635.     echo shar: \"'bitmaps/sample.xbm'\" unpacked with wrong size!
  2636. fi
  2637. # end of 'bitmaps/sample.xbm'
  2638. fi
  2639. if test -f 'bitmaps/shuffle.xbm' -a "${1}" != "-c" ; then 
  2640.   echo shar: Will not clobber existing file \"'bitmaps/shuffle.xbm'\"
  2641. else
  2642. echo shar: Extracting \"'bitmaps/shuffle.xbm'\" \(1211 characters\)
  2643. sed "s/^X//" >'bitmaps/shuffle.xbm' <<'END_OF_FILE'
  2644. X/*
  2645. X *   xmcd - Motif(tm) CD Audio Player
  2646. X *
  2647. X *   Copyright (C) 1993  Ti Kan
  2648. X *   E-mail: ti@amb.org
  2649. X *
  2650. X *   This program is free software; you can redistribute it and/or modify
  2651. X *   it under the terms of the GNU General Public License as published by
  2652. X *   the Free Software Foundation; either version 2 of the License, or
  2653. X *   (at your option) any later version.
  2654. X *
  2655. X *   This program is distributed in the hope that it will be useful,
  2656. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2657. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2658. X *   GNU General Public License for more details.
  2659. X *
  2660. X *   You should have received a copy of the GNU General Public License
  2661. X *   along with this program; if not, write to the Free Software
  2662. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2663. X *
  2664. X */
  2665. X#ifndef LINT
  2666. Xstatic char *_shuffle_xbm_ident_ = "@(#)shuffle.xbm    1.9 93/09/28";
  2667. X#endif
  2668. X
  2669. X#define shuffle_width 16
  2670. X#define shuffle_height 16
  2671. Xstatic unsigned char shuffle_bits[] = {
  2672. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0xcc, 0x00,
  2673. X   0x84, 0x0c, 0xc0, 0x3c, 0x60, 0x3c, 0x30, 0x0c, 0x00, 0x00, 0x30, 0x00,
  2674. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2675. X};
  2676. END_OF_FILE
  2677. if test 1211 -ne `wc -c <'bitmaps/shuffle.xbm'`; then
  2678.     echo shar: \"'bitmaps/shuffle.xbm'\" unpacked with wrong size!
  2679. fi
  2680. # end of 'bitmaps/shuffle.xbm'
  2681. fi
  2682. if test -f 'bitmaps/stop.xbm' -a "${1}" != "-c" ; then 
  2683.   echo shar: Will not clobber existing file \"'bitmaps/stop.xbm'\"
  2684. else
  2685. echo shar: Extracting \"'bitmaps/stop.xbm'\" \(1196 characters\)
  2686. sed "s/^X//" >'bitmaps/stop.xbm' <<'END_OF_FILE'
  2687. X/*
  2688. X *   xmcd - Motif(tm) CD Audio Player
  2689. X *
  2690. X *   Copyright (C) 1993  Ti Kan
  2691. X *   E-mail: ti@amb.org
  2692. X *
  2693. X *   This program is free software; you can redistribute it and/or modify
  2694. X *   it under the terms of the GNU General Public License as published by
  2695. X *   the Free Software Foundation; either version 2 of the License, or
  2696. X *   (at your option) any later version.
  2697. X *
  2698. X *   This program is distributed in the hope that it will be useful,
  2699. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2700. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2701. X *   GNU General Public License for more details.
  2702. X *
  2703. X *   You should have received a copy of the GNU General Public License
  2704. X *   along with this program; if not, write to the Free Software
  2705. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2706. X *
  2707. X */
  2708. X#ifndef LINT
  2709. Xstatic char *_stop_xbm_ident_ = "@(#)stop.xbm    1.6 93/09/28";
  2710. X#endif
  2711. X
  2712. X#define stop_width 16
  2713. X#define stop_height 16
  2714. Xstatic unsigned char stop_bits[] = {
  2715. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0xf0, 0x0f,
  2716. X   0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f, 0xf0, 0x0f,
  2717. X   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2718. X};
  2719. END_OF_FILE
  2720. if test 1196 -ne `wc -c <'bitmaps/stop.xbm'`; then
  2721.     echo shar: \"'bitmaps/stop.xbm'\" unpacked with wrong size!
  2722. fi
  2723. # end of 'bitmaps/stop.xbm'
  2724. fi
  2725. if test -f 'bitmaps/time.xbm' -a "${1}" != "-c" ; then 
  2726.   echo shar: Will not clobber existing file \"'bitmaps/time.xbm'\"
  2727. else
  2728. echo shar: Extracting \"'bitmaps/time.xbm'\" \(1196 characters\)
  2729. sed "s/^X//" >'bitmaps/time.xbm' <<'END_OF_FILE'
  2730. X/*
  2731. X *   xmcd - Motif(tm) CD Audio Player
  2732. X *
  2733. X *   Copyright (C) 1993  Ti Kan
  2734. X *   E-mail: ti@amb.org
  2735. X *
  2736. X *   This program is free software; you can redistribute it and/or modify
  2737. X *   it under the terms of the GNU General Public License as published by
  2738. X *   the Free Software Foundation; either version 2 of the License, or
  2739. X *   (at your option) any later version.
  2740. X *
  2741. X *   This program is distributed in the hope that it will be useful,
  2742. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2743. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2744. X *   GNU General Public License for more details.
  2745. X *
  2746. X *   You should have received a copy of the GNU General Public License
  2747. X *   along with this program; if not, write to the Free Software
  2748. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2749. X *
  2750. X */
  2751. X#ifndef LINT
  2752. Xstatic char *_time_xbm_ident_ = "@(#)time.xbm    1.6 93/09/28";
  2753. X#endif
  2754. X
  2755. X#define time_width 16
  2756. X#define time_height 16
  2757. Xstatic unsigned char time_bits[] = {
  2758. X   0x00, 0x00, 0xe0, 0x03, 0xf8, 0x0f, 0x1c, 0x1c, 0x8c, 0x18, 0x86, 0x30,
  2759. X   0x86, 0x30, 0xf6, 0x30, 0x06, 0x30, 0x06, 0x30, 0x0c, 0x18, 0x1c, 0x1c,
  2760. X   0xf8, 0x0f, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00
  2761. X};
  2762. END_OF_FILE
  2763. if test 1196 -ne `wc -c <'bitmaps/time.xbm'`; then
  2764.     echo shar: \"'bitmaps/time.xbm'\" unpacked with wrong size!
  2765. fi
  2766. # end of 'bitmaps/time.xbm'
  2767. fi
  2768. if test -f 'bitmaps/xmcd.xbm' -a "${1}" != "-c" ; then 
  2769.   echo shar: Will not clobber existing file \"'bitmaps/xmcd.xbm'\"
  2770. else
  2771. echo shar: Extracting \"'bitmaps/xmcd.xbm'\" \(2246 characters\)
  2772. sed "s/^X//" >'bitmaps/xmcd.xbm' <<'END_OF_FILE'
  2773. X/*
  2774. X *   xmcd - Motif(tm) CD Audio Player
  2775. X *
  2776. X *   Copyright (C) 1993  Ti Kan
  2777. X *   E-mail: ti@amb.org
  2778. X *
  2779. X *   This program is free software; you can redistribute it and/or modify
  2780. X *   it under the terms of the GNU General Public License as published by
  2781. X *   the Free Software Foundation; either version 2 of the License, or
  2782. X *   (at your option) any later version.
  2783. X *
  2784. X *   This program is distributed in the hope that it will be useful,
  2785. X *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  2786. X *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  2787. X *   GNU General Public License for more details.
  2788. X *
  2789. X *   You should have received a copy of the GNU General Public License
  2790. X *   along with this program; if not, write to the Free Software
  2791. X *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  2792. X *
  2793. X */
  2794. X#ifndef LINT
  2795. Xstatic char *_xmcd_xbm_ident_ = "@(#)xmcd.xbm    1.6 93/09/28";
  2796. X#endif
  2797. X
  2798. X#define xmcd_width 40
  2799. X#define xmcd_height 40
  2800. Xstatic unsigned char xmcd_bits[] = {
  2801. X   0x00, 0x00, 0xff, 0x01, 0x00, 0x00, 0xe0, 0x00, 0x0e, 0x00, 0x00, 0x18,
  2802. X   0xff, 0x31, 0x00, 0x00, 0xe6, 0xff, 0xcf, 0x00, 0x00, 0xd9, 0xff, 0x3f,
  2803. X   0x01, 0x80, 0xf4, 0xff, 0x7f, 0x02, 0x40, 0xea, 0xfd, 0xff, 0x04, 0x20,
  2804. X   0x20, 0xf5, 0xff, 0x09, 0x10, 0xc8, 0xfb, 0xff, 0x13, 0x50, 0x54, 0xff,
  2805. X   0xff, 0x17, 0x88, 0xc0, 0xf7, 0xff, 0x2b, 0x48, 0x02, 0xed, 0xff, 0x2f,
  2806. X   0x54, 0x80, 0xfc, 0xff, 0x57, 0x04, 0x00, 0xfe, 0xff, 0x5f, 0x34, 0x00,
  2807. X   0x83, 0xbf, 0x5d, 0x5a, 0x01, 0x00, 0x7e, 0xb7, 0x5a, 0x04, 0x38, 0x76,
  2808. X   0xbf, 0xba, 0x51, 0x7c, 0xfc, 0xba, 0xda, 0x04, 0xfe, 0x94, 0xbd, 0xba,
  2809. X   0x49, 0xfe, 0x84, 0xb7, 0x3a, 0x2d, 0xfe, 0xcc, 0xb8, 0xda, 0x76, 0x7c,
  2810. X   0x40, 0xbc, 0x7a, 0xfd, 0x38, 0x22, 0xb1, 0x7a, 0xfd, 0x00, 0x40, 0xb1,
  2811. X   0xf4, 0xff, 0x83, 0x00, 0x5c, 0xf4, 0xff, 0xff, 0x01, 0x58, 0xf4, 0xff,
  2812. X   0x7f, 0x03, 0x50, 0xe8, 0xff, 0xeb, 0x04, 0x28, 0xe8, 0xff, 0xdf, 0x00,
  2813. X   0x28, 0xd0, 0xff, 0xb7, 0x0a, 0x14, 0x90, 0xff, 0x7f, 0x49, 0x12, 0x20,
  2814. X   0xff, 0x4f, 0x07, 0x09, 0x40, 0xfe, 0x37, 0x6d, 0x04, 0x80, 0xfc, 0xf7,
  2815. X   0x58, 0x02, 0x00, 0xf9, 0xaf, 0x37, 0x01, 0x00, 0xe6, 0xff, 0xcf, 0x00,
  2816. X   0x00, 0x18, 0xff, 0x31, 0x00, 0x00, 0xe0, 0x00, 0x0e, 0x00, 0x00, 0x00,
  2817. X   0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
  2818. X};
  2819. END_OF_FILE
  2820. if test 2246 -ne `wc -c <'bitmaps/xmcd.xbm'`; then
  2821.     echo shar: \"'bitmaps/xmcd.xbm'\" unpacked with wrong size!
  2822. fi
  2823. # end of 'bitmaps/xmcd.xbm'
  2824. fi
  2825. echo shar: End of archive 10 \(of 13\).
  2826. cp /dev/null ark10isdone
  2827. MISSING=""
  2828. for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 ; do
  2829.     if test ! -f ark${I}isdone ; then
  2830.     MISSING="${MISSING} ${I}"
  2831.     fi
  2832. done
  2833. if test "${MISSING}" = "" ; then
  2834.     echo You have unpacked all 13 archives.
  2835.     echo "Now read the README and INSTALL files for further instructions."
  2836.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  2837. else
  2838.     echo You still need to unpack the following archives:
  2839.     echo "        " ${MISSING}
  2840. fi
  2841. ##  End of shell archive.
  2842. exit 0
  2843. -- 
  2844.     ///  Ti Kan                vorsprung durch technik
  2845.    ///   AMB Research Laboratories, Sunnyvale, CA. USA
  2846.   ///    ti@amb.org
  2847.  //////  ...!{decwrl,synopsys,tandem,tsoft,ultra}!sgiblab!bazooka!ti
  2848. ///      ...!uunet!bazooka!ti
  2849.  
  2850.  
  2851.  
  2852. exit 0 # Just in case...
  2853. -- 
  2854.   // chris@Sterling.COM           | Send comp.sources.x submissions to:
  2855. \X/  Amiga: The only way to fly!  |    sources-x@sterling.com
  2856.        "It's intuitively obvious to the most casual observer..."
  2857.  GCS d++(--) -p+ c++ !l u++ e+ m+(-) s++/++ n h--- f+ g+++ w+ t++ r+ y+
  2858.