OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 } | 210 } |
211 | 211 |
212 void InspectorDatabaseAgent::didCommitLoad(Frame* frame, DocumentLoader* loader) | 212 void InspectorDatabaseAgent::didCommitLoad(Frame* frame, DocumentLoader* loader) |
213 { | 213 { |
214 if (loader->frame() != frame->page()->mainFrame()) | 214 if (loader->frame() != frame->page()->mainFrame()) |
215 return; | 215 return; |
216 | 216 |
217 m_resources.clear(); | 217 m_resources.clear(); |
218 } | 218 } |
219 | 219 |
220 InspectorDatabaseAgent::InspectorDatabaseAgent(InstrumentingAgents* instrumentin
gAgents, InspectorCompositeState* state) | 220 InspectorDatabaseAgent::InspectorDatabaseAgent(InstrumentingAgents* instrumentin
gAgents, InspectorState* state) |
221 : InspectorBaseAgent<InspectorDatabaseAgent>("Database", instrumentingAgents
, state) | 221 : InspectorBaseAgent(instrumentingAgents, state) |
222 , m_enabled(false) | 222 , m_enabled(false) |
223 { | 223 { |
224 m_instrumentingAgents->setInspectorDatabaseAgent(this); | 224 m_instrumentingAgents->setInspectorDatabaseAgent(this); |
225 } | 225 } |
226 | 226 |
227 InspectorDatabaseAgent::~InspectorDatabaseAgent() | 227 InspectorDatabaseAgent::~InspectorDatabaseAgent() |
228 { | 228 { |
229 m_instrumentingAgents->setInspectorDatabaseAgent(0); | 229 m_instrumentingAgents->setInspectorDatabaseAgent(0); |
230 } | 230 } |
231 | 231 |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 | 324 |
325 Database* InspectorDatabaseAgent::databaseForId(const String& databaseId) | 325 Database* InspectorDatabaseAgent::databaseForId(const String& databaseId) |
326 { | 326 { |
327 DatabaseResourcesMap::iterator it = m_resources.find(databaseId); | 327 DatabaseResourcesMap::iterator it = m_resources.find(databaseId); |
328 if (it == m_resources.end()) | 328 if (it == m_resources.end()) |
329 return 0; | 329 return 0; |
330 return it->value->database(); | 330 return it->value->database(); |
331 } | 331 } |
332 | 332 |
333 } // namespace WebCore | 333 } // namespace WebCore |
OLD | NEW |