| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Harri Porten (porten@kde.org) | 2 * Copyright (C) 2000 Harri Porten (porten@kde.org) |
| 3 * Copyright (c) 2000 Daniel Molkentin (molkentin@kde.org) | 3 * Copyright (c) 2000 Daniel Molkentin (molkentin@kde.org) |
| 4 * Copyright (c) 2000 Stefan Schimanski (schimmi@kde.org) | 4 * Copyright (c) 2000 Stefan Schimanski (schimmi@kde.org) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006 Apple Computer, Inc. | 5 * Copyright (C) 2003, 2004, 2005, 2006 Apple Computer, Inc. |
| 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Lesser General Public | 9 * modify it under the terms of the GNU Lesser General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 #include "core/loader/CookieJar.h" | 28 #include "core/loader/CookieJar.h" |
| 29 #include "core/loader/FrameLoader.h" | 29 #include "core/loader/FrameLoader.h" |
| 30 #include "core/page/Frame.h" | 30 #include "core/page/Frame.h" |
| 31 #include "core/page/NavigatorID.h" | 31 #include "core/page/NavigatorID.h" |
| 32 #include "core/page/Page.h" | 32 #include "core/page/Page.h" |
| 33 #include "core/page/Settings.h" | 33 #include "core/page/Settings.h" |
| 34 #include "core/platform/Language.h" | 34 #include "core/platform/Language.h" |
| 35 #include "core/plugins/DOMMimeTypeArray.h" | 35 #include "core/plugins/DOMMimeTypeArray.h" |
| 36 #include "core/plugins/DOMPluginArray.h" | 36 #include "core/plugins/DOMPluginArray.h" |
| 37 | 37 |
| 38 #ifndef WEBCORE_NAVIGATOR_PRODUCT_SUB |
| 39 #define WEBCORE_NAVIGATOR_PRODUCT_SUB "20030107" |
| 40 #endif // ifndef WEBCORE_NAVIGATOR_PRODUCT_SUB |
| 41 |
| 42 #ifndef WEBCORE_NAVIGATOR_VENDOR |
| 43 #define WEBCORE_NAVIGATOR_VENDOR "Apple Computer, Inc." |
| 44 #endif // ifndef WEBCORE_NAVIGATOR_VENDOR |
| 45 |
| 46 #ifndef WEBCORE_NAVIGATOR_VENDOR_SUB |
| 47 #define WEBCORE_NAVIGATOR_VENDOR_SUB "" |
| 48 #endif // ifndef WEBCORE_NAVIGATOR_VENDOR_SUB |
| 49 |
| 38 namespace WebCore { | 50 namespace WebCore { |
| 39 | 51 |
| 40 Navigator::Navigator(Frame* frame) | 52 Navigator::Navigator(Frame* frame) |
| 41 : DOMWindowProperty(frame) | 53 : DOMWindowProperty(frame) |
| 42 { | 54 { |
| 43 ScriptWrappable::init(this); | 55 ScriptWrappable::init(this); |
| 44 } | 56 } |
| 45 | 57 |
| 46 Navigator::~Navigator() | 58 Navigator::~Navigator() |
| 47 { | 59 { |
| (...skipping 24 matching lines...) Expand all Loading... |
| 72 if (shouldHideFourDot(m_frame)) | 84 if (shouldHideFourDot(m_frame)) |
| 73 appVersion.replace("4.", "4_"); | 85 appVersion.replace("4.", "4_"); |
| 74 return appVersion; | 86 return appVersion; |
| 75 } | 87 } |
| 76 | 88 |
| 77 String Navigator::language() const | 89 String Navigator::language() const |
| 78 { | 90 { |
| 79 return defaultLanguage(); | 91 return defaultLanguage(); |
| 80 } | 92 } |
| 81 | 93 |
| 94 String Navigator::productSub() const |
| 95 { |
| 96 return WEBCORE_NAVIGATOR_PRODUCT_SUB; |
| 97 } |
| 98 |
| 99 String Navigator::vendor() const |
| 100 { |
| 101 return WEBCORE_NAVIGATOR_VENDOR; |
| 102 } |
| 103 |
| 104 String Navigator::vendorSub() const |
| 105 { |
| 106 return WEBCORE_NAVIGATOR_VENDOR_SUB; |
| 107 } |
| 108 |
| 82 String Navigator::userAgent() const | 109 String Navigator::userAgent() const |
| 83 { | 110 { |
| 84 if (!m_frame) | 111 if (!m_frame) |
| 85 return String(); | 112 return String(); |
| 86 | 113 |
| 87 // If the frame is already detached, FrameLoader::userAgent may malfunction,
because it calls a client method | 114 // If the frame is already detached, FrameLoader::userAgent may malfunction,
because it calls a client method |
| 88 // that uses frame's WebView (at least, in Mac WebKit). | 115 // that uses frame's WebView (at least, in Mac WebKit). |
| 89 if (!m_frame->page()) | 116 if (!m_frame->page()) |
| 90 return String(); | 117 return String(); |
| 91 | 118 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 | 154 |
| 128 return true; | 155 return true; |
| 129 } | 156 } |
| 130 | 157 |
| 131 void Navigator::getStorageUpdates() | 158 void Navigator::getStorageUpdates() |
| 132 { | 159 { |
| 133 // FIXME: Remove this method or rename to yieldForStorageUpdates. | 160 // FIXME: Remove this method or rename to yieldForStorageUpdates. |
| 134 } | 161 } |
| 135 | 162 |
| 136 } // namespace WebCore | 163 } // namespace WebCore |
| OLD | NEW |