2
# -*- coding: utf-8 -*-
5
# Xibo - Digitial Signage - http://www.xibo.org.uk
6
# Copyright (C) 2010 Alex Harrington
8
# This file is part of Xibo.
10
# Xibo is free software: you can redistribute it and/or modify
11
# it under the terms of the GNU Affero General Public License as published by
12
# the Free Software Foundation, either version 3 of the License, or
15
# Xibo is distributed in the hope that it will be useful,
16
# but WITHOUT ANY WARRANTY; without even the implied warranty of
17
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18
# GNU Affero General Public License for more details.
20
# You should have received a copy of the GNU Affero General Public License
21
# along with Xibo. If not, see <http://www.gnu.org/licenses/>.
28
from BrowserMediaAnimatedBase import BrowserMediaAnimatedBase
29
from threading import Thread
31
class TextMedia(BrowserMediaAnimatedBase):
34
# Parse out the text element from the raw tag.
36
for t in self.rawNode.getElementsByTagName('text'):
39
for node in self.textNode.childNodes:
40
if node.nodeType == node.CDATA_SECTION_NODE:
41
self.text = node.data.encode('UTF-8')
42
self.log.log(5,'audit','Text is: ' + self.text)
44
self.log.log(2,'error','%s Error parsing out the text from the xlf' % self.mediaNodeName)