#include #include /**************************************************************************** ** Form implementation generated from reading ui file '/home/bettini/work/klcddimmer/src/brightnesschooser.ui' ** ** Created: Sat Feb 24 20:45:57 2007 ** by: The User Interface Compiler ($Id: qt/main.cpp 3.3.7 edited Aug 31 2005 $) ** ** WARNING! All changes made in this file will be lost! ****************************************************************************/ #include "brightnesschooser.h" #include #include #include #include #include #include #include /* * Constructs a BrightnessChooser as a child of 'parent', with the * name 'name' and widget flags set to 'f'. */ BrightnessChooser::BrightnessChooser( TQWidget* parent, const char* name, WFlags fl ) : TQWidget( parent, name, fl ) { if ( !name ) setName( "BrightnessChooser" ); BrightnessChooserLayout = new TQGridLayout( this, 1, 1, 11, 6, "BrightnessChooserLayout"); layout9 = new TQGridLayout( 0, 1, 1, 0, 6, "layout9"); layout7 = new TQHBoxLayout( 0, 0, 0, "layout7"); spacer1 = new TQSpacerItem( 20, 20, TQSizePolicy::Minimum, TQSizePolicy::Minimum ); layout7->addItem( spacer1 ); layout5 = new TQVBoxLayout( 0, 0, 6, "layout5"); valueLabel = new TQLabel( this, "valueLabel" ); valueLabel->setAlignment( int( TQLabel::AlignCenter ) ); layout5->addWidget( valueLabel ); brightnessSlider = new TQSlider( this, "brightnessSlider" ); brightnessSlider->setOrientation( TQSlider::Vertical ); layout5->addWidget( brightnessSlider ); layout7->addLayout( layout5 ); spacer1_2 = new TQSpacerItem( 16, 20, TQSizePolicy::Minimum, TQSizePolicy::Minimum ); layout7->addItem( spacer1_2 ); layout9->addLayout( layout7, 0, 0 ); okButton = new TQPushButton( this, "okButton" ); okButton->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, okButton->sizePolicy().hasHeightForWidth() ) ); layout9->addWidget( okButton, 1, 0 ); BrightnessChooserLayout->addLayout( layout9, 0, 0 ); languageChange(); resize( TQSize(124, 163).expandedTo(minimumSizeHint()) ); clearWState( WState_Polished ); // signals and slots connections connect( okButton, SIGNAL( clicked() ), this, SLOT( updateBrightness() ) ); connect( brightnessSlider, SIGNAL( valueChanged(int) ), this, SLOT( updateValue(int) ) ); } /* * Destroys the object and frees any allocated resources */ BrightnessChooser::~BrightnessChooser() { // no need to delete child widgets, TQt does it all for us } /* * Sets the strings of the subwidgets using the current * language. */ void BrightnessChooser::languageChange() { setCaption( tr2i18n( "Form1" ) ); valueLabel->setText( tr2i18n( "0" ) ); TQToolTip::add( brightnessSlider, tr2i18n( "set the brightness and click OK or press ENTER" ) ); okButton->setText( tr2i18n( "&OK" ) ); okButton->setAccel( TQKeySequence( tr2i18n( "Alt+O" ) ) ); } void BrightnessChooser::updateBrightness() { tqWarning( "BrightnessChooser::updateBrightness(): Not implemented yet" ); } void BrightnessChooser::updateValue(int) { tqWarning( "BrightnessChooser::updateValue(int): Not implemented yet" ); } #include "brightnesschooser.moc"