306 | | if ([item->nsItem() menu]) { |
307 | | qWarning() << Q_FUNC_INFO << "Menu item is already in a menu, remove it from the other menu first before inserting"; |
| 306 | NSMenu *m = [item->nsItem() menu]; |
| 307 | if (m) { |
| 308 | QString mTitle = QCFString::toQString([m title]); |
| 309 | if (beforeItem) { |
| 310 | qWarning() << Q_FUNC_INFO << "Menu item" << item->text() << "is already in menu" << mTitle |
| 311 | << "after item" << beforeItem->text() |
| 312 | << ", remove it from the other menu first before inserting"; |
| 313 | } else { |
| 314 | qWarning() << Q_FUNC_INFO << "Menu item" << item->text() << "is already in menu" << mTitle |
| 315 | << ", remove it from the other menu first before inserting"; |
| 316 | } |