| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 24 matching lines...) Expand all Loading... |
| 35 #include "core/frame/Navigator.h" | 35 #include "core/frame/Navigator.h" |
| 36 #include "core/loader/FrameLoaderClient.h" | 36 #include "core/loader/FrameLoaderClient.h" |
| 37 | 37 |
| 38 namespace blink { | 38 namespace blink { |
| 39 | 39 |
| 40 NavigatorDoNotTrack::NavigatorDoNotTrack(LocalFrame* frame) | 40 NavigatorDoNotTrack::NavigatorDoNotTrack(LocalFrame* frame) |
| 41 : DOMWindowProperty(frame) | 41 : DOMWindowProperty(frame) |
| 42 { | 42 { |
| 43 } | 43 } |
| 44 | 44 |
| 45 NavigatorDoNotTrack::~NavigatorDoNotTrack() | 45 DEFINE_EMPTY_DESTRUCTOR_WILL_BE_REMOVED(NavigatorDoNotTrack); |
| 46 |
| 47 void NavigatorDoNotTrack::trace(Visitor* visitor) |
| 46 { | 48 { |
| 49 WillBeHeapSupplement<Navigator>::trace(visitor); |
| 50 DOMWindowProperty::trace(visitor); |
| 47 } | 51 } |
| 48 | 52 |
| 49 const char* NavigatorDoNotTrack::supplementName() | 53 const char* NavigatorDoNotTrack::supplementName() |
| 50 { | 54 { |
| 51 return "NavigatorDoNotTrack"; | 55 return "NavigatorDoNotTrack"; |
| 52 } | 56 } |
| 53 | 57 |
| 54 NavigatorDoNotTrack& NavigatorDoNotTrack::from(Navigator& navigator) | 58 NavigatorDoNotTrack& NavigatorDoNotTrack::from(Navigator& navigator) |
| 55 { | 59 { |
| 56 NavigatorDoNotTrack* supplement = static_cast<NavigatorDoNotTrack*>(WillBeHe
apSupplement<Navigator>::from(navigator, supplementName())); | 60 NavigatorDoNotTrack* supplement = static_cast<NavigatorDoNotTrack*>(WillBeHe
apSupplement<Navigator>::from(navigator, supplementName())); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 67 } | 71 } |
| 68 | 72 |
| 69 String NavigatorDoNotTrack::doNotTrack() | 73 String NavigatorDoNotTrack::doNotTrack() |
| 70 { | 74 { |
| 71 if (!frame() || !frame()->loader().client()) | 75 if (!frame() || !frame()->loader().client()) |
| 72 return String(); | 76 return String(); |
| 73 return frame()->loader().client()->doNotTrackValue(); | 77 return frame()->loader().client()->doNotTrackValue(); |
| 74 } | 78 } |
| 75 | 79 |
| 76 } // namespace blink | 80 } // namespace blink |
| OLD | NEW |