remove '#ifndef REPEATING_TIMERS' code. This was accidentally turned back on in 9/02 after being dead from 12/01, and will now revert to using repeating timers. Affect caret, <blink>, bookmarks & search 'ping'. bug 182141, r+sr=smfr

This commit is contained in:
jrgm%netscape.com 2003-01-20 04:26:17 +00:00
Родитель d75cfd969a
Коммит b9b898a7ea
7 изменённых файлов: 0 добавлений и 61 удалений

Просмотреть файл

@ -1170,10 +1170,6 @@ void nsCaret::CaretBlinkCallback(nsITimer *aTimer, void *aClosure)
if (!theCaret) return;
theCaret->DrawCaret();
#ifndef REPEATING_TIMERS
theCaret->PrimeTimer();
#endif
}

Просмотреть файл

@ -1170,10 +1170,6 @@ void nsCaret::CaretBlinkCallback(nsITimer *aTimer, void *aClosure)
if (!theCaret) return;
theCaret->DrawCaret();
#ifndef REPEATING_TIMERS
theCaret->PrimeTimer();
#endif
}

Просмотреть файл

@ -325,13 +325,6 @@ NS_IMETHODIMP nsBlinkTimer::Notify(nsITimer *timer)
// in unison.
sBlinkTextOff = PRBool(!sBlinkTextOff);
#ifndef REPEATING_TIMERS
// XXX hack to get auto-repeating timers; restart before doing
// expensive work so that time between ticks is more even
Stop();
Start();
#endif
#ifdef NOISY_BLINK
PRTime now = PR_Now();
char buf[50];

Просмотреть файл

@ -325,13 +325,6 @@ NS_IMETHODIMP nsBlinkTimer::Notify(nsITimer *timer)
// in unison.
sBlinkTextOff = PRBool(!sBlinkTextOff);
#ifndef REPEATING_TIMERS
// XXX hack to get auto-repeating timers; restart before doing
// expensive work so that time between ticks is more even
Stop();
Start();
#endif
#ifdef NOISY_BLINK
PRTime now = PR_Now();
char buf[50];

Просмотреть файл

@ -328,16 +328,6 @@ nsThrobber::Tick()
mWidget->Invalidate(PR_TRUE);
mCompletedImages = 0;
}
#ifndef REPEATING_TIMERS
nsresult rv;
mTimer = do_CreateInstance("@mozilla.org/timer;1", &rv);
if (NS_OK == rv) {
mTimer->InitWithFuncCallback(ThrobTimerCallback, this, 33,
nsITimer::TYPE_ONE_SHOT);
}
#endif
}
nsresult

Просмотреть файл

@ -2132,19 +2132,6 @@ else
printf("nsBookmarksService::FireTimer - busy pinging.\n");
}
#endif
#ifndef REPEATING_TIMERS
if (bmks->mTimer)
{
bmks->mTimer->Cancel();
bmks->mTimer = nsnull;
}
bmks->mTimer = do_CreateInstance("@mozilla.org/timer;1", &rv);
if (NS_FAILED(rv) || (!bmks->mTimer)) return;
bmks->mTimer->InitWithFuncCallback(nsBookmarksService::FireTimer, bmks, BOOKMARK_TIMEOUT,
nsITimer::TYPE_REPEATING_SLACK);
// Note: don't addref "this" as we'll cancel the timer in the nsBookmarkService destructor
#endif
}

Просмотреть файл

@ -709,22 +709,6 @@ else
printf(" InternetSearchDataSource::FireTimer - busy pinging.\n");
}
#endif
#ifndef REPEATING_TIMERS
if (search->mTimer)
{
search->mTimer->Cancel();
search->mTimer = nsnull;
}
nsresult rv;
search->mTimer = do_CreateInstance("@mozilla.org/timer;1", &rv);
if (NS_FAILED(rv) || (!search->mTimer)) return;
search->mTimer->InitWithFuncCallback(InternetSearchDataSource::FireTimer, search,
SEARCH_UPDATE_TIMEOUT, nsITimer::TYPE_REPEATING_SLACK);
// Note: don't addref "this" as we'll cancel the timer in the InternetSearchDataSource destructor
#endif
}