You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 lines
1.3 KiB
C++

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

/**********************************************************************
* @file GUIComboBox.h
* @brief 封装ComboBox解决ComboBox滚轮问题
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*********************************************************************/
#ifndef _GUIComboBox_H_
#define _GUIComboBox_H_
#include <QComboBox>
#include "GUIWidgetAPI.h"
namespace GUI
{
/**
* @brief 封装ComboBox解决ComboBox滚轮问题
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
class GUIWidgetAPI GUIComboBox : public QComboBox
{
Q_OBJECT;
public:
/**
* @brief 构造函数
* @param[i] parent 父对象
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
explicit GUIComboBox(QWidget* parent = nullptr);
/**
* @brief 析构函数
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
virtual ~GUIComboBox();
protected:
/**
* @brief 滚轮事件重写
* @param[i] e 事件对象
* @author BaGuijun (baguijun@163.com)
* @date 2024-09-11
*/
void wheelEvent(QWheelEvent *e) override;
};
}
#endif