Home | Trees | Indices | Help |
---|
|
1 # -*- coding: utf-8 -*- 2 # Elisa - Home multimedia server 3 # Copyright (C) 2006-2008 Fluendo Embedded S.L. (www.fluendo.com). 4 # All rights reserved. 5 # 6 # This file is available under one of two license agreements. 7 # 8 # This file is licensed under the GPL version 3. 9 # See "LICENSE.GPL" in the root of this distribution including a special 10 # exception to use Elisa with Fluendo's plugins. 11 # 12 # The GPL part of Elisa is also available under a commercial licensing 13 # agreement from Fluendo. 14 # See "LICENSE.Elisa" in the root directory of this distribution package 15 # for details on that license. 16 17 from shaded_list_view import ListItem 18 from elisa.core import common 192152 53 plugin_registry = common.application.plugin_registry 54 ShadedListView = plugin_registry.get_component_class('raval:shaded_list_view') 5523 super(DetailedListItem, self).load() 24 25 self._sub_description = self._create_text() 26 self.add(self._sub_description) 27 self._sub_description.fg_color = (150, 150, 150, 255) 28 # self._sub_description.bg_color = (0, 0, 255, 255) 29 self._sub_description.visible = True 30 self._sub_description.font_height = 0.10 31 32 text_x = self.description.x 33 text_y = 0.21 34 text_width = self.description.width 35 text_height = 0.25 36 37 self._description.y = -0.01 38 self._description.font_height = 0.11 39 40 self._sub_description.position = (text_x, text_y, 0) 41 self._sub_description.size = (text_width, text_height)42 46 4957 618963 model = self.controller.model[index] 64 widget = self[index] 65 66 widget.load() 67 68 self.load_from_theme(model.theme_icon, widget.thumbnail) 69 70 text = self.frontend.translate_text(model.text) 71 sub_text = self.frontend.translate_text(model.sub_text) 72 widget.description = text 73 widget.sub_description = sub_text 74 75 uri = model.thumbnail_source 76 if uri != None: 77 self._thumbnail_source_to_image(uri, widget.thumbnail)7880 widget.unload()8183 super(DetailedShadedListView, self).element_attribute_set(position, key, 84 old_value, 85 new_value) 86 if key == "sub_text": 87 subtext = self.frontend.translate_text(new_value) 88 self[position].sub_description = subtext
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0beta1 on Wed Jan 16 19:11:01 2008 | http://epydoc.sourceforge.net |