зеркало из https://github.com/mozilla/pjs.git
Fix bug#309770 (refresh urltimer bug). added a new member (the reload policy) to CHTMLView so that it can be set correctly in SpendTime(). Now passing the eitire URL_Struct to SetURLTimer() to avoid long param lists.
This commit is contained in:
Родитель
cd6d3fdd6f
Коммит
227c6a7cb1
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -724,7 +724,7 @@ void CHTMLView::SpendTime(const EventRecord& /* inMacEvent */)
|
|||
( XP_IsContextBusy(*mContext) == false) &&
|
||||
CFrontApp::GetApplication() && CFrontApp::GetApplication()->HasProperlyStartedUp())
|
||||
{
|
||||
URL_Struct * request = NET_CreateURLStruct (mTimerURLString, NET_NORMAL_RELOAD);
|
||||
URL_Struct * request = NET_CreateURLStruct (mTimerURLString, mTimerURLReloadPolicy);
|
||||
ClearTimerURL(); // ...frees mTimerURLString, so must do this _after_ |NET_CreateURLStruct|.
|
||||
if (request)
|
||||
{
|
||||
|
@ -4801,13 +4801,17 @@ void CHTMLView::DoDragSendData(FlavorType inFlavor,
|
|||
//
|
||||
// ÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑ
|
||||
|
||||
void CHTMLView::SetTimerURL(Uint32 inSeconds, const char* inURL)
|
||||
void CHTMLView::SetTimerURL(const URL_Struct* inURL)
|
||||
{
|
||||
if (inURL)
|
||||
mTimerURLString = XP_STRDUP(inURL);
|
||||
mTimerURLString = XP_STRDUP(inURL->refresh_url);
|
||||
else
|
||||
return;
|
||||
mTimerURLFireTime = ::TickCount() + inSeconds * 60;
|
||||
mTimerURLFireTime = ::TickCount() + inURL->refresh * 60;
|
||||
if ( inURL->dont_cache )
|
||||
mTimerURLReloadPolicy = NET_SUPER_RELOAD;
|
||||
else
|
||||
mTimerURLReloadPolicy = inURL->force_reload;
|
||||
StartRepeating();
|
||||
}
|
||||
|
||||
|
|
|
@ -250,7 +250,7 @@ class CHTMLView :
|
|||
virtual void ImageToAvailScreenPoint(const SPoint32 &inImagePoint, Point &outPoint) const;
|
||||
// TIMER URL
|
||||
|
||||
virtual void SetTimerURL(Uint32 inSeconds, const char* inURL);
|
||||
virtual void SetTimerURL(const URL_Struct* inURL);
|
||||
virtual void ClearTimerURL(void);
|
||||
|
||||
inline CCharSet GetCharSet() { return mCharSet; }
|
||||
|
@ -796,6 +796,7 @@ class CHTMLView :
|
|||
|
||||
Uint32 mTimerURLFireTime;
|
||||
char* mTimerURLString;
|
||||
NET_ReloadMethod mTimerURLReloadPolicy;
|
||||
|
||||
CRouterDrawable* mOnscreenDrawable;
|
||||
COffscreenDrawable* mOffscreenDrawable;
|
||||
|
|
Загрузка…
Ссылка в новой задаче