eudora-mac/ends.c

1 line
111 KiB
C
Raw Normal View History

2018-05-23 09:59:15 +00:00
/* Copyright (c) 2017, Computer History Museum All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted (subject to the limitations in the disclaimer below) provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Computer History Museum nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "ends.h" #include "buildversion.h" #define FILE_NUM 12 /* Copyright (c) 1990-1992 by the University of Illinois Board of Trustees */ /********************************************************************** * initialization and cleanup **********************************************************************/ #pragma segment Ends typedef struct { Str31 *badNames; short badCount; Str31 newText; #ifdef TWO Str31 otherText; #endif #ifdef IMAP Str31 thisBoxText; #endif short level; CInfoPBRec hfi; Str63 hfi_namePtr; #ifdef IMAP Str63 enclosingFolderName; #endif } BoxFolderDesc, *BoxFolderDescPtr; #ifdef IMAP typedef struct {FSSpec spec; Boolean isDir; Boolean hasUnread; Boolean skipIt; Boolean isIMAPpers; Boolean moveToTop; long imapAttributes;} NameType; #else typedef struct {FSSpec spec; Boolean isDir; Boolean hasUnread; Boolean skipIt;} NameType; #endif void ZapResMenu(short id); Boolean HaveOptiMEM(void); void doInitDEF(short resId,UniversalProcPtr upp,OSType type); void SettingsInit(FSSpecPtr spec,Boolean system,Boolean changeUserState); void OpenSettingsFile(FSSpecPtr spec); void PutUpMenus(void); void CreateBoxes(void); void SetupInsurancePort(void); void SetRunType(void); Boolean ModernSystem(void); void BoxFolder(short vRef,long dirId,MenuHandle *menus,BoxFolderDescPtr bfd,Boolean *anyUnread,Boolean appending,Boolean isIMAP); void RemoveBoxMenus(void); void BuildMarginMenu(void); #ifdef NEVER void MakeHmnusPurge(void); void TrashHmnu(void); #endif void OpenPlugIns(void); void MarkHavingUnread(MenuHandle mh, short item); Boolean UsingNewTables(void); void AwaitStartupAE(void); void AddHelpMenuItems(void); void AddWSMenuItems(void); void Splash(void); void MakeWordChars(void); void ConvertSignature(void); short PlugInDir(short vRef,long dirId); void GenAliasList(void); void BoxNamesSort(NameType **names); int NameCompare(NameType *n1, NameType *n2); void NameSwap(NameType *n1, NameType *n2); void MakeUserFindSettings(FSSpecPtr spec); Boolean MakeUserFindSettingsStd(FSSpecPtr spec); void GetAndInsertHier(short menu); #ifdef IMAP Boolean InferUnread(CInfoPBRec *hfi, Boolean imap); #else Boolean InferUnread(CInfoPBRec *hfi); #endif void CheckAttachFolder(void); void AddRes2HelpMenu(MenuHandle hm,Handle resH); OSErr AddIconsToColorMenu(MenuHandle mh); OSErr LogPlugins(void); void SaneSettings(FSSpecPtr spec); void HuntSpellswell(void); Boolea