mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 18:32:50 +00:00
generic: use loop-scoped variables
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
770aded56e
commit
751c90cf55
5 changed files with 6 additions and 10 deletions
|
@ -799,8 +799,7 @@ void KColorCm::updateColorTable()
|
||||||
stackColors->setCurrentIndex(0);
|
stackColors->setCurrentIndex(0);
|
||||||
stackPreview->setCurrentIndex(0);
|
stackPreview->setCurrentIndex(0);
|
||||||
|
|
||||||
KColorButton * button;
|
foreach (KColorButton *button, m_commonColorButtons)
|
||||||
foreach (button, m_commonColorButtons)
|
|
||||||
{
|
{
|
||||||
button->blockSignals(true);
|
button->blockSignals(true);
|
||||||
}
|
}
|
||||||
|
@ -836,7 +835,7 @@ void KColorCm::updateColorTable()
|
||||||
m_commonColorButtons[24]->setColor(m_wmColors.color(WindecoColors::InactiveForeground));
|
m_commonColorButtons[24]->setColor(m_wmColors.color(WindecoColors::InactiveForeground));
|
||||||
m_commonColorButtons[25]->setColor(m_wmColors.color(WindecoColors::InactiveBlend));
|
m_commonColorButtons[25]->setColor(m_wmColors.color(WindecoColors::InactiveBlend));
|
||||||
|
|
||||||
foreach (button, m_commonColorButtons)
|
foreach (KColorButton *button, m_commonColorButtons)
|
||||||
{
|
{
|
||||||
button->blockSignals(false);
|
button->blockSignals(false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -134,7 +134,6 @@ void ThemePage::updateSizeComboBox()
|
||||||
QIcon m_icon;
|
QIcon m_icon;
|
||||||
if (sizes.size() > 1) // only refill the combobox if there is more that 1 size
|
if (sizes.size() > 1) // only refill the combobox if there is more that 1 size
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
QList<int> comboBoxList;
|
QList<int> comboBoxList;
|
||||||
QPixmap m_pixmap;
|
QPixmap m_pixmap;
|
||||||
|
|
||||||
|
@ -149,7 +148,7 @@ void ThemePage::updateSizeComboBox()
|
||||||
i18nc("@item:inlistbox size", "resolution dependent"),
|
i18nc("@item:inlistbox size", "resolution dependent"),
|
||||||
0);
|
0);
|
||||||
comboBoxList << 0;
|
comboBoxList << 0;
|
||||||
foreach (i, sizes)
|
foreach (int i, sizes)
|
||||||
{
|
{
|
||||||
m_pixmap = theme->createIcon(i);
|
m_pixmap = theme->createIcon(i);
|
||||||
if (m_pixmap.width() > maxIconWidth)
|
if (m_pixmap.width() > maxIconWidth)
|
||||||
|
|
|
@ -118,8 +118,7 @@ void KNotify::closeNotification(int id)
|
||||||
if(e->ref>0)
|
if(e->ref>0)
|
||||||
{
|
{
|
||||||
e->ref++;
|
e->ref++;
|
||||||
KNotifyPlugin *plugin;
|
foreach(KNotifyPlugin *plugin , m_plugins)
|
||||||
foreach(plugin , m_plugins)
|
|
||||||
{
|
{
|
||||||
plugin->close( id );
|
plugin->close( id );
|
||||||
}
|
}
|
||||||
|
|
|
@ -79,8 +79,7 @@ KNotifyConfig *KNotifyConfig::copy() const
|
||||||
|
|
||||||
QString KNotifyConfig::readEntry( const QString & entry, bool path )
|
QString KNotifyConfig::readEntry( const QString & entry, bool path )
|
||||||
{
|
{
|
||||||
QPair<QString , QString> context;
|
for (QPair<QString,QString> context: contexts )
|
||||||
foreach( context , contexts )
|
|
||||||
{
|
{
|
||||||
const QString group="Event/" + eventid + '/' + context.first + '/' + context.second;
|
const QString group="Event/" + eventid + '/' + context.first + '/' + context.second;
|
||||||
if( configfile->hasGroup( group ) )
|
if( configfile->hasGroup( group ) )
|
||||||
|
|
|
@ -372,7 +372,7 @@ void Workspace::raiseClient(Client* c, bool nogroup)
|
||||||
Client *transient_parent = c;
|
Client *transient_parent = c;
|
||||||
while ((transient_parent = transient_parent->transientFor()))
|
while ((transient_parent = transient_parent->transientFor()))
|
||||||
transients << transient_parent;
|
transients << transient_parent;
|
||||||
foreach (transient_parent, transients)
|
foreach (Client *transient_parent, transients)
|
||||||
raiseClient(transient_parent, true);
|
raiseClient(transient_parent, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue