OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
544 if (documentOrigin->toRawString() == securityOrigin) | 544 if (documentOrigin->toRawString() == securityOrigin) |
545 return frame; | 545 return frame; |
546 } | 546 } |
547 return 0; | 547 return 0; |
548 } | 548 } |
549 | 549 |
550 } // namespace | 550 } // namespace |
551 | 551 |
552 void InspectorIndexedDBAgent::provideTo(Page* page) | 552 void InspectorIndexedDBAgent::provideTo(Page* page) |
553 { | 553 { |
554 OwnPtr<InspectorIndexedDBAgent> agent(adoptPtr(new InspectorIndexedDBAgent(p
age))); | 554 OwnPtrWillBeRawPtr<InspectorIndexedDBAgent> agent(adoptPtrWillBeNoop(new Ins
pectorIndexedDBAgent(page))); |
555 page->inspectorController().registerModuleAgent(agent.release()); | 555 page->inspectorController().registerModuleAgent(agent.release()); |
556 } | 556 } |
557 | 557 |
558 InspectorIndexedDBAgent::InspectorIndexedDBAgent(Page* page) | 558 InspectorIndexedDBAgent::InspectorIndexedDBAgent(Page* page) |
559 : InspectorBaseAgent<InspectorIndexedDBAgent>("IndexedDB") | 559 : InspectorBaseAgent<InspectorIndexedDBAgent>("IndexedDB") |
560 , m_page(page) | 560 , m_page(page) |
561 { | 561 { |
562 } | 562 } |
563 | 563 |
564 InspectorIndexedDBAgent::~InspectorIndexedDBAgent() | 564 InspectorIndexedDBAgent::~InspectorIndexedDBAgent() |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
764 IDBFactory* idbFactory = assertIDBFactory(errorString, document); | 764 IDBFactory* idbFactory = assertIDBFactory(errorString, document); |
765 if (!idbFactory) | 765 if (!idbFactory) |
766 return; | 766 return; |
767 | 767 |
768 ScriptState* scriptState = ScriptState::forMainWorld(frame); | 768 ScriptState* scriptState = ScriptState::forMainWorld(frame); |
769 ScriptState::Scope scope(scriptState); | 769 ScriptState::Scope scope(scriptState); |
770 RefPtr<ClearObjectStore> clearObjectStore = ClearObjectStore::create(scriptS
tate, objectStoreName, requestCallback); | 770 RefPtr<ClearObjectStore> clearObjectStore = ClearObjectStore::create(scriptS
tate, objectStoreName, requestCallback); |
771 clearObjectStore->start(idbFactory, document->securityOrigin(), databaseName
); | 771 clearObjectStore->start(idbFactory, document->securityOrigin(), databaseName
); |
772 } | 772 } |
773 | 773 |
| 774 void InspectorIndexedDBAgent::trace(Visitor* visitor) |
| 775 { |
| 776 visitor->trace(m_page); |
| 777 InspectorBaseAgent::trace(visitor); |
| 778 } |
| 779 |
774 } // namespace WebCore | 780 } // namespace WebCore |
OLD | NEW |