Changeset 62549 in webkit
- Timestamp:
- Jul 6, 2010 8:04:35 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 21 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ChangeLog
r62483 r62549 1 2010-07-06 Ilya Tikhonovsky <loislo@chromium.org> 2 3 Reviewed by Yury Semikhatsky. 4 5 WebInspector: generator part of the patch for bug 40675. 6 On the way to Remote Debugging we want to support JSON serialization 7 on both sides of WebInspector transport. 8 As far as InspectorFrontend class is a simple proxy to WebInspector 9 it would be better to generate it from an IDL file. 10 We have generator infrastructure for binding and will reuse it for 11 new generator. 12 https://bugs.webkit.org/show_bug.cgi?id=41692 13 14 * GNUmakefile.am: 15 1 16 2010-07-05 Antti Koivisto <koivisto@iki.fi> 2 17 -
trunk/GNUmakefile.am
r62387 r62549 58 58 lib_LTLIBRARIES := 59 59 IDL_BINDINGS := 60 INSPECTOR_INTERFACES := 60 61 TEST_PROGS := 61 62 POFILES := -
trunk/WebCore/CMakeLists.txt
r62502 r62549 290 290 inspector/InjectedScriptHost.idl 291 291 inspector/InspectorBackend.idl 292 inspector/InspectorFrontend2.idl 292 293 inspector/InspectorFrontendHost.idl 293 294 inspector/JavaScriptCallFrame.idl -
trunk/WebCore/ChangeLog
r62546 r62549 1 2010-07-06 Ilya Tikhonovsky <loislo@chromium.org> 2 3 Reviewed by Yury Semikhatsky. 4 5 WebInspector: generator part of the patch for bug 40675. 6 On the way to Remote Debugging we want to support JSON serialization 7 on both sides of WebInspector transport. 8 As far as InspectorFrontend class is a simple proxy to WebInspector 9 it would be better to generate it from an IDL file. 10 We have generator infrastructure for binding and will reuse it for 11 new generator. 12 https://bugs.webkit.org/show_bug.cgi?id=41692 13 14 15 * CMakeLists.txt: 16 * DerivedSources.make: 17 * GNUmakefile.am: 18 * WebCore.gyp/WebCore.gyp: 19 * WebCore.gyp/scripts/rule_binding.py: 20 * WebCore.gypi: 21 * WebCore.pri: 22 * WebCore.vcproj/WebCore.vcproj: 23 * WebCore.xcodeproj/project.pbxproj: 24 * bindings/scripts/CodeGenerator.pm: 25 * bindings/scripts/IDLParser.pm: 26 * bindings/scripts/generate-bindings.pl: 27 * inspector/CodeGeneratorInspector.pm: Added. 28 * inspector/InspectorController.cpp: 29 (WebCore::InspectorController::connectFrontend): 30 (WebCore::InspectorController::startTimelineProfiler): 31 * inspector/InspectorController.h: 32 * inspector/InspectorFrontend.cpp: 33 * inspector/InspectorFrontend.h: 34 * inspector/InspectorFrontend2.idl: Added. 35 * inspector/InspectorTimelineAgent.cpp: 36 (WebCore::InspectorTimelineAgent::InspectorTimelineAgent): 37 (WebCore::InspectorTimelineAgent::resetFrontendProxyObject): 38 (WebCore::InspectorTimelineAgent::addRecordToTimeline): 39 * inspector/InspectorTimelineAgent.h: 40 1 41 2010-07-06 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> 2 42 -
trunk/WebCore/DerivedSources.make
r62357 r62549 471 471 # 472 472 473 INSPECTOR_CLASSES = InspectorFrontend2 474 473 475 .PHONY : all 474 476 475 JS_DOM_HEADERS=$(filter-out JSEventListener.h JSEventTarget.h,$(DOM_CLASSES:%=JS%.h) )477 JS_DOM_HEADERS=$(filter-out JSEventListener.h JSEventTarget.h,$(DOM_CLASSES:%=JS%.h) $(INSPECTOR_CLASSES:%=Remote%.h)) 476 478 477 479 all : \ … … 821 823 # -------- 822 824 823 # JavaScript bindings 824 825 GENERATE_BINDINGS = perl -I $(WebCore)/bindings/scripts $(WebCore)/bindings/scripts/generate-bindings.pl \ 826 --include dom --include html --include css --include page --include notifications --include xml --include svg --write-dependencies --outputDir . 827 828 GENERATE_BINDINGS_SCRIPTS = \ 825 # Common generator things 826 827 GENERATE_SCRIPTS = \ 829 828 bindings/scripts/CodeGenerator.pm \ 830 829 bindings/scripts/IDLParser.pm \ 831 830 bindings/scripts/IDLStructure.pm \ 832 bindings/scripts/generate-bindings.pl \ 833 # 834 835 JS%.h : %.idl $(GENERATE_BINDINGS_SCRIPTS) bindings/scripts/CodeGeneratorJS.pm 836 $(GENERATE_BINDINGS) --defines "$(FEATURE_DEFINES) $(ADDITIONAL_IDL_DEFINES) LANGUAGE_JAVASCRIPT" --generator JS $< 831 bindings/scripts/generate-bindings.pl 832 833 generator_script = perl $(addprefix -I $(WebCore)/, $(sort $(dir $(1)))) $(WebCore)/bindings/scripts/generate-bindings.pl 834 835 # JS bindings generator 836 837 IDL_INCLUDES = dom html css page notifications xml svg 838 IDL_COMMON_ARGS = $(IDL_INCLUDES:%=--include %) --write-dependencies --outputDir . 839 840 JS_BINDINGS_SCRIPTS = $(GENERATE_SCRIPTS) bindings/scripts/CodeGeneratorJS.pm 841 842 JS%.h : %.idl $(JS_BINDINGS_SCRIPTS) 843 $(call generator_script, $(JS_BINDINGS_SCRIPTS)) $(IDL_COMMON_ARGS) --defines "$(FEATURE_DEFINES) $(ADDITIONAL_IDL_DEFINES) LANGUAGE_JAVASCRIPT" --generator JS $< 844 845 # Inspector interfaces generator 846 847 INSPECTOR_GENERATOR_SCRIPTS = $(GENERATE_SCRIPTS) inspector/CodeGeneratorInspector.pm 848 849 Remote%.h : %.idl $(INSPECTOR_GENERATOR_SCRIPTS) 850 $(call generator_script, $(INSPECTOR_GENERATOR_SCRIPTS)) --outputDir . --defines "LANGUAGE_JAVASCRIPT" --generator Inspector $< 837 851 838 852 -include $(JS_DOM_HEADERS:.h=.dep) … … 939 953 # Objective-C bindings 940 954 941 DOM%.h : %.idl $(GENERATE_BINDINGS_SCRIPTS) bindings/scripts/CodeGeneratorObjC.pm bindings/objc/PublicDOMInterfaces.h 942 $(GENERATE_BINDINGS) --defines "$(FEATURE_DEFINES) $(ADDITIONAL_IDL_DEFINES) LANGUAGE_OBJECTIVE_C" --generator ObjC $< 955 DOM_BINDINGS_SCRIPTS = $(GENERATE_BINDING_SCRIPTS) bindings/scripts/CodeGeneratorObjC.pm 956 DOM%.h : %.idl $(DOM_BINDINGS_SCRIPTS) bindings/objc/PublicDOMInterfaces.h 957 $(call generator_script, $(DOM_BINDINGS_SCRIPTS)) $(IDL_COMMON_ARGS) --defines "$(FEATURE_DEFINES) $(ADDITIONAL_IDL_DEFINES) LANGUAGE_OBJECTIVE_C" --generator ObjC $< 943 958 944 959 -include $(OBJC_DOM_HEADERS:.h=.dep) -
trunk/WebCore/GNUmakefile.am
r62506 r62549 333 333 WebCore/xml/XMLSerializer.idl \ 334 334 WebCore/xml/XSLTProcessor.idl 335 336 INSPECTOR_INTERFACES += WebCore/inspector/InspectorFrontend2.idl 335 337 336 338 webcoregtk_dom_sources = \ … … 3994 3996 DerivedSources/WebCore/JS%.h: DerivedSources/WebCore/JS%.cpp; 3995 3997 3998 DerivedSources/WebCore/Remote%.h: DerivedSources/WebCore/Remote%.cpp; 3999 3996 4000 .SECONDARY: 3997 4001 DerivedSources/WebCore/JS%.cpp: %.idl $(SCRIPTS_BINDINGS) $(WebCore)/bindings/scripts/CodeGeneratorJS.pm 3998 4002 $(AM_V_GEN)$(PERL) -I$(WebCore)/bindings/scripts $(WebCore)/bindings/scripts/generate-bindings.pl $(IDL_PATH:%=--include "%") --outputDir "$(GENSOURCES_WEBCORE)" --defines "LANGUAGE_JAVASCRIPT=1 $(FEATURE_DEFINES)" --generator JS $< 4003 4004 DerivedSources/WebCore/Remote%.cpp: %.idl $(SCRIPTS_BINDINGS) $(WebCore)/inspector/CodeGeneratorInspector.pm 4005 $(AM_V_GEN)$(PERL) -I$(WebCore)/bindings/scripts -I$(WebCore)/inspector $(WebCore)/bindings/scripts/generate-bindings.pl $(IDL_PATH:%=--include "%") --outputDir "$(GENSOURCES)" --defines "LANGUAGE_JAVASCRIPT=1 $(FEATURE_DEFINES)" --generator Inspector $< 3999 4006 4000 4007 IDL_BINDINGS_JS_PURE := \ … … 4017 4024 4018 4025 webcore_built_nosources += $(patsubst %.idl,DerivedSources/WebCore/JS%.h,$(notdir $(IDL_BINDINGS))) 4019 4020 webcore_built_nosources += $(patsubst %.idl,DerivedSources/WebCore/JS%.cpp,$(notdir $(IDL_BINDINGS_JS))) 4026 webcore_built_nosources += $(patsubst %.idl,DerivedSources/WebCore/Remote%.h,$(notdir $(INSPECTOR_INTERFACES))) 4027 4028 webcore_built_cpp = $(patsubst %.idl,DerivedSources/WebCore/JS%.cpp,$(notdir $(IDL_BINDINGS_JS))) 4029 webcore_built_cpp += $(patsubst %.idl,DerivedSources/WebCore/Remote%.cpp,$(notdir $(INSPECTOR_INTERFACES))) 4030 webcore_built_nosources += $(webcore_built_cpp) 4021 4031 4022 4032 webcore_built_objects = := $(patsubst %.cpp,%.lo,$(webcore_built_nosources)) … … 4026 4036 $(webcore_built_objects): AM_CXXFLAGS+=$(libwebkitgtk_@WEBKITGTK_API_MAJOR_VERSION@_@WEBKITGTK_API_MINOR_VERSION@_la_CXXFLAGS) 4027 4037 4028 libWebCoreJS_objects := $(patsubst %. idl,DerivedSources/WebCore/JS%.lo,$(notdir $(IDL_BINDINGS_JS)))4029 4030 libWebCoreJS_depfiles := $(patsubst %. idl,DerivedSources/WebCore/$(DEPDIR)/JS%.Plo,$(notdir $(IDL_BINDINGS_JS)))4038 libWebCoreJS_objects := $(patsubst %.cpp,%.lo,$(webcore_built_cpp)) 4039 4040 libWebCoreJS_depfiles := $(patsubst %.cpp,DerivedSources/WebCore/$(DEPDIR)/%.Plo,$(notdir $(webcore_built_cpp))) 4031 4041 4032 4042 # Older automake versions (1.7) place Plo files in a different place: -
trunk/WebCore/WebCore.gyp/WebCore.gyp
r62219 r62549 455 455 }, 456 456 { 457 'action_name': 'InspectorFrontend2', 458 'inputs': [ 459 '../bindings/scripts/generate-bindings.pl', 460 '../bindings/scripts/CodeGenerator.pm', 461 '../bindings/scripts/IDLParser.pm', 462 '../bindings/scripts/IDLStructure.pm', 463 '../inspector/CodeGeneratorInspector.pm', 464 '../inspector/InspectorFrontend2.idl', 465 ], 466 'outputs': [ 467 '<(SHARED_INTERMEDIATE_DIR)/webcore/bindings/RemoteInspectorFrontend2.cpp', 468 '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings/RemoteInspectorFrontend2.h', 469 ], 470 'variables': { 471 'generator_include_dirs': [ 472 ], 473 }, 474 'action': [ 475 'python', 476 'scripts/rule_binding.py', 477 '../inspector/InspectorFrontend2.idl', 478 '<(SHARED_INTERMEDIATE_DIR)/webcore/bindings', 479 '<(SHARED_INTERMEDIATE_DIR)/webkit/bindings', 480 '--', 481 '<@(_inputs)', 482 '--', 483 '--defines', 'LANGUAGE_JAVASCRIPT', 484 '--prefix', 'Remote', 485 '--generator', 'Inspector', 486 '<@(generator_include_dirs)' 487 ], 488 'message': 'Generating InspectorFrontend2 class from InspectorFrontend2.idl', 489 }, 490 { 457 491 'action_name': 'XMLNames', 458 492 'inputs': [ … … 656 690 '<(SHARED_INTERMEDIATE_DIR)/webkit/CSSGrammar.cpp', 657 691 '<(SHARED_INTERMEDIATE_DIR)/webkit/XPathGrammar.cpp', 692 693 # Additional .cpp files from the webcore_inspector_sources list. 694 '<(SHARED_INTERMEDIATE_DIR)/webcore/bindings/RemoteInspectorFrontend2.cpp', 658 695 ], 659 696 'conditions': [ -
trunk/WebCore/WebCore.gyp/scripts/rule_binding.py
r50480 r62549 96 96 includeDirs.append(includeDir) 97 97 98 if '--prefix' in options: 99 prefixIndex = options.index('--prefix') 100 else: 101 prefixIndex = options.index('--generator') 102 103 if prefixIndex + 1 < len(options): 104 prefix = options[prefixIndex + 1] 105 98 106 # The defines come in as one flat string. Split it up into distinct arguments. 99 107 if '--defines' in options: … … 123 131 inputBasename = os.path.basename(input) 124 132 (root, ext) = os.path.splitext(inputBasename) 125 hname = ' V8%s.h' % root133 hname = '%s%s.h' % (prefix, root) 126 134 hsrc = os.path.join(cppdir, hname) 127 135 hdst = os.path.join(hdir, hname) -
trunk/WebCore/WebCore.gypi
r62502 r62549 277 277 'xml/XPathResult.idl', 278 278 'xml/XSLTProcessor.idl', 279 ], 280 'webcore_inspector_idl_files': [ 281 'inspector/InspectorFrontend2.idl', 279 282 ], 280 283 'webcore_svg_bindings_idl_files': [ -
trunk/WebCore/WebCore.pri
r62483 r62549 653 653 xml/XSLTProcessor.idl 654 654 655 INSPECTOR_INTERFACES = inspector/InspectorFrontend2.idl 656 655 657 contains(DEFINES, ENABLE_MATHML=1) { 656 658 mathmlnames.output = $${WC_GENERATED_SOURCES_DIR}/MathMLNames.cpp … … 718 720 addExtraCompiler(idl) 719 721 722 # GENERATOR 2: inspector idl compiler 723 inspectorIDL.output = $${WC_GENERATED_SOURCES_DIR}/Remote${QMAKE_FILE_BASE}.cpp 724 inspectorIDL.input = INSPECTOR_INTERFACES 725 inspectorIDL.wkScript = $$PWD/bindings/scripts/generate-bindings.pl 726 inspectorIDL.commands = perl -I$$PWD/bindings/scripts -I$$PWD/inspector $$inspectorIDL.wkScript --defines \"$${FEATURE_DEFINES_JAVASCRIPT}\" --generator Inspector --outputDir $$WC_GENERATED_SOURCES_DIR --preprocessor \"$${QMAKE_MOC} -E\" ${QMAKE_FILE_NAME} 727 inspectorIDL.depends = $$PWD/bindings/scripts/CodeGenerator.pm \ 728 $$PWD/inspector/CodeGeneratorInspector.pm \ 729 $$PWD/bindings/scripts/IDLParser.pm \ 730 $$PWD/bindings/scripts/IDLStructure.pm \ 731 $$PWD/bindings/scripts/InFilesParser.pm 732 addExtraCompiler(inspectorIDL) 733 720 734 # GENERATOR 3: tokenizer (flex) 721 735 tokenizer.output = $${WC_GENERATED_SOURCES_DIR}/${QMAKE_FILE_BASE}.cpp -
trunk/WebCore/WebCore.vcproj/WebCore.vcproj
r62502 r62549 20746 20746 </File> 20747 20747 <File 20748 RelativePath="$(WebKitOutputDir)\obj\$(ProjectName)\DerivedSources\RemoteInspectorFrontend2.cpp" 20749 > 20750 </File> 20751 <File 20752 RelativePath="$(WebKitOutputDir)\obj\$(ProjectName)\DerivedSources\RemoteInspectorFrontend2.h" 20753 > 20754 </File> 20755 <File 20748 20756 RelativePath="$(WebKitOutputDir)\obj\$(ProjectName)\DerivedSources\WMLElementFactory.cpp" 20749 20757 > -
trunk/WebCore/WebCore.xcodeproj/project.pbxproj
r62502 r62549 1020 1020 4F3289B511A42AAB005ABE7E /* InspectorValues.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4F3289B311A42AAB005ABE7E /* InspectorValues.cpp */; }; 1021 1021 4F3289B611A42AAB005ABE7E /* InspectorValues.h in Headers */ = {isa = PBXBuildFile; fileRef = 4F3289B411A42AAB005ABE7E /* InspectorValues.h */; settings = {ATTRIBUTES = (Private, ); }; }; 1022 4F4F5FFB11CBD2E100A186BF /* RemoteInspectorFrontend2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4F4F5FFA11CBD2D200A186BF /* RemoteInspectorFrontend2.cpp */; }; 1022 1023 4FD8D0F2119C718B002FA825 /* ScriptGCEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4FD8D0F0119C718B002FA825 /* ScriptGCEvent.cpp */; }; 1023 1024 4FD8D0F3119C718B002FA825 /* ScriptGCEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 4FD8D0F1119C718B002FA825 /* ScriptGCEvent.h */; }; … … 6717 6718 4F3289B311A42AAB005ABE7E /* InspectorValues.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorValues.cpp; sourceTree = "<group>"; }; 6718 6719 4F3289B411A42AAB005ABE7E /* InspectorValues.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorValues.h; sourceTree = "<group>"; }; 6720 4F4F5FFA11CBD2D200A186BF /* RemoteInspectorFrontend2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RemoteInspectorFrontend2.cpp; sourceTree = "<group>"; }; 6721 4F4F5FFC11CBD30100A186BF /* RemoteInspectorFrontend2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RemoteInspectorFrontend2.h; sourceTree = "<group>"; }; 6719 6722 4FD8D0F0119C718B002FA825 /* ScriptGCEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptGCEvent.cpp; sourceTree = "<group>"; }; 6720 6723 4FD8D0F1119C718B002FA825 /* ScriptGCEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptGCEvent.h; sourceTree = "<group>"; }; … … 11334 11337 9FA37EF81172FD9300C4CD55 /* JSScriptProfileNode.cpp */, 11335 11338 9FA37EF91172FD9300C4CD55 /* JSScriptProfileNode.h */, 11339 4F4F5FFA11CBD2D200A186BF /* RemoteInspectorFrontend2.cpp */, 11340 4F4F5FFC11CBD30100A186BF /* RemoteInspectorFrontend2.h */, 11336 11341 ); 11337 11342 name = Inspector; … … 22041 22046 97DD4D860FDF4D6E00ECF9A4 /* XSSAuditor.cpp in Sources */, 22042 22047 B885E8D411E06DD2009FFBF4 /* InspectorApplicationCacheAgent.cpp in Sources */, 22048 4F4F5FFB11CBD2E100A186BF /* RemoteInspectorFrontend2.cpp in Sources */, 22043 22049 ); 22044 22050 runOnlyForDeploymentPostprocessing = 0; -
trunk/WebCore/bindings/scripts/CodeGenerator.pm
r61413 r62549 84 84 $preprocessor = shift; 85 85 $writeDependencies = shift; 86 $verbose = shift; 86 87 87 88 bless($reference, $object); … … 104 105 105 106 my $ifaceName = "CodeGenerator" . $useGenerator; 107 require $ifaceName . ".pm"; 106 108 107 109 # Dynamically load external code generation perl module 108 require $ifaceName . ".pm"; 109 $codeGenerator = $ifaceName->new($object, $useOutputDir, $useLayerOnTop, $preprocessor, $writeDependencies); 110 $codeGenerator = $ifaceName->new($object, $useOutputDir, $useLayerOnTop, $preprocessor, $writeDependencies, $verbose); 110 111 unless (defined($codeGenerator)) { 111 112 my $classes = $useDocument->classes; -
trunk/WebCore/bindings/scripts/IDLParser.pm
r61022 r62549 260 260 261 261 foreach my $line (@interfaceMethods) { 262 if ($line =~ / attribute/) {262 if ($line =~ /\Wattribute\W/) { 263 263 $line =~ /$IDLStructure::interfaceAttributeSelector/; 264 264 -
trunk/WebCore/bindings/scripts/generate-bindings.pl
r56344 r62549 42 42 my $generator; 43 43 my $defines; 44 my $prefix; 44 45 my $preprocessor; 45 46 my $writeDependencies; 47 my $verbose; 46 48 47 49 GetOptions('include=s@' => \@idlDirectories, … … 49 51 'generator=s' => \$generator, 50 52 'defines=s' => \$defines, 53 'prefix=s' => \$prefix, 51 54 'preprocessor=s' => \$preprocessor, 55 'verbose' => \$verbose, 52 56 'write-dependencies' => \$writeDependencies); 53 57 … … 55 59 56 60 die('Must specify input file.') unless defined($idlFile); 57 die('Must specify IDL search path.') unless @idlDirectories;58 61 die('Must specify generator') unless defined($generator); 59 62 die('Must specify output directory.') unless defined($outputDirectory); 60 63 die('Must specify defines') unless defined($defines); 61 64 65 if ($verbose) { 66 print "$generator: $idlFile\n"; 67 } 62 68 $defines =~ s/^\s+|\s+$//g; # trim whitespace 63 69 64 70 # Parse the given IDL file. 65 my $parser = IDLParser->new( 1);71 my $parser = IDLParser->new(!$verbose); 66 72 my $document = $parser->Parse($idlFile, $defines, $preprocessor); 67 73 68 74 # Generate desired output for given IDL file. 69 my $codeGen = CodeGenerator->new(\@idlDirectories, $generator, $outputDirectory, 0, $preprocessor, $writeDependencies );75 my $codeGen = CodeGenerator->new(\@idlDirectories, $generator, $outputDirectory, 0, $preprocessor, $writeDependencies, $verbose); 70 76 $codeGen->ProcessDocument($document, $defines); -
trunk/WebCore/inspector/InspectorController.cpp
r62535 r62549 69 69 #include "ProgressTracker.h" 70 70 #include "Range.h" 71 #include "RemoteInspectorFrontend2.h" 71 72 #include "RenderInline.h" 72 73 #include "ResourceRequest.h" … … 486 487 releaseFrontendLifetimeAgents(); 487 488 m_frontend = new InspectorFrontend(webInspector, m_client); 489 m_frontend2 = new InspectorFrontend2(m_client); 488 490 m_domAgent = InspectorDOMAgent::create(m_cssStore.get(), m_frontend.get()); 489 491 if (m_timelineAgent) 490 m_timelineAgent->resetFrontendProxyObject(m_frontend .get());492 m_timelineAgent->resetFrontendProxyObject(m_frontend2.get()); 491 493 492 494 // Initialize Web Inspector title. … … 1162 1164 return; 1163 1165 1164 m_timelineAgent = new InspectorTimelineAgent(m_frontend .get());1166 m_timelineAgent = new InspectorTimelineAgent(m_frontend2.get()); 1165 1167 if (m_frontend) 1166 1168 m_frontend->timelineProfilerWasStarted(); -
trunk/WebCore/inspector/InspectorController.h
r62535 r62549 70 70 class InspectorDatabaseResource; 71 71 class InspectorFrontend; 72 class InspectorFrontend2; 72 73 class InspectorFrontendClient; 73 74 class InspectorResource; … … 344 345 bool m_openingFrontend; 345 346 OwnPtr<InspectorFrontend> m_frontend; 347 OwnPtr<InspectorFrontend2> m_frontend2; 346 348 RefPtr<InspectorDOMAgent> m_domAgent; 347 349 OwnPtr<InspectorCSSStore> m_cssStore; -
trunk/WebCore/inspector/InspectorFrontend.cpp
r62542 r62549 298 298 } 299 299 300 void InspectorFrontend::addRecordToTimeline(const RefPtr<InspectorObject>& record)301 {302 RefPtr<InspectorArray> arguments = InspectorArray::create();303 arguments->pushString("addRecordToTimeline");304 arguments->push(record);305 m_inspectorClient->sendMessageToFrontend(arguments->toJSONString());306 }307 308 300 #if ENABLE(JAVASCRIPT_DEBUGGER) 309 301 void InspectorFrontend::attachDebuggerWhenShown() -
trunk/WebCore/inspector/InspectorFrontend.h
r62542 r62549 172 172 void timelineProfilerWasStarted(); 173 173 void timelineProfilerWasStopped(); 174 void addRecordToTimeline(const RefPtr<InspectorObject>& record);175 174 176 175 #if ENABLE(WORKERS) -
trunk/WebCore/inspector/InspectorTimelineAgent.cpp
r62542 r62549 35 35 36 36 #include "Event.h" 37 #include "InspectorFrontend.h"38 37 #include "IntRect.h" 38 #include "RemoteInspectorFrontend2.h" 39 39 #include "ResourceRequest.h" 40 40 #include "ResourceResponse.h" … … 47 47 int InspectorTimelineAgent::s_instanceCount = 0; 48 48 49 InspectorTimelineAgent::InspectorTimelineAgent(InspectorFrontend * frontend)49 InspectorTimelineAgent::InspectorTimelineAgent(InspectorFrontend2* frontend) 50 50 : m_frontend(frontend) 51 51 { … … 280 280 } 281 281 282 void InspectorTimelineAgent::resetFrontendProxyObject(InspectorFrontend * frontend)282 void InspectorTimelineAgent::resetFrontendProxyObject(InspectorFrontend2* frontend) 283 283 { 284 284 ASSERT(frontend); -
trunk/WebCore/inspector/InspectorTimelineAgent.h
r62542 r62549 43 43 namespace WebCore { 44 44 class Event; 45 class InspectorFrontend ;45 class InspectorFrontend2; 46 46 class IntRect; 47 47 class ResourceRequest; … … 75 75 class InspectorTimelineAgent : ScriptGCEventListener, public Noncopyable { 76 76 public: 77 InspectorTimelineAgent(InspectorFrontend * frontend);77 InspectorTimelineAgent(InspectorFrontend2* frontend); 78 78 ~InspectorTimelineAgent(); 79 79 80 80 void reset(); 81 void resetFrontendProxyObject(InspectorFrontend *);81 void resetFrontendProxyObject(InspectorFrontend2*); 82 82 83 83 // Methods called from WebCore. … … 153 153 void pushGCEventRecords(); 154 154 155 InspectorFrontend * m_frontend;155 InspectorFrontend2* m_frontend; 156 156 157 157 Vector<TimelineRecordEntry> m_recordStack;
Note: See TracChangeset
for help on using the changeset viewer.