Skip to content

Commit

Permalink
Merge pull request #1377 from alvinhochun/fix-touch
Browse files Browse the repository at this point in the history
Fix touch point not properly updated on move
  • Loading branch information
mitchmindtree authored Aug 18, 2020
2 parents 7a18b9c + 89a688f commit 9dc5531
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions conrod_core/src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -839,14 +839,14 @@ impl Ui {

// Update the widget under the touch and return the widget capturing the touch.
let widget = match self.global_input.current.touch.get_mut(&touch.id) {
Some(touch) => {
touch.widget =
Some(touch_state) => {
touch_state.widget =
graph::algo::pick_widgets(&self.depth_order.indices, touch.xy)
.next(&self.widget_graph,
&self.depth_order.indices,
&self.theme);
touch.xy = touch.xy;
touch.start.widget
touch_state.xy = touch.xy;
touch_state.start.widget
},
None => None,
};
Expand Down

0 comments on commit 9dc5531

Please sign in to comment.