Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7947183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T01:21:36+00:00 2026-06-04T01:21:36+00:00

iPad – iOS 5.1 – Xcode 4.3.2 When the keyboard pop ups I animate

  • 0

iPad – iOS 5.1 – Xcode 4.3.2

When the keyboard pop ups I animate the y origin of my UIImageView up by “x”
When the keyboard goes down, i animate it back down by the same “x”

So the keyboard pops up, the image goes up by X, the keyboard comes down, the image goes down by x, but it doesn’t end up in the same place!. You go up 60, down 60, and you’re not in the same place! it’s further down, as if the coordinate system changed between the appearance of the keyboard and the disappearance of it. It absolutely drives me crazy. I can’t understand why this happens.

//add gesture recognizer when keyboard appears
-(void)keyboardWillShow:(NSNotification *) note {

    [self.view addGestureRecognizer:tapRecognizer];

    // Setup the animation
    [UIView beginAnimations:nil context:NULL];
    [UIView setAnimationDuration:0.3f];
    [UIView setAnimationCurve:UIViewAnimationOptionCurveEaseInOut];
    [UIView setAnimationBeginsFromCurrentState:YES];

    // The transform matrix: Logo Image

    CGAffineTransform moveLogo = CGAffineTransformMakeTranslation(0, -60);
    self.logoImageView.transform = moveLogo;

    // Commit the changes
    [UIView commitAnimations];  
}

//add gesture recognizer when keyboard appears
-(void)keyboardWillHide:(NSNotification *) note {

    [self.view removeGestureRecognizer:tapRecognizer];

    // Setup the animation
    [UIView beginAnimations:nil context:NULL];
    [UIView setAnimationDuration:0.3f];
    [UIView setAnimationCurve:UIViewAnimationOptionCurveEaseInOut];
    [UIView setAnimationBeginsFromCurrentState:YES];

    // The transform matrix: Logo Image

    CGAffineTransform moveLogo = CGAffineTransformMakeTranslation(0, 60);
    self.logoImageView.transform = moveLogo;

    // Commit the changes
    [UIView commitAnimations];  
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T01:21:38+00:00Added an answer on June 4, 2026 at 1:21 am

    That’s because you are not translating it, when you use CGAffineTransformMakeTranslation you are saying Give me these coordinates not give me this offset. In other words, make translation gives you the translation from the identity matrix. The function you want is CGAffineTransformTranslate. This will apply the translation to the current transform (passed as the first argument).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an iPad app which is for both iOS 4 and iOS 5.
The iPad/iOS has video streaming support for e.g. H.264 using MPMoviePlayerController etc., but i
My iPad app uses an external device that acts as a hardware keyboard. But,
In iPad ios 5.1, https://s140452.gridserver.com/property/4123 (in landscape view) Clicking the show details button takes
The iPad application I'm working on requires that the user provide a username and
I'm creating an iPad application which needs a UIPopoverController like this one (I mean,
I am developing an iPad application in which I need a table view (
I'm designing an iPad/iPhone app using core data. The main focus of the app
In an iPad app, I'm using a custom subclass of UIView with UIViewController. Here's
I'm building an iPad app, and would like to use a tiled display with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.