Clean up all mentions of Android in comments
authorsteveblock@google.com <steveblock@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Sep 2011 12:37:04 +0000 (12:37 +0000)
committersteveblock@google.com <steveblock@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Sep 2011 12:37:04 +0000 (12:37 +0000)
https://bugs.webkit.org/show_bug.cgi?id=67303

Also removes some superfluous guards and methods added for Android.

Reviewed by Darin Adler.

No new tests, removing dead code only.

* WebCorePrefix.h:
  Chromium uses this file only on Mac, so these Android guards are no
  longer required.
* bindings/v8/NPV8Object.cpp:
* bindings/v8/NPV8Object.h:
  Including npruntime.h for non-Chromium ports was added in
  http://trac.webkit.org/changeset/53634 for Android. However, this
  file is included in WebCore.pro, so leaving the guard in place.
* bindings/v8/ScriptCachedFrameData.h:
  This code was added for Android in
  http://trac.webkit.org/changeset/56716 but is now also used by QT. The
  comment should have been removed in
  http://trac.webkit.org/changeset/93573.
* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::isLayoutTimerActive):
(WebCore::Document::minimumLayoutDelay):
* dom/Document.h:
  This method was added for Android in
  http://trac.webkit.org/changeset/52919 and modified in
  http://trac.webkit.org/changeset/79775. It is no longer needed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@94290 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/WebCorePrefix.h
Source/WebCore/bindings/v8/NPV8Object.cpp
Source/WebCore/bindings/v8/NPV8Object.h
Source/WebCore/bindings/v8/ScriptCachedFrameData.h
Source/WebCore/dom/Document.cpp
Source/WebCore/dom/Document.h

index 1057e93..c473664 100644 (file)
@@ -1,3 +1,36 @@
+2011-08-31  Steve Block  <steveblock@google.com>
+
+        Clean up all mentions of Android in comments
+        https://bugs.webkit.org/show_bug.cgi?id=67303
+
+        Also removes some superfluous guards and methods added for Android.
+
+        Reviewed by Darin Adler.
+
+        No new tests, removing dead code only.
+
+        * WebCorePrefix.h:
+          Chromium uses this file only on Mac, so these Android guards are no
+          longer required.
+        * bindings/v8/NPV8Object.cpp:
+        * bindings/v8/NPV8Object.h:
+          Including npruntime.h for non-Chromium ports was added in
+          http://trac.webkit.org/changeset/53634 for Android. However, this
+          file is included in WebCore.pro, so leaving the guard in place.
+        * bindings/v8/ScriptCachedFrameData.h:
+          This code was added for Android in
+          http://trac.webkit.org/changeset/56716 but is now also used by QT. The
+          comment should have been removed in
+          http://trac.webkit.org/changeset/93573.
+        * dom/Document.cpp:
+        (WebCore::Document::Document):
+        (WebCore::Document::isLayoutTimerActive):
+        (WebCore::Document::minimumLayoutDelay):
+        * dom/Document.h:
+          This method was added for Android in
+          http://trac.webkit.org/changeset/52919 and modified in
+          http://trac.webkit.org/changeset/79775. It is no longer needed.
+
 2011-09-01  Krist√≥f Koszty√≥  <kkristof@inf.u-szeged.hu>
 
         [Qt] Build dependency problems
index ef8bd1d..8c2817a 100644 (file)
 
 #include <time.h>
 
-#if !defined(BUILDING_WX__) && !defined(ANDROID) && !defined(BUILDING_BREWMP__)
+#if !defined(BUILDING_WX__) && !defined(BUILDING_BREWMP__)
 #include <CoreFoundation/CoreFoundation.h>
 #ifdef WTF_PLATFORM_WIN_CAIRO
 #include <ConditionalMacros.h>
 #endif
 
 #endif
-#endif  // !defined(BUILDING_WX__) && !defined(ANDROID)
+#endif // !defined(BUILDING_WX__) && !defined(BUILDING_BREWMP__)
 
 #ifdef __OBJC__
 #import <Cocoa/Cocoa.h>
index d016104..02f60f7 100644 (file)
 #include "npruntime_impl.h"
 #include "npruntime_priv.h"
 
-#if PLATFORM(CHROMIUM)
-#include <bindings/npruntime.h>
-#else
-#include "npruntime.h"
-#endif
-
 #include <stdio.h>
 #include <wtf/StringExtras.h>
 
index 2a81181..f72ba8b 100644 (file)
@@ -39,7 +39,7 @@
 // moved into bridge/npruntime.h, guarded by an #if PlATFORM(CHROMIUM).
 #include <bindings/npruntime.h>
 #else
-#include "npruntime.h" // Use WebCore version for Android and other ports.
+#include "npruntime.h" // Use WebCore version for other ports.
 #endif
 
 #include <v8.h>
index e42e2eb..1e3a2f6 100644 (file)
@@ -54,9 +54,6 @@ public:
 #elif PLATFORM(QT)
 // FIXME: the right guard should be ENABLE(PAGE_CACHE). Replace with the right guard, once
 // https://bugs.webkit.org/show_bug.cgi?id=35061 is fixed.
-//
-// On Android we do use WebKit's page cache. For now we don't support isolated worlds
-// so our implementation does not take them into account.
 
 #include "OwnHandle.h"
 #include <v8.h>
index e329852..1685ae1 100644 (file)
@@ -391,7 +391,6 @@ Document::Document(Frame* frame, const KURL& url, bool isXHTML, bool isHTML)
     , m_loadEventFinished(false)
     , m_startTime(currentTime())
     , m_overMinimumLayoutThreshold(false)
-    , m_extraLayoutDelay(0)
     , m_scriptRunner(ScriptRunner::create(this))
     , m_xmlVersion("1.0")
     , m_xmlStandalone(false)
@@ -2219,22 +2218,19 @@ bool Document::shouldScheduleLayout()
     
 bool Document::isLayoutTimerActive()
 {
-    if (!view() || !view()->layoutPending())
-        return false;
-    bool isPendingLayoutImmediate = minimumLayoutDelay() == m_extraLayoutDelay;
-    return isPendingLayoutImmediate;
+    return view() && view()->layoutPending() && !minimumLayoutDelay();
 }
 
 int Document::minimumLayoutDelay()
 {
     if (m_overMinimumLayoutThreshold)
-        return m_extraLayoutDelay;
+        return 0;
     
     int elapsed = elapsedTime();
     m_overMinimumLayoutThreshold = elapsed > cLayoutScheduleThreshold;
     
     // We'll want to schedule the timer to fire at the minimum layout threshold.
-    return max(0, cLayoutScheduleThreshold - elapsed) + m_extraLayoutDelay;
+    return max(0, cLayoutScheduleThreshold - elapsed);
 }
 
 int Document::elapsedTime() const
index 3e84612..aad686e 100644 (file)
@@ -655,9 +655,6 @@ public:
     bool parsing() const { return m_bParsing; }
     int minimumLayoutDelay();
 
-    // This method is used by Android.
-    void setExtraLayoutDelay(int delay) { m_extraLayoutDelay = delay; }
-
     bool shouldScheduleLayout();
     bool isLayoutTimerActive();
     int elapsedTime() const;
@@ -1297,10 +1294,6 @@ private:
     RefPtr<SerializedScriptValue> m_pendingStateObject;
     double m_startTime;
     bool m_overMinimumLayoutThreshold;
-    // This is used to increase the minimum delay between re-layouts. It is set
-    // using setExtraLayoutDelay to modify the minimum delay used at different
-    // points during the lifetime of the Document.
-    int m_extraLayoutDelay;
     
     OwnPtr<ScriptRunner> m_scriptRunner;