~lukas-kde/unity8/threeFingerTapOverlay

« back to all changes in this revision

Viewing changes to qml/Stages/WindowControlsOverlay.qml

  • Committer: Lukáš Tinkl
  • Date: 2016-05-20 12:29:44 UTC
  • Revision ID: lukas.tinkl@canonical.com-20160520122944-x1ci87o8ed8mu7cp
take the horizontal/vertical maximization into account as well
when showing the resize handles

Show diffs side-by-side

added added

removed removed

Lines of Context:
34
34
        anchors.fill: parent
35
35
 
36
36
        // NB: for testing set to 2, not to clash with unity7 touch overlay controls
37
 
        minimumTouchPoints: 2
 
37
        minimumTouchPoints: 3
38
38
        maximumTouchPoints: minimumTouchPoints
39
39
        releaseRejectPeriod: 500
40
40
 
152
152
        ResizeGrip { // top left
153
153
            anchors.horizontalCenter: parent.left
154
154
            anchors.verticalCenter: parent.top
155
 
            visible: target && !overlay.anyMaximized
 
155
            visible: target && !overlay.anyMaximized && !target.maximizedHorizontally && !target.maximizedVertically
156
156
            resizeTarget: priv.resizeArea
157
157
        }
158
158
 
160
160
            anchors.horizontalCenter: parent.horizontalCenter
161
161
            anchors.verticalCenter: parent.top
162
162
            rotation: 45
163
 
            visible: target && !overlay.anyMaximized
 
163
            visible: target && !overlay.anyMaximized && !target.maximizedVertically
164
164
            resizeTarget: priv.resizeArea
165
165
        }
166
166
 
168
168
            anchors.horizontalCenter: parent.right
169
169
            anchors.verticalCenter: parent.top
170
170
            rotation: 90
171
 
            visible: target && !overlay.anyMaximized
 
171
            visible: target && !overlay.anyMaximized && !target.maximizedHorizontally && !target.maximizedVertically
172
172
            resizeTarget: priv.resizeArea
173
173
        }
174
174
 
176
176
            anchors.horizontalCenter: parent.right
177
177
            anchors.verticalCenter: parent.verticalCenter
178
178
            rotation: 135
179
 
            visible: target && !target.maximizedRight && !target.maximized
 
179
            visible: target && !target.maximizedRight && !target.maximized && !target.maximizedHorizontally
180
180
            resizeTarget: priv.resizeArea
181
181
        }
182
182
 
183
183
        ResizeGrip { // bottom right
184
184
            anchors.horizontalCenter: parent.right
185
185
            anchors.verticalCenter: parent.bottom
186
 
            visible: target && !overlay.anyMaximized
 
186
            visible: target && !overlay.anyMaximized && !target.maximizedHorizontally && !target.maximizedVertically
187
187
            resizeTarget: priv.resizeArea
188
188
        }
189
189
 
191
191
            anchors.horizontalCenter: parent.horizontalCenter
192
192
            anchors.verticalCenter: parent.bottom
193
193
            rotation: 45
194
 
            visible: target && !overlay.anyMaximized
 
194
            visible: target && !overlay.anyMaximized && !target.maximizedVertically
195
195
            resizeTarget: priv.resizeArea
196
196
        }
197
197
 
199
199
            anchors.horizontalCenter: parent.left
200
200
            anchors.verticalCenter: parent.bottom
201
201
            rotation: 90
202
 
            visible: target && !overlay.anyMaximized
 
202
            visible: target && !overlay.anyMaximized && !target.maximizedHorizontally && !target.maximizedVertically
203
203
            resizeTarget: priv.resizeArea
204
204
        }
205
205
 
207
207
            anchors.horizontalCenter: parent.left
208
208
            anchors.verticalCenter: parent.verticalCenter
209
209
            rotation: 135
210
 
            visible: target && !target.maximizedLeft && !target.maximized
 
210
            visible: target && !target.maximizedLeft && !target.maximized && !target.maximizedHorizontally
211
211
            resizeTarget: priv.resizeArea
212
212
        }
213
213
    }