Revision: 28891 http://sourceforge.net/p/bibdesk/svn/28891 Author: hofman Date: 2024-05-07 09:25:52 +0000 (Tue, 07 May 2024) Log Message: ----------- use bit shift operator to define option enum values
Modified Paths: -------------- trunk/bibdesk/BDSKTemplate.h trunk/bibdesk/BibAuthor.h Modified: trunk/bibdesk/BDSKTemplate.h =================================================================== --- trunk/bibdesk/BDSKTemplate.h 2024-05-06 23:32:03 UTC (rev 28890) +++ trunk/bibdesk/BDSKTemplate.h 2024-05-07 09:25:52 UTC (rev 28891) @@ -41,17 +41,17 @@ typedef NS_OPTIONS(NSUInteger, BDSKTemplateFormat) { BDSKTemplateFormatUnknown = 0, - BDSKTemplateFormatText = 1, // generic plain text template - BDSKTemplateFormatPlainHTML = 2, // HTML template edited as plain text - BDSKTemplateFormatPlainText = 3, // any plain text template - BDSKTemplateFormatRichHTML = 4, // HTML template edited as wysiwyg - BDSKTemplateFormatRTF = 8, - BDSKTemplateFormatRTFD = 16, - BDSKTemplateFormatDoc = 32, - BDSKTemplateFormatDocx = 64, - BDSKTemplateFormatOdt = 128, - BDSKTemplateFormatWebArchive = 256, - BDSKTemplateFormatRichText = 444 // Rich HTML, RTF, RTFD, Doc, Docx, ODT, or WebArchive + BDSKTemplateFormatText = 1 << 0, // generic plain text template + BDSKTemplateFormatPlainHTML = 1 << 1, // HTML template edited as plain text + BDSKTemplateFormatPlainText = BDSKTemplateFormatText | BDSKTemplateFormatPlainHTML, // any plain text template + BDSKTemplateFormatRichHTML = 1 << 2, // HTML template edited as wysiwyg + BDSKTemplateFormatRTF = 1 << 3, + BDSKTemplateFormatRTFD = 1 << 4, + BDSKTemplateFormatDoc = 1 << 5, + BDSKTemplateFormatDocx = 1 << 6, + BDSKTemplateFormatOdt = 1 << 7, + BDSKTemplateFormatWebArchive = 1 << 8, + BDSKTemplateFormatRichText = BDSKTemplateFormatRichHTML | BDSKTemplateFormatRTF | BDSKTemplateFormatRTFD | BDSKTemplateFormatDoc | BDSKTemplateFormatDocx | BDSKTemplateFormatOdt | BDSKTemplateFormatWebArchive // Any rich text template }; extern NSString *BDSKTemplateRoleString; Modified: trunk/bibdesk/BibAuthor.h =================================================================== --- trunk/bibdesk/BibAuthor.h 2024-05-06 23:32:03 UTC (rev 28890) +++ trunk/bibdesk/BibAuthor.h 2024-05-07 09:25:52 UTC (rev 28891) @@ -42,9 +42,9 @@ @class BibItem; typedef NS_OPTIONS(NSUInteger, BDSKAuthorDisplay) { - BDSKAuthorDisplayFirstName = 1, - BDSKAuthorDisplayAbbreviateFirstName = 2, - BDSKAuthorDisplayLastNameFirst = 4 + BDSKAuthorDisplayFirstName = 1 << 0, + BDSKAuthorDisplayAbbreviateFirstName = 1 << 1, + BDSKAuthorDisplayLastNameFirst = 1 << 2 }; /*! This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. _______________________________________________ Bibdesk-commit mailing list Bibdesk-commit@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bibdesk-commit