Skip to content

Commit

Permalink
Removed buggy button animation.
Browse files Browse the repository at this point in the history
  • Loading branch information
jimweirich committed Aug 10, 2012
1 parent b63c090 commit b155a30
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions app/ppbot_view_controller.rb
Expand Up @@ -76,21 +76,14 @@ def doneTapped

def transition
delay = 0.25
UIView.animateWithDuration(delay,
animations: lambda { @q1.alpha = 0; @q2.alpha = 0 },
completion: lambda { |finished|
@state.establish(self)
UIView.animateWithDuration(delay,
animations: lambda { @q1.alpha = 1; @q2.alpha = 1 },
completion: lambda { |finished| delayed_show_buttons })
})

@state.establish(self)
show_buttons
end

def restart
@state = States::HaveTestState.instance
@state.establish(self)
delayed_show_buttons
show_buttons
end

def swipeGesture(gesture)
Expand All @@ -108,7 +101,7 @@ def doit(action, more_action=nil)
@asking = false
end

def delayed_show_buttons
def show_buttons
@yes_button.hidden = ! @asking
@no_button.hidden = ! @asking
@done_button.hidden = @asking
Expand Down

0 comments on commit b155a30

Please sign in to comment.