Main Page | Class Hierarchy | Class List | Directories | File List | Class Members | File Members

YQGenericButton Class Reference

#include <YQGenericButton.h>

Inheritance diagram for YQGenericButton:

YPushButton YWidget YQPushButton YQWizardButton List of all members.

Public Slots

void activate ()

Public Member Functions

virtual ~YQGenericButton ()
void setEnabling (bool enabled)
bool isEnabled () const
void setLabel (const QString &label)
void setLabel (const YCPString &label)
void showAsDefault (bool show=true)
bool isShownAsDefault () const
bool isDefault () const
void setDefault (bool def=true)
virtual bool setKeyboardFocus ()
virtual void setIcon (const YCPString &icon_name)
QString text () const
QPushButton * qPushButton () const
YQDialogyQDialog () const

Protected Member Functions

 YQGenericButton (QWidget *parent, YQDialog *dialog, const YWidgetOpt &opt, YCPString label)
void setQPushButton (QPushButton *pb)
bool eventFilter (QObject *obj, QEvent *event)

Private Attributes

YQDialog_dialog
QPushButton * _qPushButton
bool _isDefault

Detailed Description

Abstract base class for push button and similar widgets - all that can become a YQDialog's "default button".


Constructor & Destructor Documentation

YQGenericButton::YQGenericButton QWidget *  parent,
YQDialog dialog,
const YWidgetOpt opt,
YCPString  label
[protected]
 

Constructor.

YQGenericButton::~YQGenericButton  )  [virtual]
 

Destructor.


Member Function Documentation

void YQGenericButton::activate  )  [slot]
 

Activate (animated) this button.

bool YQGenericButton::eventFilter QObject *  obj,
QEvent *  event
[protected]
 

Redirect events from the _qPushButton member to this object.

Overwritten from QObject.

bool YQGenericButton::isDefault  )  const [inline]
 

Returns 'true' if this is the dialog's default button.

Don't confuse this with isShownAsDefault()!

bool YQGenericButton::isEnabled  )  const
 

Returns 'true' if this button is enabled, 'false' otherwise.

bool YQGenericButton::isShownAsDefault  )  const
 

Returns 'true' if this button is shown as a default button - which may mean that this really is the dialogs's default button or it is the dialog's focus button (a button that currently has the keyboard focus).

Don't confuse this with isDefault()!

QPushButton* YQGenericButton::qPushButton  )  const [inline]
 

Returns the internal Qt PushButton.

void YQGenericButton::setDefault bool  def = true  )  [inline]
 

Set this button's default button state.

void YQGenericButton::setEnabling bool  enabled  )  [virtual]
 

Inherited from YWidget: Sets the enabled state of the widget. Only enabled widgets can take user input.

Reimplemented from YWidget.

void YQGenericButton::setIcon const YCPString icon_name  )  [virtual]
 

Set this button's icon. Inherited from YPushButton.

Reimplemented from YPushButton.

bool YQGenericButton::setKeyboardFocus  )  [virtual]
 

Accept the keyboard focus.

Reimplemented from YWidget.

void YQGenericButton::setLabel const YCPString label  )  [virtual]
 

Changes the label (the text) of the button.

Reimplemented from YPushButton.

void YQGenericButton::setLabel const QString &  label  ) 
 

Changes the label (the text) of the button.

void YQGenericButton::setQPushButton QPushButton *  pb  )  [protected]
 

Set the corresponding QPushButton.

void YQGenericButton::showAsDefault bool  show = true  ) 
 

Show this button as the dialog's default button. The button never calls this by itself - the parent dialog is responsible for that.

QString YQGenericButton::text  )  const
 

Returns the button's text ( label ) - useful for log messages etc.

YQDialog* YQGenericButton::yQDialog  )  const [inline]
 

Returns the internal parent dialog.


Member Data Documentation

YQDialog* YQGenericButton::_dialog [private]
 

bool YQGenericButton::_isDefault [private]
 

QPushButton* YQGenericButton::_qPushButton [private]
 


The documentation for this class was generated from the following files:
Generated on Wed Nov 12 06:11:16 2008 for yast2-qt by  doxygen 1.3.9.1