Changeset View
Changeset View
Standalone View
Standalone View
src/activities/scalesboard/MasseArea.qml
Show First 20 Lines • Show All 183 Lines • ▼ Show 20 Line(s) | 144 | Image { | |||
---|---|---|---|---|---|
184 | 184 | | |||
185 | onOpacityChanged: opacity == 1.0 ? currentMasseArea = masseAreaCenter : null | 185 | onOpacityChanged: opacity == 1.0 ? currentMasseArea = masseAreaCenter : null | ||
186 | 186 | | |||
187 | MouseArea { | 187 | MouseArea { | ||
188 | id: dragArea | 188 | id: dragArea | ||
189 | anchors.fill: parent | 189 | anchors.fill: parent | ||
190 | drag.target: parent | 190 | drag.target: parent | ||
191 | enabled: model.dragEnabled | 191 | enabled: model.dragEnabled | ||
192 | 192 | | |||
timotheegiet: Better put that at the beginning of the onPressed | |||||
193 | onPressed: { | 193 | onPressed: { | ||
194 | message.text = "" | ||||
194 | if(masseModel.contains(parent.masseIndex)) { | 195 | if(masseModel.contains(parent.masseIndex)) { | ||
195 | parent.initDrag() | 196 | parent.initDrag() | ||
196 | } | 197 | } | ||
197 | else { | 198 | else { | ||
198 | setAllZonesDropEnabled(false) | 199 | setAllZonesDropEnabled(false) | ||
199 | } | 200 | } | ||
200 | } | 201 | } | ||
201 | 202 | | |||
▲ Show 20 Lines • Show All 84 Lines • Show Last 20 Lines |
Better put that at the beginning of the onPressed