Opened 12 years ago

Closed 9 years ago

#3778 closed enhancement (fixed)

Load images when they are needed

Reported by: humitos Owned by: humitos
Priority: Unspecified by Maintainer Milestone: Unspecified
Component: TypingTurtle Version: Unspecified
Severity: Unspecified Keywords:
Cc: godiard Distribution/OS: Unspecified
Bug Status: Unconfirmed


Typing Turtle is loading all the SVG images (62 images) at startup. This makes the activity to spend some time at the beggining and to consume to much memory.

I think it should load the SVG images at the moment they are needed by the activity.

This is the chunk of code ( L#138) that is doing this work:

for filename in glob.iglob('images/OLPC*.svg'):
    image = GdkPixbuf.Pixbuf.new_from_file_at_scale(
        filename, scale_width, self.height, False)
    name = os.path.basename(filename)
    self.images[name] = image

Change History (1)

comment:1 Changed 9 years ago by godiard

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.