OLD | NEW |
1 /* | 1 /* |
2 * This file is part of the XSL implementation. | 2 * This file is part of the XSL implementation. |
3 * | 3 * |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple, Inc. All rights reserved. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple, Inc. All rights reserved. |
5 * Copyright (C) 2005, 2006 Alexey Proskuryakov <ap@webkit.org> | 5 * Copyright (C) 2005, 2006 Alexey Proskuryakov <ap@webkit.org> |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 14 matching lines...) Expand all Loading... |
25 | 25 |
26 #include "core/FetchInitiatorTypeNames.h" | 26 #include "core/FetchInitiatorTypeNames.h" |
27 #include "core/dom/Document.h" | 27 #include "core/dom/Document.h" |
28 #include "core/dom/TransformSource.h" | 28 #include "core/dom/TransformSource.h" |
29 #include "core/editing/markup.h" | 29 #include "core/editing/markup.h" |
30 #include "core/fetch/Resource.h" | 30 #include "core/fetch/Resource.h" |
31 #include "core/fetch/ResourceFetcher.h" | 31 #include "core/fetch/ResourceFetcher.h" |
32 #include "core/frame/FrameConsole.h" | 32 #include "core/frame/FrameConsole.h" |
33 #include "core/frame/FrameHost.h" | 33 #include "core/frame/FrameHost.h" |
34 #include "core/frame/LocalFrame.h" | 34 #include "core/frame/LocalFrame.h" |
| 35 #include "core/inspector/ConsoleMessage.h" |
35 #include "core/xml/XSLStyleSheet.h" | 36 #include "core/xml/XSLStyleSheet.h" |
36 #include "core/xml/XSLTExtensions.h" | 37 #include "core/xml/XSLTExtensions.h" |
37 #include "core/xml/XSLTUnicodeSort.h" | 38 #include "core/xml/XSLTUnicodeSort.h" |
38 #include "core/xml/parser/XMLDocumentParser.h" | 39 #include "core/xml/parser/XMLDocumentParser.h" |
39 #include "platform/SharedBuffer.h" | 40 #include "platform/SharedBuffer.h" |
40 #include "platform/network/ResourceError.h" | 41 #include "platform/network/ResourceError.h" |
41 #include "platform/network/ResourceRequest.h" | 42 #include "platform/network/ResourceRequest.h" |
42 #include "platform/network/ResourceResponse.h" | 43 #include "platform/network/ResourceResponse.h" |
43 #include "platform/weborigin/SecurityOrigin.h" | 44 #include "platform/weborigin/SecurityOrigin.h" |
44 #include "wtf/Assertions.h" | 45 #include "wtf/Assertions.h" |
(...skipping 27 matching lines...) Expand all Loading... |
72 case XML_ERR_WARNING: | 73 case XML_ERR_WARNING: |
73 level = WarningMessageLevel; | 74 level = WarningMessageLevel; |
74 break; | 75 break; |
75 case XML_ERR_ERROR: | 76 case XML_ERR_ERROR: |
76 case XML_ERR_FATAL: | 77 case XML_ERR_FATAL: |
77 default: | 78 default: |
78 level = ErrorMessageLevel; | 79 level = ErrorMessageLevel; |
79 break; | 80 break; |
80 } | 81 } |
81 | 82 |
82 console->addMessage(XMLMessageSource, level, error->message, error->file, er
ror->line); | 83 console->addMessage(ConsoleMessage::create(XMLMessageSource, level, error->m
essage, error->file, error->line)); |
83 } | 84 } |
84 | 85 |
85 // FIXME: There seems to be no way to control the ctxt pointer for loading here,
thus we have globals. | 86 // FIXME: There seems to be no way to control the ctxt pointer for loading here,
thus we have globals. |
86 static XSLTProcessor* globalProcessor = 0; | 87 static XSLTProcessor* globalProcessor = 0; |
87 static ResourceFetcher* globalResourceFetcher = 0; | 88 static ResourceFetcher* globalResourceFetcher = 0; |
88 | 89 |
89 static xmlDocPtr docLoaderFunc( | 90 static xmlDocPtr docLoaderFunc( |
90 const xmlChar* uri, xmlDictPtr, int options, void* ctxt, xsltLoadType type) | 91 const xmlChar* uri, xmlDictPtr, int options, void* ctxt, xsltLoadType type) |
91 { | 92 { |
92 if (!globalProcessor) | 93 if (!globalProcessor) |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
342 | 343 |
343 sheet->method = origMethod; | 344 sheet->method = origMethod; |
344 setXSLTLoadCallBack(0, 0, 0); | 345 setXSLTLoadCallBack(0, 0, 0); |
345 xsltFreeStylesheet(sheet); | 346 xsltFreeStylesheet(sheet); |
346 m_stylesheet = nullptr; | 347 m_stylesheet = nullptr; |
347 | 348 |
348 return success; | 349 return success; |
349 } | 350 } |
350 | 351 |
351 } // namespace WebCore | 352 } // namespace WebCore |
OLD | NEW |