You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tdebase/khotkeys/kcontrol/main_buttons_widget.cpp

52 lines
1.6 KiB

/****************************************************************************
KHotKeys
Copyright (C) 1999-2001 Lubos Lunak <l.lunak@kde.org>
Distributed under the terms of the GNU General Public License version 2.
****************************************************************************/
#define MAIN_BUTTONS_WIDGET_CPP
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "main_buttons_widget.h"
#include <tqpushbutton.h>
#include "kcmkhotkeys.h"
namespace KHotKeys
{
Main_buttons_widget::Main_buttons_widget( TQWidget* parent_P, const char* name_P )
: Main_buttons_widget_ui( parent_P, name_P )
{
connect( new_action_button, TQ_SIGNAL( clicked()), TQ_SIGNAL( new_action_pressed()));
connect( new_action_group_button, TQ_SIGNAL( clicked()), TQ_SIGNAL( new_action_group_pressed()));
connect( delete_action_button, TQ_SIGNAL( clicked()), TQ_SIGNAL( delete_action_pressed()));
connect( global_settings_button, TQ_SIGNAL( clicked()), TQ_SIGNAL( global_settings_pressed()));
enable_delete( false );
// KHotKeys::Module::changed()
connect( new_action_button, TQ_SIGNAL( clicked()),
module, TQ_SLOT( changed()));
connect( new_action_group_button, TQ_SIGNAL( clicked()),
module, TQ_SLOT( changed()));
connect( delete_action_button, TQ_SIGNAL( clicked()),
module, TQ_SLOT( changed()));
setMaximumHeight( sizeHint().height()); // it gets too high and I have no idea why
}
void Main_buttons_widget::enable_delete( bool enable_P )
{
delete_action_button->setEnabled( enable_P );
}
} // namespace KHotKeys
#include "main_buttons_widget.moc"