2006-10-15 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
authorbdash <bdash@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 16 Oct 2006 01:33:04 +0000 (01:33 +0000)
committerbdash <bdash@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 16 Oct 2006 01:33:04 +0000 (01:33 +0000)
        Reviewed by Anders.

        Remove junk (as gcc calls it) after #else clause.

        * wtf/FastMalloc.cpp:
        (WTF::do_free):

2006-10-15  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>

        Reviewed by Anders.

        Misc Gdk/Linux build fixes.

        * platform/gdk/BrowserExtensionGdk.h:
        * platform/gdk/FrameGdk.cpp:
        (WebCore::FrameGdk::submitForm):
        (WebCore::FrameGdk::urlSelected):
        * platform/gdk/FrameGdk.h:
        * platform/gdk/RenderPopupMenuGdk.cpp:
        (WebCore::PopupMenu::PopupMenu):
        (WebCore::PopupMenu::~PopupMenu):
        (WebCore::PopupMenu::clear):
        (WebCore::PopupMenu::populate):
        (WebCore::PopupMenu::show):
        (WebCore::PopupMenu::hide):
        (WebCore::PopupMenu::addSeparator):
        (WebCore::PopupMenu::addGroupLabel):
        (WebCore::PopupMenu::addOption):
        * platform/gdk/RenderPopupMenuGdk.h:
        * platform/gdk/RenderThemeGdk.cpp:
        * platform/gdk/RenderThemeGdk.h:
        (WebCore::RenderThemeGdk::RenderThemeGdk):
        * platform/gdk/TemporaryLinkStubs.cpp:
        (BrowserExtensionGdk::createNewWindow):
        (BrowserExtensionGdk::BrowserExtensionGdk):
        (BrowserExtensionGdk::setTypedIconURL):
        (BrowserExtensionGdk::setIconURL):
        (BrowserExtensionGdk::getHistoryLength):
        (WebCore::CheckIfReloading):
        (WebCore::CacheObjectExpiresTime):
        (WebCore::ResponseURL):
        (WebCore::IsResponseURLEqualToURL):
        (WebCore::ResponseIsMultipart):
        (WebCore::ResponseMIMEType):
        (WebCore::CachedResource::setResponse):
        (WebCore::CachedResource::setAllData):
        (FileChooser::disconnectUploadControl):
        * rendering/RenderTheme.h:
        * rendering/RenderThemeMac.h:

2006-10-15  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>

        Reviewed by Anders.

        Make compiler not complain about unused gk. SpinneretWebHost was not setting
        initial refcount upon creation, so it is completely bogus.

        * GdkLauncher/main.cpp:
        (main):
        * Spinneret/Spinneret/Spinneret.h:
        (SpinneretWebHost::SpinneretWebHost):

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

16 files changed:
JavaScriptCore/ChangeLog
JavaScriptCore/wtf/FastMalloc.cpp
WebCore/ChangeLog
WebCore/platform/gdk/BrowserExtensionGdk.h
WebCore/platform/gdk/FrameGdk.cpp
WebCore/platform/gdk/FrameGdk.h
WebCore/platform/gdk/RenderPopupMenuGdk.cpp
WebCore/platform/gdk/RenderPopupMenuGdk.h
WebCore/platform/gdk/RenderThemeGdk.cpp
WebCore/platform/gdk/RenderThemeGdk.h
WebCore/platform/gdk/TemporaryLinkStubs.cpp
WebCore/rendering/RenderTheme.h
WebCore/rendering/RenderThemeMac.h
WebKitTools/ChangeLog
WebKitTools/GdkLauncher/main.cpp
WebKitTools/Spinneret/Spinneret/Spinneret.h

index 2e42ffb..551fdb6 100644 (file)
@@ -1,3 +1,12 @@
+2006-10-15  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>
+
+        Reviewed by Anders.
+
+        Remove junk (as gcc calls it) after #else clause.
+
+        * wtf/FastMalloc.cpp:
+        (WTF::do_free):
+
 2006-10-14  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>
 
         Reviewed by Maciej.
index 54a5722..0ef02d4 100644 (file)
@@ -1896,7 +1896,7 @@ static ALWAYS_INLINE void do_free(void* ptr) {
 #endif
 #if WTF_CHANGES
   if (ptr == NULL) return;
-#else WTF_CHANGES
+#else
   if (ptr == NULL || tcmalloc_is_destroyed) return;
 #endif
 
index bfd0d27..82bd099 100644 (file)
@@ -1,3 +1,46 @@
+2006-10-15  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>
+
+        Reviewed by Anders.
+
+        Misc Gdk/Linux build fixes.
+
+        * platform/gdk/BrowserExtensionGdk.h:
+        * platform/gdk/FrameGdk.cpp:
+        (WebCore::FrameGdk::submitForm):
+        (WebCore::FrameGdk::urlSelected):
+        * platform/gdk/FrameGdk.h:
+        * platform/gdk/RenderPopupMenuGdk.cpp:
+        (WebCore::PopupMenu::PopupMenu):
+        (WebCore::PopupMenu::~PopupMenu):
+        (WebCore::PopupMenu::clear):
+        (WebCore::PopupMenu::populate):
+        (WebCore::PopupMenu::show):
+        (WebCore::PopupMenu::hide):
+        (WebCore::PopupMenu::addSeparator):
+        (WebCore::PopupMenu::addGroupLabel):
+        (WebCore::PopupMenu::addOption):
+        * platform/gdk/RenderPopupMenuGdk.h:
+        * platform/gdk/RenderThemeGdk.cpp:
+        * platform/gdk/RenderThemeGdk.h:
+        (WebCore::RenderThemeGdk::RenderThemeGdk):
+        * platform/gdk/TemporaryLinkStubs.cpp:
+        (BrowserExtensionGdk::createNewWindow):
+        (BrowserExtensionGdk::BrowserExtensionGdk):
+        (BrowserExtensionGdk::setTypedIconURL):
+        (BrowserExtensionGdk::setIconURL):
+        (BrowserExtensionGdk::getHistoryLength):
+        (WebCore::CheckIfReloading):
+        (WebCore::CacheObjectExpiresTime):
+        (WebCore::ResponseURL):
+        (WebCore::IsResponseURLEqualToURL):
+        (WebCore::ResponseIsMultipart):
+        (WebCore::ResponseMIMEType):
+        (WebCore::CachedResource::setResponse):
+        (WebCore::CachedResource::setAllData):
+        (FileChooser::disconnectUploadControl):
+        * rendering/RenderTheme.h:
+        * rendering/RenderThemeMac.h:
+
 2006-10-15  Sam Weinig  <sam.weinig@gmail.com>
 
         Reviewed by Mitz.
index 6fc58cc..205985e 100644 (file)
@@ -39,8 +39,8 @@ class BrowserExtensionGdk : public BrowserExtension {
 public:
     BrowserExtensionGdk(Frame*);
 
-    virtual void createNewWindow(const ResourceRequest&);
-    virtual void createNewWindow(const ResourceRequest&, const WindowArgs&, Frame*&);
+    virtual void createNewWindow(const FrameLoadRequest&);
+    virtual void createNewWindow(const FrameLoadRequest&, const WindowArgs&, Frame*&);
 
     virtual void setIconURL(const KURL&);
     virtual void setTypedIconURL(const KURL&, const String& type);
index 7e795b6..3e887c3 100644 (file)
@@ -52,6 +52,7 @@
 #include "TypingCommand.h"
 #include "SSLKeyGenerator.h"
 #include "KeyboardCodes.h"
+#include "FrameLoadRequest.h"
 #include <gdk/gdk.h>
 
 
@@ -205,8 +206,10 @@ bool FrameGdk::openURL(const KURL& url)
     return true;
 }
 
-void FrameGdk::submitForm(const ResourceRequest& request)
+void FrameGdk::submitForm(const FrameLoadRequest& frameLoadRequest)
 {
+    ResourceRequest request = frameLoadRequest.m_request;
+
     // FIXME: this is a hack inherited from FrameMac, and should be pushed into Frame
     if (d->m_submittedFormURL == request.url())
         return;
@@ -218,8 +221,10 @@ void FrameGdk::submitForm(const ResourceRequest& request)
     clearRecordedFormValues();
 }
 
-void FrameGdk::urlSelected(const ResourceRequest& request)
+void FrameGdk::urlSelected(const FrameLoadRequest& frameLoadRequest)
 {
+    ResourceRequest request = frameLoadRequest.m_request;
+
     if (!m_client)
         return;
 
index 5f3e873..dc081e7 100644 (file)
@@ -79,9 +79,9 @@ public:
 
     void handleGdkEvent(GdkEvent*);
     virtual bool openURL(const KURL&);
-    virtual void openURLRequest(const ResourceRequest&);
-    virtual void submitForm(const ResourceRequest&);
-    virtual void urlSelected(const ResourceRequest&);
+    virtual void openURLRequest(const FrameLoadRequest&);
+    virtual void submitForm(const FrameLoadRequest&);
+    virtual void urlSelected(const FrameLoadRequest&);
 
     virtual void setTitle(const String&);
 
index a605e14..5718cd1 100644 (file)
  */
 
 #include "config.h"
-#include "RenderPopupMenuGdk.h"
+#include "PopupMenu.h"
+
+#include <stdio.h>
+
+#define notImplemented() do { fprintf(stderr, "FIXME: UNIMPLEMENTED: %s:%d\n", __FILE__, __LINE__); } while(0)
 
 namespace WebCore {
 
-RenderPopupMenuGdk::RenderPopupMenuGdk(Node* element,  RenderMenuList* list)
-    : RenderPopupMenu(element,list)
+PopupMenu::PopupMenu(RenderMenuList* menuList)
 {
 }
 
-RenderPopupMenuGdk::~RenderPopupMenuGdk()
+PopupMenu::~PopupMenu()
 {
 }
 
-void RenderPopupMenuGdk::clear()
+void PopupMenu::clear()
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::populate()
+void PopupMenu::populate()
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::showPopup(const IntRect&, FrameView*, int)
+void PopupMenu::show(const IntRect&, FrameView*, int)
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::hidePopup()
+void PopupMenu::hide()
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::addSeparator()
+void PopupMenu::addSeparator()
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::addGroupLabel(HTMLOptGroupElement*)
+void PopupMenu::addGroupLabel(HTMLOptGroupElement*)
 {
+    notImplemented();
 }
 
-void RenderPopupMenuGdk::addOption(HTMLOptionElement*)
+void PopupMenu::addOption(HTMLOptionElement*)
 {
+    notImplemented();
 }
 
 }
+
index c0b2048..c16e415 100644 (file)
 #ifndef RENDER_POPUPMENU_GDK_H
 #define RENDER_POPUPMENU_GDK_H
 
-#include "RenderPopupMenu.h"
+#include "PopupMenu.h"
 
 namespace WebCore {
 
 class HTMLOptionElement;
 class HTMLOptGroupElement;
 
-class RenderPopupMenuGdk : public RenderPopupMenu {
+class PopupMenuGdk : public PopupMenu {
 public:
-    RenderPopupMenuGdk(Node*,  RenderMenuList*);
-    ~RenderPopupMenuGdk();
+    PopupMenuGdk(Node*,  RenderMenuList*);
+    ~PopupMenuGdk();
 
     virtual void clear();
     virtual void populate();
index a15de65..4bdb7f2 100644 (file)
@@ -57,14 +57,6 @@ RenderTheme* theme()
     return &gdkTheme;
 }
 
-RenderThemeGdk::RenderThemeGdk()
-{
-}
-
-RenderThemeGdk::~RenderThemeGdk()
-{
-}
-
 void RenderThemeGdk::close()
 {
 }
@@ -157,11 +149,6 @@ void RenderThemeGdk::adjustButtonStyle(CSSStyleSelector* selector, RenderStyle*
     addIntrinsicMargins(style);
 }
 
-RenderPopupMenu* RenderThemeGdk::createPopupMenu(RenderArena* arena, Document* doc, RenderMenuList* list)
-{
-    return new (arena) RenderPopupMenuGdk(doc,list);
-}
-
 void RenderThemeGdk::systemFont(int propId, FontDescription&) const
 {
 
index b75e80f..be7d19d 100644 (file)
@@ -38,8 +38,7 @@ struct ThemeData {
 
 class RenderThemeGdk : public RenderTheme {
 public:
-    RenderThemeGdk();
-    ~RenderThemeGdk();
+    RenderThemeGdk() : RenderTheme() { }
 
     // A method asking if the theme's controls actually care about redrawing when hovered.
     virtual bool supportsHover(const RenderStyle* style) const { return true; }
@@ -61,8 +60,6 @@ public:
     // System fonts.
     virtual void systemFont(int propId, FontDescription&) const;
 
-    virtual RenderPopupMenu* createPopupMenu(RenderArena*, Document*, RenderMenuList*);
-
 private:
     void addIntrinsicMargins(RenderStyle*) const;
     void close();
index a681fd2..8dbe085 100644 (file)
@@ -27,8 +27,6 @@
 
 #include "config.h"
 
-#define WIN32_COMPILE_HACK
-
 #include <stdio.h>
 #include <stdlib.h>
 #include "CString.h"
 #include "RenderTheme.h"
 #include "FrameGdk.h"
 #include "BrowserExtensionGdk.h"
-#include "ResourceLoader.h"
+#include "FrameLoadRequest.h"
 #include "RenderThemeGdk.h"
 #include "TextBoundaries.h"
 #include "AXObjectCache.h"
-#include "RenderPopupMenuGdk.h"
 #include "EditCommand.h"
 #include "Icon.h"
 #include "IconLoader.h"
 #include "IconDatabase.h"
+#include "CachedResource.h"
 
 using namespace WebCore;
 
-static void notImplemented() { puts("Not yet implemented"); }
+namespace WebCore {
+struct PlatformDataStruct
+{
+};
+
+struct PlatformResponseStruct
+{
+};
+}
+
+#define notImplemented() do { fprintf(stderr, "FIXME: UNIMPLEMENTED: %s in %s:%d\n", __FUNCTION__, __FILE__, __LINE__); } while(0)
 
 void FrameView::updateBorder() { notImplemented(); }
 bool FrameView::passMousePressEventToScrollbar(MouseEventWithHitTestResults&, PlatformScrollbar*) { return false; }
@@ -154,7 +162,7 @@ KJS::Bindings::Instance* FrameGdk::getAppletInstanceForWidget(Widget*) { notImpl
 bool FrameGdk::passMouseDownEventToWidget(Widget*) { notImplemented(); return 0; }
 void FrameGdk::issueCutCommand() { notImplemented(); }
 void FrameGdk::issueCopyCommand() { notImplemented(); }
-void FrameGdk::openURLRequest(struct WebCore::ResourceRequest const&) { notImplemented(); }
+void FrameGdk::openURLRequest(struct WebCore::FrameLoadRequest const&) { notImplemented(); }
 void FrameGdk::issueUndoCommand() { notImplemented(); }
 String FrameGdk::mimeTypeForFileName(String const&) const { notImplemented(); return String(); }
 void FrameGdk::issuePasteCommand() { notImplemented(); }
@@ -174,12 +182,16 @@ KURL FrameGdk::originalRequestURL() const { return KURL(); }
 Plugin* FrameGdk::createPlugin(Element*, KURL const&, const Vector<String>&, const Vector<String>&, String const&) { notImplemented(); return 0; }
 
 bool BrowserExtensionGdk::canRunModal() { notImplemented(); return 0; }
-void BrowserExtensionGdk::createNewWindow(struct WebCore::ResourceRequest const&, struct WebCore::WindowArgs const&, Frame*&) { notImplemented(); }
+void BrowserExtensionGdk::createNewWindow(struct WebCore::FrameLoadRequest const&, struct WebCore::WindowArgs const&, Frame*&) { notImplemented(); }
+void BrowserExtensionGdk::createNewWindow(struct WebCore::FrameLoadRequest const&) { notImplemented(); }
 bool BrowserExtensionGdk::canRunModalNow() { notImplemented(); return 0; }
 void BrowserExtensionGdk::runModal() { notImplemented(); }
 void BrowserExtensionGdk::goBackOrForward(int) { notImplemented(); }
 KURL BrowserExtensionGdk::historyURL(int distance) { notImplemented(); return KURL(); }
-void BrowserExtensionGdk::createNewWindow(struct WebCore::ResourceRequest const&) { notImplemented(); }
+BrowserExtensionGdk::BrowserExtensionGdk(WebCore::Frame*) { }
+void BrowserExtensionGdk::setTypedIconURL(KURL const&, const String&) { }
+void BrowserExtensionGdk::setIconURL(KURL const&) { }
+int BrowserExtensionGdk::getHistoryLength() { return 0; }
 
 int WebCore::screenDepthPerComponent(const Page*) { notImplemented(); return 0; }
 bool WebCore::screenIsMonochrome(const Page*) { notImplemented(); return false; }
@@ -231,15 +243,17 @@ String FrameGdk::incomingReferrer() const { return String(); }
 void FrameGdk::markMisspellingsInAdjacentWords(WebCore::VisiblePosition const&) { }
 void FrameGdk::respondToChangedContents(const Selection&) { }
 
-BrowserExtensionGdk::BrowserExtensionGdk(WebCore::Frame*) { }
-void BrowserExtensionGdk::setTypedIconURL(KURL const&, const String&) { }
-void BrowserExtensionGdk::setIconURL(KURL const&) { }
-int BrowserExtensionGdk::getHistoryLength() { return 0; }
-
 namespace WebCore {
 
-bool CheckIfReloading(WebCore::DocLoader*) { return false; }
+bool CheckIfReloading(DocLoader*) { return false; }
+time_t CacheObjectExpiresTime(DocLoader*, PlatformResponse) { return 0; }
 void CheckCacheObjectStatus(DocLoader*, CachedResource*) { }
+DeprecatedString ResponseURL(PlatformResponse) { return DeprecatedString(); }
+bool IsResponseURLEqualToURL(PlatformResponse , const String& URL) { return false; }
+bool ResponseIsMultipart(PlatformResponse) { return false; }
+DeprecatedString ResponseMIMEType(PlatformResponse) { return DeprecatedString(); }
+void CachedResource::setResponse(PlatformResponse) { notImplemented(); }
+void CachedResource::setAllData(PlatformData) { notImplemented(); }
 
 }
 
@@ -326,12 +340,6 @@ void PlatformScrollbar::updateThumbPosition() { }
 void PlatformScrollbar::updateThumbProportion() { }
 void PlatformScrollbar::setRect(const IntRect&) { }
 
-Scrollbar::Scrollbar(ScrollbarClient*, ScrollbarOrientation, ScrollbarControlSize controlSize) { }
-void Scrollbar::setSteps(int, int) { }
-bool Scrollbar::scroll(ScrollDirection, ScrollGranularity, float) { return false; }
-bool Scrollbar::setValue(int) { return false; }
-void Scrollbar::setProportion(int, int) { }
-
 ListBox::ListBox() { }
 ListBox::~ListBox() { }
 void ListBox::setSelectionMode(ListBox::SelectionMode) { }
@@ -342,7 +350,7 @@ FileChooser::~FileChooser() { notImplemented(); }
 PassRefPtr<FileChooser> FileChooser::create(Document*, RenderFileUploadControl*) { notImplemented(); return 0; }
 void FileChooser::openFileChooser() { notImplemented(); }
 String FileChooser::basenameForWidth(int width) const { notImplemented(); return String(); }
-void FileChooser::uploadControlDetaching() { notImplemented(); }
+void FileChooser::disconnectUploadControl() { notImplemented(); }
 void FileChooser::chooseFile(const String& filename) { notImplemented(); }
 
 Color WebCore::focusRingColor() { return 0xFF0000FF; }
index cd82c50..a67f0ea 100644 (file)
@@ -28,7 +28,7 @@
 namespace WebCore {
 
 class Element;
-class RenderPopupMenu;
+class PopupMenu;
 class RenderMenuList;
 
 enum ControlState { HoverState, PressedState, FocusState, EnabledState, CheckedState, ReadOnlyState };
index 683694c..3f820ba 100644 (file)
@@ -28,7 +28,6 @@
 namespace WebCore {
 
 class RenderStyle;
-class RenderPopupMenu;
 
 class RenderThemeMac : public RenderTheme {
 public:
index 55bcad4..7780b9e 100644 (file)
@@ -1,3 +1,15 @@
+2006-10-15  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>
+
+        Reviewed by Anders.
+
+        Make compiler not complain about unused gk. SpinneretWebHost was not setting
+        initial refcount upon creation, so it is completely bogus.
+
+        * GdkLauncher/main.cpp:
+        (main):
+        * Spinneret/Spinneret/Spinneret.h:
+        (SpinneretWebHost::SpinneretWebHost):
+
 2006-10-15  Nikolas Zimmermann  <zimmermann@kde.org>
 
         Reviewed by Oliver.
index 8d4eebb..23689af 100644 (file)
@@ -70,7 +70,6 @@ int main(int argc, char *argv[])
     win = gdk_window_new(NULL,&attr,0);
     frame = new LauncherFrameGdk(win);
     gdk_window_show(win);
-    char *pg = " <html><head><title>Google</title> <body bgcolor=#ffffff text=#000000> <p><font size=-2/>2006 Google Hello bigworld from mike</p></body></html> ";
     url = "http://www.google.com";
     bool exitAfterLoading = false;
     for (int argPos = 1; argPos < argc; ++argPos) {
@@ -84,12 +83,13 @@ int main(int argc, char *argv[])
         printf("OPENING URL == %s \n", url);
         frame->openURL(url);
     } else {
-/*
-  frame->createEmptyDocument();
-    frame->document()->open();
-    frame->write(pg,strlen(pg));
-    frame->document()->close();
-*/
+#if 0
+        char *pg = " <html><head><title>Google</title> <body bgcolor=#ffffff text=#000000> <p><font size=-2/>2006 Google Hello bigworld from mike</p></body></html> ";
+        frame->createEmptyDocument();
+        frame->document()->open();
+        frame->write(pg,strlen(pg));
+        frame->document()->close();
+#endif
     }
     
     gtk_main();
index fc51ab2..de3501f 100644 (file)
@@ -32,6 +32,8 @@
 class SpinneretWebHost : public IWebFrameLoadDelegate
 {
 public:
+    SpinneretWebHost() : m_refCount(1) {}
+
     // IUnknown
     virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject);
     virtual ULONG STDMETHODCALLTYPE AddRef(void);