00001 /*---------------------------------------------------------------------\ 00002 | | 00003 | __ __ ____ _____ ____ | 00004 | \ \ / /_ _/ ___|_ _|___ \ | 00005 | \ V / _` \___ \ | | __) | | 00006 | | | (_| |___) || | / __/ | 00007 | |_|\__,_|____/ |_| |_____| | 00008 | | 00009 | core system | 00010 | (C) SuSE GmbH | 00011 \----------------------------------------------------------------------/ 00012 00013 File: YQDumbTab.h 00014 00015 Author: Stefan Hundhammer <sh@suse.de> 00016 00017 /-*/ 00018 00019 // -*- c++ -*- 00020 00021 #ifndef YQDumbTab_h 00022 #define YQDumbTab_h 00023 00024 #include <qvbox.h> 00025 00026 #include "YDumbTab.h" 00027 00028 class QTabBar; 00029 class YQAlignment; 00030 class YWidget; 00031 00032 class YQDumbTab : public QVBox, public YDumbTab 00033 { 00034 Q_OBJECT 00035 00036 public: 00037 00041 YQDumbTab( QWidget * parent, 00042 const YWidgetOpt & opt ); 00043 00049 void setEnabling( bool enabled ); 00050 00056 long nicesize( YUIDimension dim ); 00057 00061 void setSize( long newWidth, long newHeight ); 00062 00066 bool eventFilter( QObject * obj, QEvent * ev ); 00067 00072 void addChild( YWidget * child ); 00073 00074 00075 public slots: 00076 00080 void sendTabSelectedEvent( int index ); 00081 00085 void resizeClientArea(); 00086 00087 00088 protected: 00089 00095 void addTab( const YCPString & label ); 00096 00102 int getSelectedTabIndex(); 00103 00109 void setSelectedTab( int index ); 00110 00111 00112 // 00113 // Data members 00114 // 00115 00116 QTabBar * _tabBar; 00117 QVBox * _clientArea; 00118 YQAlignment * _contents; 00119 00120 bool _doingResize; 00121 }; 00122 00123 #endif // YQDumbTab_h