main/ holds the main window and top bar, quiz/ the quiz and its parts, player/ the music player, popups/ every popup and what they share, data/ the songs, players, playlist and settings, server/ the MusicServer client, common/ the list row and GameLog, and themes/ the themes and style boxes.
13 lines
348 B
GDScript
13 lines
348 B
GDScript
class_name ScrollToEndContainer
|
|
extends ScrollContainer
|
|
## A scroll container that scrolls to the end whenever its content grows, so the newest
|
|
## item is always in view.
|
|
|
|
var max_value: float = 0.0
|
|
|
|
|
|
func _draw() -> void:
|
|
if max_value != get_v_scroll_bar().max_value:
|
|
max_value = get_v_scroll_bar().max_value
|
|
scroll_vertical = int(max_value)
|