Skip to content

Commit

Permalink
Add type hints to scene/moving_camera_scene.py
Browse files Browse the repository at this point in the history
  • Loading branch information
fmuenkel committed Jan 22, 2025
1 parent 8ff2b35 commit 2f28e69
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions manim/scene/moving_camera_scene.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,10 @@ def create_scene(number):

__all__ = ["MovingCameraScene"]

from typing import Any

from manim.animation.animation import Animation
from manim.mobject.mobject import Mobject

from ..camera.moving_camera import MovingCamera
from ..scene.scene import Scene
Expand All @@ -111,10 +114,12 @@ class MovingCameraScene(Scene):
:class:`.MovingCamera`
"""

def __init__(self, camera_class=MovingCamera, **kwargs):
def __init__(
self, camera_class: type[MovingCamera] = MovingCamera, **kwargs: Any
) -> None:
super().__init__(camera_class=camera_class, **kwargs)

def get_moving_mobjects(self, *animations: Animation):
def get_moving_mobjects(self, *animations: Animation) -> list[Mobject]:
"""
This method returns a list of all of the Mobjects in the Scene that
are moving, that are also in the animations passed.
Expand Down

0 comments on commit 2f28e69

Please sign in to comment.