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 7952747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T02:57:04+00:00 2026-06-04T02:57:04+00:00

The following code works. It animates all those components nicely CGRect logoRect = self.logoImageView.frame;

  • 0

The following code works. It animates all those components nicely

CGRect logoRect = self.logoImageView.frame;
CGRect loginBackgroundRect = self.loginControlsBkImageView.frame;
CGRect loginButtonRect = self.loginButton.frame;
CGRect tableViewRect = self.tableView.frame;
CGRect forgotPasswordRect = self.forgotButton.frame;
CGRect signupButtonRect = self.signUpButton.frame;


if (!iPhone) {

    // ipad keyboard-on-screen re-layout

    logoRect.origin.y-= 60;
    loginBackgroundRect.origin.y-= 110;
    loginButtonRect.origin.y-=110;
    tableViewRect.origin.y-=110;
    forgotPasswordRect.origin.y-=110;
    signupButtonRect.origin.y-=200;

}
else {

    // iphone keyboard-on-screen re-layout

    if (portrait) {
        logoRect.origin.y-=17;
        logoRect.origin.x-=50;
        loginBackgroundRect.origin.y-= 70;
        loginButtonRect.origin.y-=70;
        tableViewRect.origin.y-=70;
        forgotPasswordRect.origin.y-=70;
        //signupButtonRect.origin.y+=200; // get off screen!
    } else {
        logoRect.origin.y-= 30;
        loginBackgroundRect.origin.y-= 25;
        loginButtonRect.origin.y-=25;
        tableViewRect.origin.y-=25;
    }
}    


[UIView animateWithDuration:0.2f
                      delay:0.0f
                    options:UIViewAnimationOptionCurveEaseIn
                 animations:^(void) {
                     self.logoImageView.frame = logoRect;
                     self.loginControlsBkImageView.frame = loginBackgroundRect;
                     self.loginButton.frame = loginButtonRect;
                     self.tableView.frame = tableViewRect;
                     self.forgotButton.frame = forgotPasswordRect;
                     self.signUpButton.frame = signupButtonRect;
                 }
                 completion:NULL];

Take the following code and add one line (see below) to animate the WIDTH of the logoImageView… and puff… only the logoImageView animation works – the rest simply doesn’t move. as if the frame size animation causes everything else not to animate if in the same animation block.

if (portrait) {
        logoRect.origin.y-=17;
        logoRect.origin.x-=50;
        loginBackgroundRect.origin.y-= 70;
        loginButtonRect.origin.y-=70;
        tableViewRect.origin.y-=70;
        forgotPasswordRect.origin.y-=70;
        //signupButtonRect.origin.y+=200; // get off screen!
    } else {
        logoRect.origin.y-= 30;
        logoRect.size.width-= 30;   // <------- LINE BEING ADDED HERE

        loginBackgroundRect.origin.y-= 25;
        loginButtonRect.origin.y-=25;
        tableViewRect.origin.y-=25;
    }

I’m at a loss here. Does anyone know what’s going on?

  • 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-04T02:57:05+00:00Added an answer on June 4, 2026 at 2:57 am

    Try to change whole frame, not just width. It should work.

    Put these lines before commiting animation (not in block):

    self.logoImageView.frame = logoRect;
    etc.
    

    And instead of using animate method try to use commit animations this way:

    [UIView beginAnimations:nil context:nil];
    [UIView setAnimationDuration:0.75];
    // Here some more animation settings
    // Here your animations 
    [UIView commitAnimations];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The following piece of code works perfectly in all browsers, bar IE. As usual.
In the following code, the animate() function in click() works. However, animate() or pulse()
// following code works fine n open notepad... class demo { public static void
The following code works just fine: #include <exception> using namespace std; class FileException :
The following code works. What I'd like to do is change it from accepting
The following code works just fine. But it seems so verbose, surely there is
The following code works, but I'm wondering if the MemoryStream created is closed properly.
The following code works great in IE, but not in FF or Safari. I
The following code works for 90+ % of global security groups, but for one
The following code works fine: person = {:a=>:A, :b=>:B, :c=>:C} berson = {:a=>:A1, :b=>:B1,

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.