From 116a66179196c272282b67cff51707f96cc3316a Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Mon, 25 Feb 2019 12:20:42 +0100 Subject: Properly deprecate assorted enum members This adds the first uses of Q_DECL_ENUMERATOR_DEPRECATED. Prompted by API change review for 5.13, comment by Christian Ehrlicher. Task-number: QTBUG-73484 Change-Id: Ic106048cec18960a91f88eb12650abab6abf0e97 Reviewed-by: Rolf Eike Beer Reviewed-by: Christian Ehrlicher --- src/widgets/styles/qstyle.h | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) (limited to 'src/widgets/styles') diff --git a/src/widgets/styles/qstyle.h b/src/widgets/styles/qstyle.h index 8256f908db..5ee37bd8e9 100644 --- a/src/widgets/styles/qstyle.h +++ b/src/widgets/styles/qstyle.h @@ -141,8 +141,10 @@ public: PE_FrameGroupBox, PE_FrameLineEdit, PE_FrameMenu, - PE_FrameStatusBar, // ### Qt 6: remove - PE_FrameStatusBarItem = PE_FrameStatusBar, + PE_FrameStatusBarItem, +#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove + PE_FrameStatusBar Q_DECL_ENUMERATOR_DEPRECATED = PE_FrameStatusBarItem, +#endif PE_FrameTabWidget, PE_FrameWindow, PE_FrameButtonBevel, @@ -162,8 +164,10 @@ public: PE_IndicatorArrowUp, PE_IndicatorBranch, PE_IndicatorButtonDropDown, - PE_IndicatorViewItemCheck, // ### Qt 6: remove - PE_IndicatorItemViewItemCheck = PE_IndicatorViewItemCheck, + PE_IndicatorItemViewItemCheck, +#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove + PE_IndicatorViewItemCheck Q_DECL_ENUMERATOR_DEPRECATED = PE_IndicatorItemViewItemCheck, +#endif PE_IndicatorCheckBox, PE_IndicatorDockWidgetResizeHandle, PE_IndicatorHeaderArrow, @@ -309,8 +313,9 @@ public: SE_TabWidgetRightCorner, SE_ItemViewItemCheckIndicator, - SE_ViewItemCheckIndicator = SE_ItemViewItemCheckIndicator, // ### Qt 6: remove - +#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove + SE_ViewItemCheckIndicator Q_DECL_ENUMERATOR_DEPRECATED = SE_ItemViewItemCheckIndicator, +#endif SE_TabBarTearIndicator, SE_TabBarTearIndicatorLeft = SE_TabBarTearIndicator, @@ -506,9 +511,11 @@ public: PM_DialogButtonsButtonHeight, PM_MdiSubWindowFrameWidth, - PM_MDIFrameWidth = PM_MdiSubWindowFrameWidth, // ### Qt 6: remove PM_MdiSubWindowMinimizedWidth, - PM_MDIMinimizedWidth = PM_MdiSubWindowMinimizedWidth, // ### Qt 6: remove +#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove + PM_MDIFrameWidth Q_DECL_ENUMERATOR_DEPRECATED = PM_MdiSubWindowFrameWidth, + PM_MDIMinimizedWidth Q_DECL_ENUMERATOR_DEPRECATED = PM_MdiSubWindowMinimizedWidth, +#endif PM_HeaderMargin, PM_HeaderMarkSize, @@ -649,7 +656,9 @@ public: SH_ComboBox_Popup, SH_TitleBar_NoBorder, SH_Slider_StopMouseOverSlider, - SH_ScrollBar_StopMouseOverSlider = SH_Slider_StopMouseOverSlider, // ### Qt 6: remove +#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove + SH_ScrollBar_StopMouseOverSlider Q_DECL_ENUMERATOR_DEPRECATED = SH_Slider_StopMouseOverSlider, +#endif SH_BlinkCursorWhenTextSelected, SH_RichText_FullWidthSelection, SH_Menu_Scrollable, -- cgit v1.2.3