Fix quick tiling and maximization GUI and interlocks.
svn path=/trunk/KDE/kdebase/workspace/; revision=1024684
This commit is contained in:
parent
c5c7cd79d6
commit
cf86c50d98
2 changed files with 82 additions and 67 deletions
|
@ -61,6 +61,8 @@ KWinScreenEdgesConfig::KWinScreenEdgesConfig( QWidget* parent, const QVariantLis
|
|||
|
||||
// Visual feedback of action group conflicts
|
||||
connect( m_ui->desktopSwitchCombo, SIGNAL( currentIndexChanged(int) ), this, SLOT( groupChanged() ));
|
||||
connect( m_ui->quickMaximizeBox, SIGNAL( stateChanged(int) ), this, SLOT( groupChanged() ));
|
||||
connect( m_ui->quickTileBox, SIGNAL( stateChanged(int) ), this, SLOT( groupChanged() ));
|
||||
|
||||
if( CompositingPrefs::compositingPossible() )
|
||||
m_defaultPrefs.detect(); // Driver-specific config detection
|
||||
|
@ -84,13 +86,17 @@ void KWinScreenEdgesConfig::groupChanged()
|
|||
monitorHideEdge( ElectricLeft, hide );
|
||||
|
||||
// Desktop switch conflicts
|
||||
m_ui->desktopSwitchLabel->setEnabled( true );
|
||||
m_ui->desktopSwitchCombo->setEnabled( true );
|
||||
|
||||
bool enableMaximize = false;
|
||||
if( m_ui->desktopSwitchCombo->currentIndex() == 0 )
|
||||
enableMaximize = true;
|
||||
m_ui->quickMaximizeBox->setEnabled( enableMaximize );
|
||||
if( m_ui->quickTileBox->isChecked() || m_ui->quickMaximizeBox->isChecked() )
|
||||
{
|
||||
m_ui->desktopSwitchLabel->setEnabled( false );
|
||||
m_ui->desktopSwitchCombo->setEnabled( false );
|
||||
m_ui->desktopSwitchCombo->setCurrentIndex( 0 );
|
||||
}
|
||||
else
|
||||
{
|
||||
m_ui->desktopSwitchLabel->setEnabled( true );
|
||||
m_ui->desktopSwitchCombo->setEnabled( true );
|
||||
}
|
||||
}
|
||||
|
||||
void KWinScreenEdgesConfig::load()
|
||||
|
|
|
@ -10,11 +10,69 @@
|
|||
<height>475</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<property name="margin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item row="1" column="0" colspan="2">
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_3">
|
||||
<property name="title">
|
||||
<string>Active Screen Edge Actions</string>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="KWin::Monitor" name="monitor" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>200</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="text">
|
||||
<string>To trigger an action push your mouse cursor against the edge of the screen in the action's direction.</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="title">
|
||||
<string>Window Management</string>
|
||||
</property>
|
||||
<layout class="QFormLayout" name="formLayout_2">
|
||||
<property name="fieldGrowthPolicy">
|
||||
<enum>QFormLayout::ExpandingFieldsGrow</enum>
|
||||
</property>
|
||||
<item row="0" column="0" colspan="2">
|
||||
<widget class="QCheckBox" name="quickMaximizeBox">
|
||||
<property name="text">
|
||||
<string>Maximize windows by dragging them to the top of the screen</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0" colspan="2">
|
||||
<widget class="QCheckBox" name="quickTileBox">
|
||||
<property name="text">
|
||||
<string>Tile windows by dragging them to the side of the screen</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
|
@ -58,7 +116,7 @@
|
|||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="toolTip">
|
||||
<string>Amount of time required for the mouse cursor to be pushed against the edge of the screen before the action is triggered</string>
|
||||
|
@ -71,7 +129,7 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<item row="2" column="1">
|
||||
<widget class="KIntSpinBox" name="activationDelaySpin">
|
||||
<property name="suffix">
|
||||
<string> ms</string>
|
||||
|
@ -87,7 +145,7 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
|
@ -103,7 +161,7 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<item row="3" column="1">
|
||||
<widget class="KIntSpinBox" name="triggerCooldownSpin">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
|
@ -122,7 +180,7 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<item row="4" column="0">
|
||||
<spacer name="verticalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
|
@ -135,24 +193,10 @@
|
|||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="1" column="0" colspan="2">
|
||||
<widget class="QCheckBox" name="quickMaximizeBox">
|
||||
<property name="text">
|
||||
<string>Maximize windows by dragging them to the top of the screen</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0" colspan="2">
|
||||
<widget class="QCheckBox" name="quickTileBox">
|
||||
<property name="text">
|
||||
<string>Tile windows by dragging them to the side of the screen</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0" colspan="2">
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
|
@ -165,41 +209,6 @@
|
|||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="0" column="0" colspan="2">
|
||||
<widget class="QGroupBox" name="groupBox_3">
|
||||
<property name="title">
|
||||
<string>Active Screen Edge Actions</string>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="KWin::Monitor" name="monitor" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>200</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="text">
|
||||
<string>To trigger an action push your mouse cursor against the edge of the screen in the action's direction.</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
|
|
Loading…
Reference in a new issue