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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T11:54:30+00:00 2026-05-13T11:54:30+00:00

I have a question that we might answer together i have a tickertape in

  • 0

I have a question that we might answer together i have a tickertape in my iphone app (Like those stick tickers) and i use a NSThread to keep the memory away from the main thread so it will not slow down the app. Now the thing is it does its job well but when i scroll on a UITableView that i have on the same view i notice that my ticker tape animation stops to work.

ViewController.m (Main view of this object has the ticker tape on it)

-(void)startTicker {
  [NSThread detachNewThreadSelector:@selector(start) toTarget:ticker withObject:nil];
}

TickerView.c (This handles the tickertape animation)

// Called from the viewcontroller

-(void) start {
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
    [self performSelectorOnMainThread:@selector(loop) withObject:nil waitUntilDone:YES];
        [pool release];
}

-(void)loop {
timerHandle = [NSTimer scheduledTimerWithTimeInterval:.01f target:self selector:@selector(render) userInfo:nil repeats:YES];
}

-(void) render {
   // Does a *** load of calculations here and moves the items in the tickertape..
}

My Question: How can i prevent the UITableview or any other view / touch event to block this thread from updating the tickertape animation ?.

  • 1 1 Answer
  • 1 View
  • 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-05-13T11:54:30+00:00Added an answer on May 13, 2026 at 11:54 am

    Your NSTimer is not running on a background thread, but on the main thread. It will block anytime something else runs on the main thread. -performSelectorOnMainThread: means that anything done within the method called will run on the main thread.

    To make your loop truly independent of the main thread, you could set up a while loop within your start method that sleeps for a given interval on every pass, then calls your render method. You’d need to make sure that all user interface updates within your render method get performed on the main thread, but make waitUntilDone NO for those method calls. I’ve also done this using NSOperations, where as one operation finishes I add another to the queue.

    Also, running this render operation 100 times per second is excessive. I’d back that down a bit, or even better, look at using Core Animation for your ticker to make your drawing more efficient.

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

Sidebar

Related Questions

I know that this question might have been asked like 100 times, but, believe
This is kind of a 'double' question that might have a single answer. I'm
Beginner level question Scenario: Have simple string cocantation tool, that I might expand later
I have a question that I just don't feel like I've found a satisfactory
I have a question that can I use AS400ConnectionPool in Spring if then pls
I have a question that most of you might find a little odd. I
I have a question that I can't quite find the answer to... If you
I have a question that might seem simple, but yet I was unable to
That might be silly question but I really need to know the answer. If
There might be similar questions but I still have some parts that I couldn't

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.