mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 06:15:04 +00:00
(svn r13323) -Codechange: scrollbars are not refresh counters
This commit is contained in:
parent
22d7b25296
commit
2a816fb685
@ -1304,10 +1304,10 @@ struct PlayerCompanyWindow : Window
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void OnTick()
|
virtual void OnHundredthTick()
|
||||||
{
|
{
|
||||||
/* redraw the window every now and then */
|
/* redraw the window every now and then */
|
||||||
if ((++this->vscroll.pos & 0x1F) == 0) this->SetDirty();
|
this->SetDirty();
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void OnPlaceObject(Point pt, TileIndex tile)
|
virtual void OnPlaceObject(Point pt, TileIndex tile)
|
||||||
|
@ -574,6 +574,7 @@ class SmallMapWindow : public Window
|
|||||||
int32 scroll_x;
|
int32 scroll_x;
|
||||||
int32 scroll_y;
|
int32 scroll_y;
|
||||||
int32 subscroll;
|
int32 subscroll;
|
||||||
|
uint8 refresh;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
@ -1019,7 +1020,7 @@ public:
|
|||||||
virtual void OnTick()
|
virtual void OnTick()
|
||||||
{
|
{
|
||||||
/* update the window every now and then */
|
/* update the window every now and then */
|
||||||
if ((++this->vscroll.pos & 0x1F) == 0) this->SetDirty();
|
if ((++this->refresh & 0x1F) == 0) this->SetDirty();
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void OnScroll(Point delta)
|
virtual void OnScroll(Point delta)
|
||||||
|
Loading…
Reference in New Issue
Block a user