--- BasiliskII/src/AmigaOS/clip_amiga.cpp 2000/04/10 18:52:34 1.3 +++ BasiliskII/src/AmigaOS/clip_amiga.cpp 2008/01/01 09:40:31 1.9 @@ -1,7 +1,7 @@ /* * clip_amiga.cpp - Clipboard handling, AmigaOS implementation * - * Basilisk II (C) 1997-2000 Christian Bauer + * Basilisk II (C) 1997-2008 Christian Bauer * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -18,14 +18,19 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +#include "sysdeps.h" + #include #include #include +#define __USE_SYSBASE #include #include +#include +#include -#include "sysdeps.h" #include "clip.h" +#include "prefs.h" #define DEBUG 0 #include "debug.h" @@ -35,6 +40,7 @@ static struct IFFHandle *iffw = NULL; static struct ClipboardHandle *ch = NULL; static bool clipboard_open = false; +static bool no_clip_conversion; // Conversion tables @@ -64,6 +70,8 @@ static const uint8 mac2iso[0x80] = { void ClipInit(void) { + no_clip_conversion = PrefsFindBool("noclipconversion"); + // Create clipboard IFF handle iffw = AllocIFF(); if (iffw) { @@ -91,6 +99,16 @@ void ClipExit(void) /* + * Mac application reads clipboard + */ + +void GetScrap(void **handle, uint32 type, int32 offset) +{ + D(bug("GetScrap handle %p, type %08x, offset %d\n", handle, type, offset)); +} + + +/* * Mac application wrote to clipboard */ @@ -117,7 +135,7 @@ void PutScrap(uint32 type, void *scrap, if (c < 0x80) { if (c == 13) // CR -> LF c = 10; - } else + } else if (!no_clip_conversion) c = mac2iso[c & 0x7f]; *q++ = c; }