diff --git a/src/GUI/FGCocoaMenuBar.mm b/src/GUI/FGCocoaMenuBar.mm index 288017ab7..09568ab99 100644 --- a/src/GUI/FGCocoaMenuBar.mm +++ b/src/GUI/FGCocoaMenuBar.mm @@ -2,8 +2,6 @@ #include -#include - #include #include #include @@ -77,12 +75,6 @@ public: std::vector listeners; }; -// prior to the 10.6 SDK, NSMenuDelegate was an informal protocol -#if __MAC_OS_X_VERSION_MIN_REQUIRED < 1060 -@protocol NSMenuDelegate -@end -#endif - @interface CocoaMenuDelegate : NSObject { @private FGCocoaMenuBar::CocoaMenuBarPrivate* peer; @@ -182,7 +174,7 @@ static bool labelIsSeparator(NSString* s) void FGCocoaMenuBar::CocoaMenuBarPrivate::menuFromProps(NSMenu* menu, SGPropertyNode* menuNode) { int index = 0; - BOOST_FOREACH(SGPropertyNode_ptr n, menuNode->getChildren("item")) { + for (SGPropertyNode_ptr n : menuNode->getChildren("item")) { if (!n->hasValue("enabled")) { n->setBoolValue("enabled", true); } @@ -277,7 +269,7 @@ void FGCocoaMenuBar::init() [previousMenu setTitle:@"FlightGear"]; } - BOOST_FOREACH(SGPropertyNode_ptr n, props->getChildren("menu")) { + for (auto n : props->getChildren("menu")) { NSString* label = stdStringToCocoa(getLocalizedLabel(n)); NSMenuItem* item = [mainBar itemWithTitle:label]; NSMenu* menu;