Reviewed by Geoff.
Improve gdk build compiler flags (show warning, no rtti and exceptions).
* jscore.bkl:
2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
Reviewed by Geoff.
Improve gdk build compiler options.
* Bakefiles.bkgen:
* presets.bkl:
2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
Reviewed by Geoff.
Fix memory leaks discovered via valgrind. Gdk build fixes.
* Projects/gdk/webcore-gdk.bkl:
* make-generated-sources.sh:
* platform/cairo/ImageCairo.cpp:
(WebCore::Image::draw):
* platform/gdk/FrameGdk.cpp:
(WebCore::FrameGdk::handleGdkEvent):
* platform/gdk/FrameGdk.h:
* platform/gdk/PlatformScrollBar.h:
(WebCore::PlatformScrollbar::horizontalScrollbarHeight):
(WebCore::PlatformScrollbar::verticalScrollbarWidth):
2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
Reviewed by Geoff.
Add -exit-after-loading option to make gdklauncher quit after fully loading and rendering
a page. This allows automatic testing via e.g. valgrind.
* GdkLauncher/gdklauncher.bkl:
* GdkLauncher/main.cpp:
(LauncherFrameGdk::LauncherFrameGdk):
(LauncherFrameGdk::setExitAfterLoading):
(LauncherFrameGdk::handledOnloadEvents):
(handle_event):
(main):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@16945
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
<!-- List of output formats to generate: -->
<add-formats>
- msvc,msvs2005,gnu <!-- xcode2 -->
+ gnu <!-- xcode2,msvc,msvs2005 -->
</add-formats>
<!-- webcore gdk is Unix-only for now, right? -->
+2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
+
+ Reviewed by Geoff.
+
+ Improve gdk build compiler options.
+
+ * Bakefiles.bkgen:
+ * presets.bkl:
+
2006-10-03 Mark Rowe <bdash@webkit.org>
Reviewed by Eric.
- Stop Bakefile-generated Makefile from running `pkg-config' multiple times per file.
+ Stop Bakefile-generated Makefile from running pkg-config multiple times per file.
* presets.bkl: Make use of "options" and Python commands to run pkg-config etc up front.
<template id="jscore">
<include>$(SRCDIR)/../JavaScriptCore</include>
- <if cond="FORMAT in ['msvc', 'msvs2005']">
- <!-- MSVC chokes on #import, so don't use ForwardingHeaders... -->
- <include>$(SRCDIR)/../JavaScriptCore/os-win32</include><!-- stdint.h is here -->
- </if>
<if cond="FORMAT=='gnu'">
<ldflags>$(SRCDIR)/../JavaScriptCore/libjscore.a</ldflags>
</if>
+2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
+
+ Reviewed by Geoff.
+
+ Improve gdk build compiler flags (show warning, no rtti and exceptions).
+
+ * jscore.bkl:
+
2006-10-06 Kevin McCullough <KMcCullough@apple.com>
Reviewed by Brady.
<include>$(SRCDIR)/bindings</include>
<include>$(SRCDIR)/bindings/c</include>
<include>$(SRCDIR)/bindings/jni</include>
- <include>$(SRCDIR)/kxmlcore</include>
<include>$(SRCDIR)/DerivedSources/JavaScriptCore</include>
<define>APPLE_CHANGES=1</define>
<lib id="jscore" template="jscore_base">
<objects-depend>dftables</objects-depend>
<pre-build-target>DerivedSources</pre-build-target>
+ <warnings>default</warnings>
+ <cxx-rtti>off</cxx-rtti>
+ <cxx-exceptions>off</cxx-exceptions>
+ <debug-info>on</debug-info>
<sources>
$(JSCORE_SOURCES_WTF)
$(JSCORE_SOURCES_PCRE)
+2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
+
+ Reviewed by Geoff.
+
+ Fix memory leaks discovered via valgrind. Gdk build fixes.
+
+ * Projects/gdk/webcore-gdk.bkl:
+ * make-generated-sources.sh:
+ * platform/cairo/ImageCairo.cpp:
+ (WebCore::Image::draw):
+ * platform/gdk/FrameGdk.cpp:
+ (WebCore::FrameGdk::handleGdkEvent):
+ * platform/gdk/FrameGdk.h:
+ * platform/gdk/PlatformScrollBar.h:
+ (WebCore::PlatformScrollbar::horizontalScrollbarHeight):
+ (WebCore::PlatformScrollbar::verticalScrollbarWidth):
+
2006-10-09 Nikolas Zimmermann <zimmermann@kde.org>
Reviewed by Beth.
<dirname>.</dirname>
<pic>on</pic>
<threading>multi</threading>
- <warnings>no</warnings>
- <cxxflags>-w</cxxflags>
+ <warnings>default</warnings>
+ <cxx-rtti>off</cxx-rtti>
+ <cxx-exceptions>off</cxx-exceptions>
+ <debug-info>on</debug-info>
<include>$(SRCDIR)/platform/gdk</include>
- <cflags>-w</cflags>
<define>BUILDING_GDK__</define>
<define>BUILDING_CAIRO__</define>
<include>platform/gdk</include>
#!/bin/sh
+export SOURCE_ROOT=$PWD
export SRCROOT=$PWD
export WebCore=$PWD
export CREATE_HASH_TABLE="$SRCROOT/../JavaScriptCore/kjs/create_hash_table"
# note ENCODINGS_PREFIX needs to be a ws string so it does not turn into
# a null value
-make -f ../../DerivedSources.make ENCODINGS_FILE=$1 ENCODINGS_PREFIX=" "
+make -f ../../DerivedSources.make ENCODINGS_FILE=$1 ENCODINGS_PREFIX="\" \""
cd ../..
cairo_rectangle(context, 0, 0, dstRect.width(), dstRect.height());
cairo_fill(context);
+ cairo_pattern_destroy(pattern);
cairo_restore(context);
startAnimation();
GraphicsContext* ctx = new GraphicsContext(cr);
paint(ctx, IntRect(clip.x, clip.y, clip.width, clip.height));
delete ctx;
+ cairo_destroy(cr);
gdk_window_end_paint (event->any.window);
break;
}
public:
FrameGdk(Page*, Element*);
FrameGdk(GdkDrawable*);
- ~FrameGdk();
+ virtual ~FrameGdk();
void handleGdkEvent(GdkEvent*);
virtual bool openURL(const KURL&);
virtual void setEnabled(bool);
virtual void paint(GraphicsContext*, const IntRect& damageRect);
+ // FIXME: Implement.
+ static int horizontalScrollbarHeight() { return 15; }
+ static int verticalScrollbarWidth() { return 15; }
+
protected:
virtual void updateThumbPosition();
virtual void updateThumbProportion();
+2006-10-09 Krzysztof Kowalczyk <kkowalczyk@gmail.com>
+
+ Reviewed by Geoff.
+
+ Add -exit-after-loading option to make gdklauncher quit after fully loading and rendering
+ a page. This allows automatic testing via e.g. valgrind.
+
+ * GdkLauncher/gdklauncher.bkl:
+ * GdkLauncher/main.cpp:
+ (LauncherFrameGdk::LauncherFrameGdk):
+ (LauncherFrameGdk::setExitAfterLoading):
+ (LauncherFrameGdk::handledOnloadEvents):
+ (handle_event):
+ (main):
+
2006-10-06 David Smith <catfish.man@gmail.com>
Reviewed by Timothy.
<include>$(TOPDIR)/WebCore/platform/gdk</include>
<pic>on</pic>
<threading>multi</threading>
- <warnings>no</warnings>
- <cxxflags>-w</cxxflags>
- <cflags>-w</cflags>
+ <warnings>default</warnings>
+ <debug-info>on</debug-info>
<define>BUILDING_GDK__</define>
<define>BUILDING_CAIRO__</define>
<set var="TOPDIR">../..</set>
<exe id="gdklauncher" template="webcore_gdk_link">
<ldflags>-L$(TOPDIR)/WebCore/Projects/gdk -lwebcore-gdk</ldflags>
+ <warnings>default</warnings>
+ <cxx-rtti>off</cxx-rtti>
+ <cxx-exceptions>off</cxx-exceptions>
+ <debug-info>on</debug-info>
<sources>
main.cpp
</sources>
#include "Document.h"
#include "DocLoader.h"
#include "DOMImplementation.h"
-//#include "HTMLDocument.h"
#include "Cache.h"
#include "EventNames.h"
-//#include "htmlnames.h"
#if SVG_SUPPORT
#include "SVGNames.h"
#include "SVGDocumentExtensions.h"
#endif
-//painting
#include "RenderObject.h"
#include "GraphicsContext.h"
using namespace WebCore;
-static FrameGdk *frame;
+class LauncherFrameGdk : public FrameGdk
+{
+public:
+ LauncherFrameGdk(Page* page, Element* element) : FrameGdk(page, element), m_exitAfterLoading(false) {}
+ LauncherFrameGdk(GdkDrawable* drawable) : FrameGdk(drawable), m_exitAfterLoading(false) {}
+ virtual void handledOnloadEvents();
+ void setExitAfterLoading(bool exitAfterLoading) { m_exitAfterLoading = exitAfterLoading; }
+private:
+ bool m_exitAfterLoading;
+};
+
+void LauncherFrameGdk::handledOnloadEvents()
+{
+ if (m_exitAfterLoading)
+ gtk_main_quit();
+}
+
+static LauncherFrameGdk *frame;
static GdkWindow *win;
static void handle_event(GdkEvent *event)
{
- if (GDK_DELETE == event->type) {
- gtk_main_quit();
- return;
- }
- frame->handleGdkEvent(event);
+ if (GDK_DELETE == event->type) {
+ gtk_main_quit();
+ return;
+ }
+ frame->handleGdkEvent(event);
}
int main(int argc, char *argv[])
{
- GdkWindowAttr attr;
- char *url;
- gdk_init(&argc,&argv);
- gdk_event_handler_set ((GdkEventFunc)handle_event, NULL, NULL);
-
- attr.width = 800;
- attr.height = 600;
- attr.window_type = GDK_WINDOW_TOPLEVEL;
- attr.wclass = GDK_INPUT_OUTPUT;
- //see how where we handle motion here need to do the hint stuff
- attr.event_mask = ((GDK_ALL_EVENTS_MASK^GDK_POINTER_MOTION_HINT_MASK));
- win = gdk_window_new(NULL,&attr,0);
- frame = new FrameGdk(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";
- if (argc >= 2)
- url = argv[1];
+ GdkWindowAttr attr;
+ char *url;
+ gdk_init(&argc,&argv);
+ gdk_event_handler_set ((GdkEventFunc)handle_event, NULL, NULL);
- if (url) {
- printf("OPENING URL == %s \n", url);
- frame->openURL(url);
- } else {
+ attr.width = 800;
+ attr.height = 600;
+ attr.window_type = GDK_WINDOW_TOPLEVEL;
+ attr.wclass = GDK_INPUT_OUTPUT;
+ //see how where we handle motion here need to do the hint stuff
+ attr.event_mask = ((GDK_ALL_EVENTS_MASK^GDK_POINTER_MOTION_HINT_MASK));
+ 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) {
+ if (0 == strcmp(argv[argPos], "-exit-after-loading"))
+ exitAfterLoading = true;
+ else
+ url = argv[argPos];
+ }
+ frame->setExitAfterLoading(exitAfterLoading);
+ if (url) {
+ printf("OPENING URL == %s \n", url);
+ frame->openURL(url);
+ } else {
/*
- frame->createEmptyDocument();
+ frame->createEmptyDocument();
frame->document()->open();
frame->write(pg,strlen(pg));
frame->document()->close();
*/
- }
-
- gtk_main();
- delete frame;
- return 0;
+ }
+
+ gtk_main();
+ delete frame;
+ gdk_window_destroy(win);
+ return 0;
}