Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

R14->R15



I'm finishing up a long round of 3.1.5 to R14 conversions and preparing to move on to R15. The main stumbling block I've found so far is the pervasive use of CString_AC in interfaces. The conversion approach I prefer is to allow my application source code to compile against the old and new MacApp versions simultaneously. To that end I'm trying a suggestion Tom Becker provided a year or two ago and have added the following lines to AutoSwitches_AC.h:

#define qBackwardCompatible 1
#define CString_AC CStr255_AC

I've also commented out the body of CString_AC.h by surrounding the file with

#if 0
#endif

starting with the line:

#include <string>

CPascalString_AC lacks a few features of CString_AC so the changes above do not suffice. I've started by adding two inlines to the CStr255_AC interface, after operator const char*() const:

const char* data() const
{ return CChar255_AC(*this); }

unsigned char size() const
{ return this->Length(); }

There's more work to be done, though. Has anyone else tried this approach to conversion, or does anyone have an alternative approach to suggest?

For the record, I recognize that CString_AC is a superior solution, and for the long term the code ought to be converted to use it. At the moment, though, I'm not close to having the budget that would allow that to happen.

--
Adam Wildavsky Extreme Programmer Tameware, LLC
email@hidden http://www.tameware.com
_______________________________________________
macapp-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/macapp-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: WWDC? (From: Thomas Myers <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.