|
|
@ -178,9 +178,9 @@ smoothblendButton::smoothblendButton(smoothblendClient *parent, const char *name
|
|
|
|
setToggleButton(toggle);
|
|
|
|
setToggleButton(toggle);
|
|
|
|
//button animation setup
|
|
|
|
//button animation setup
|
|
|
|
animTmr = new TQTimer(this);
|
|
|
|
animTmr = new TQTimer(this);
|
|
|
|
connect(animTmr, TQT_SIGNAL(timeout() ), this, TQT_SLOT(animate() ) );
|
|
|
|
connect(animTmr, TQ_SIGNAL(timeout() ), this, TQ_SLOT(animate() ) );
|
|
|
|
connect(this, TQT_SIGNAL(pressed() ), this, TQT_SLOT(buttonClicked() ) );
|
|
|
|
connect(this, TQ_SIGNAL(pressed() ), this, TQ_SLOT(buttonClicked() ) );
|
|
|
|
connect(this, TQT_SIGNAL(released() ), this, TQT_SLOT(buttonReleased() ) );
|
|
|
|
connect(this, TQ_SIGNAL(released() ), this, TQ_SLOT(buttonReleased() ) );
|
|
|
|
animProgress = 0;
|
|
|
|
animProgress = 0;
|
|
|
|
m_clicked=false;
|
|
|
|
m_clicked=false;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -697,8 +697,8 @@ void smoothblendClient::_resetLayout()
|
|
|
|
mainLayout_->addItem( bottomSpacer_ );
|
|
|
|
mainLayout_->addItem( bottomSpacer_ );
|
|
|
|
|
|
|
|
|
|
|
|
// connections
|
|
|
|
// connections
|
|
|
|
connect(this, TQT_SIGNAL(keepAboveChanged(bool)), TQT_SLOT(keepAboveChange(bool)));
|
|
|
|
connect(this, TQ_SIGNAL(keepAboveChanged(bool)), TQ_SLOT(keepAboveChange(bool)));
|
|
|
|
connect(this, TQT_SIGNAL(keepBelowChanged(bool)), TQT_SLOT(keepBelowChange(bool)));
|
|
|
|
connect(this, TQ_SIGNAL(keepBelowChanged(bool)), TQ_SLOT(keepBelowChange(bool)));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
|
|
@ -715,8 +715,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
if (!button[ButtonMenu]) {
|
|
|
|
if (!button[ButtonMenu]) {
|
|
|
|
button[ButtonMenu] =
|
|
|
|
button[ButtonMenu] =
|
|
|
|
new smoothblendButton(this, "splat.png", i18n("Menu"),ButtonMenu,button_size);
|
|
|
|
new smoothblendButton(this, "splat.png", i18n("Menu"),ButtonMenu,button_size);
|
|
|
|
connect(button[ButtonMenu], TQT_SIGNAL(pressed()), this, TQT_SLOT(menuButtonPressed()));
|
|
|
|
connect(button[ButtonMenu], TQ_SIGNAL(pressed()), this, TQ_SLOT(menuButtonPressed()));
|
|
|
|
connect(button[ButtonMenu], TQT_SIGNAL(released()), this, TQT_SLOT(menuButtonReleased()));
|
|
|
|
connect(button[ButtonMenu], TQ_SIGNAL(released()), this, TQ_SLOT(menuButtonReleased()));
|
|
|
|
layout->addWidget(button[ButtonMenu]);
|
|
|
|
layout->addWidget(button[ButtonMenu]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -731,8 +731,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
}
|
|
|
|
}
|
|
|
|
button[ButtonSticky] =
|
|
|
|
button[ButtonSticky] =
|
|
|
|
new smoothblendButton(this, "circle.png", tip, ButtonSticky, button_size, true);
|
|
|
|
new smoothblendButton(this, "circle.png", tip, ButtonSticky, button_size, true);
|
|
|
|
connect(button[ButtonSticky], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonSticky], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(toggleOnAllDesktops()));
|
|
|
|
this, TQ_SLOT(toggleOnAllDesktops()));
|
|
|
|
layout->addWidget(button[ButtonSticky]);
|
|
|
|
layout->addWidget(button[ButtonSticky]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -742,8 +742,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
if ((!button[ButtonHelp]) && providesContextHelp()) {
|
|
|
|
if ((!button[ButtonHelp]) && providesContextHelp()) {
|
|
|
|
button[ButtonHelp] =
|
|
|
|
button[ButtonHelp] =
|
|
|
|
new smoothblendButton(this, "help.png", i18n("Help"), ButtonHelp, button_size);
|
|
|
|
new smoothblendButton(this, "help.png", i18n("Help"), ButtonHelp, button_size);
|
|
|
|
connect(button[ButtonHelp], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonHelp], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(showContextHelp()));
|
|
|
|
this, TQ_SLOT(showContextHelp()));
|
|
|
|
layout->addWidget(button[ButtonHelp]);
|
|
|
|
layout->addWidget(button[ButtonHelp]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -753,8 +753,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
if ((!button[ButtonMin]) && isMinimizable()) {
|
|
|
|
if ((!button[ButtonMin]) && isMinimizable()) {
|
|
|
|
button[ButtonMin] =
|
|
|
|
button[ButtonMin] =
|
|
|
|
new smoothblendButton(this, "minimize.png", i18n("Minimize"), ButtonMin, button_size);
|
|
|
|
new smoothblendButton(this, "minimize.png", i18n("Minimize"), ButtonMin, button_size);
|
|
|
|
connect(button[ButtonMin], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonMin], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(minimize()));
|
|
|
|
this, TQ_SLOT(minimize()));
|
|
|
|
layout->addWidget(button[ButtonMin]);
|
|
|
|
layout->addWidget(button[ButtonMin]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -769,8 +769,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
}
|
|
|
|
}
|
|
|
|
button[ButtonMax] =
|
|
|
|
button[ButtonMax] =
|
|
|
|
new smoothblendButton(this, "maximize.png", tip, ButtonMax, button_size, true);
|
|
|
|
new smoothblendButton(this, "maximize.png", tip, ButtonMax, button_size, true);
|
|
|
|
connect(button[ButtonMax], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonMax], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(maxButtonPressed()));
|
|
|
|
this, TQ_SLOT(maxButtonPressed()));
|
|
|
|
layout->addWidget(button[ButtonMax]);
|
|
|
|
layout->addWidget(button[ButtonMax]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -780,8 +780,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
if ((!button[ButtonClose]) && isCloseable()) {
|
|
|
|
if ((!button[ButtonClose]) && isCloseable()) {
|
|
|
|
button[ButtonClose] =
|
|
|
|
button[ButtonClose] =
|
|
|
|
new smoothblendButton(this, "close.png", i18n("Close"), ButtonClose, button_size);
|
|
|
|
new smoothblendButton(this, "close.png", i18n("Close"), ButtonClose, button_size);
|
|
|
|
connect(button[ButtonClose], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonClose], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(closeWindow()));
|
|
|
|
this, TQ_SLOT(closeWindow()));
|
|
|
|
layout->addWidget(button[ButtonClose]);
|
|
|
|
layout->addWidget(button[ButtonClose]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -792,8 +792,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
button[ButtonAbove] =
|
|
|
|
button[ButtonAbove] =
|
|
|
|
new smoothblendButton(this, "keep_above.png",
|
|
|
|
new smoothblendButton(this, "keep_above.png",
|
|
|
|
i18n("Keep Above Others"), ButtonAbove, button_size, true);
|
|
|
|
i18n("Keep Above Others"), ButtonAbove, button_size, true);
|
|
|
|
connect(button[ButtonAbove], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonAbove], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(aboveButtonPressed()));
|
|
|
|
this, TQ_SLOT(aboveButtonPressed()));
|
|
|
|
layout->addWidget(button[ButtonAbove]);
|
|
|
|
layout->addWidget(button[ButtonAbove]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -804,8 +804,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
button[ButtonBelow] =
|
|
|
|
button[ButtonBelow] =
|
|
|
|
new smoothblendButton(this, "keep_below.png",
|
|
|
|
new smoothblendButton(this, "keep_below.png",
|
|
|
|
i18n("Keep Below Others"), ButtonBelow, button_size, true);
|
|
|
|
i18n("Keep Below Others"), ButtonBelow, button_size, true);
|
|
|
|
connect(button[ButtonBelow], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonBelow], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(belowButtonPressed()));
|
|
|
|
this, TQ_SLOT(belowButtonPressed()));
|
|
|
|
layout->addWidget(button[ButtonBelow]);
|
|
|
|
layout->addWidget(button[ButtonBelow]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -820,8 +820,8 @@ void smoothblendClient::addButtons(TQBoxLayout *layout, const TQString& s, int b
|
|
|
|
}
|
|
|
|
}
|
|
|
|
button[ButtonShade] =
|
|
|
|
button[ButtonShade] =
|
|
|
|
new smoothblendButton(this, "shade.png", tip, ButtonShade, button_size, true);
|
|
|
|
new smoothblendButton(this, "shade.png", tip, ButtonShade, button_size, true);
|
|
|
|
connect(button[ButtonShade], TQT_SIGNAL(clicked()),
|
|
|
|
connect(button[ButtonShade], TQ_SIGNAL(clicked()),
|
|
|
|
this, TQT_SLOT(shadeButtonPressed()));
|
|
|
|
this, TQ_SLOT(shadeButtonPressed()));
|
|
|
|
layout->addWidget(button[ButtonShade]);
|
|
|
|
layout->addWidget(button[ButtonShade]);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
if (n < s.length()-1) layout->addSpacing(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|