diff options
author | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-05 21:29:08 +0000 |
---|---|---|
committer | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-12-05 21:29:08 +0000 |
commit | b13253836c8c98d13a8c44d6b23bdad477fb2179 (patch) | |
tree | de8a40d4ede83a4c8341cd09dd79e7d99c72b264 | |
parent | faf4d4d4a80456caf39fbc547763f80bee50acee (diff) | |
download | chromium_src-b13253836c8c98d13a8c44d6b23bdad477fb2179.zip chromium_src-b13253836c8c98d13a8c44d6b23bdad477fb2179.tar.gz chromium_src-b13253836c8c98d13a8c44d6b23bdad477fb2179.tar.bz2 |
Un-revert 6386 (my CSS change). Layout tests pass for me. I think the
builders just need a clobber when this is checked in.
I also fixed the SConscript and deleted the old CSS files.
Review URL: http://codereview.chromium.org/13146
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6452 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | webkit/build/WebCore/WebCore.vcproj | 8 | ||||
-rw-r--r-- | webkit/build/port/SConscript | 16 | ||||
-rw-r--r-- | webkit/build/port/port.vcproj | 12 | ||||
-rw-r--r-- | webkit/port/DerivedSources.make | 8 | ||||
-rw-r--r-- | webkit/port/css/html4-overrides.css | 68 | ||||
-rw-r--r-- | webkit/port/css/quirks-overrides.css | 12 | ||||
-rw-r--r-- | webkit/port/rendering/RenderThemeWin.cpp | 12 | ||||
-rw-r--r-- | webkit/port/rendering/RenderThemeWin.h | 3 |
8 files changed, 30 insertions, 109 deletions
diff --git a/webkit/build/WebCore/WebCore.vcproj b/webkit/build/WebCore/WebCore.vcproj index d9a7d9e..1b491a7 100644 --- a/webkit/build/WebCore/WebCore.vcproj +++ b/webkit/build/WebCore/WebCore.vcproj @@ -2274,6 +2274,14 @@ >
</File>
<File
+ RelativePath="..\..\..\third_party\WebKit\WebCore\css\themeWin.css"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\third_party\WebKit\WebCore\css\themeWinQuirks.css"
+ >
+ </File>
+ <File
RelativePath="..\..\..\third_party\WebKit\WebCore\css\tokenizer.flex"
>
</File>
diff --git a/webkit/build/port/SConscript b/webkit/build/port/SConscript index 1e16989..ae87fb5 100644 --- a/webkit/build/port/SConscript +++ b/webkit/build/port/SConscript @@ -542,23 +542,15 @@ def cat_files(target, source, env): fin.close() fout.close() -env.Command('$DERIVED_DIR/html4.css', - ['$PORT_DIR/css/html4.css', - '$PORTROOT/css/html4-overrides.css'], - cat_files) - -env.Command('$DERIVED_DIR/quirks.css', - ['$PORT_DIR/css/quirks.css', - '$PORTROOT/css/quirks-overrides.css'], - cat_files) - env.Command(['$DERIVED_DIR/UserAgentStyleSheets.h', '$DERIVED_DIR/UserAgentStyleSheetsData.cpp'], ['$PORT_DIR/css/make-css-file-arrays.pl', '$PORT_DIR/css/view-source.css', '$PORT_DIR/css/svg.css', - '$DERIVED_DIR/html4.css', - '$DERIVED_DIR/quirks.css'], + '$PORT_DIR/css/html4.css', + '$PORT_DIR/css/quirks.css', + '$PORT_DIR/css/themeWin.css', + '$PORT_DIR/css/themeWinQuirks.css'], '$PERL ${SOURCES[0].posix} ${TARGETS.posix} ${SOURCES[1:].posix}') def create_h_wrapper(target, source, env): diff --git a/webkit/build/port/port.vcproj b/webkit/build/port/port.vcproj index 4e31f62..6ed828c 100644 --- a/webkit/build/port/port.vcproj +++ b/webkit/build/port/port.vcproj @@ -137,18 +137,6 @@ </References>
<Files>
<Filter
- Name="css"
- >
- <File
- RelativePath="..\..\port\css\html4-overrides.css"
- >
- </File>
- <File
- RelativePath="..\..\port\css\quirks-overrides.css"
- >
- </File>
- </Filter>
- <Filter
Name="page"
>
<File
diff --git a/webkit/port/DerivedSources.make b/webkit/port/DerivedSources.make index ae7c2a5..1b45fae 100644 --- a/webkit/port/DerivedSources.make +++ b/webkit/port/DerivedSources.make @@ -1010,11 +1010,9 @@ XPathGrammar.cpp : xml/XPathGrammar.y $(PROJECT_FILE) # user agent style sheets -USER_AGENT_STYLE_SHEETS = $(WebCore)/css/view-source.css $(WebCore)/css/svg.css -UserAgentStyleSheets.h : css/make-css-file-arrays.pl $(USER_AGENT_STYLE_SHEETS) $(WebCore)/css/html4.css $(PORTROOT)/css/html4-overrides.css $(PORTROOT)/css/quirks-overrides.css - cat $(WebCore)/css/html4.css $(PORTROOT)/css/html4-overrides.css > $(DerivedSourcesDir)/html4.css - cat $(WebCore)/css/quirks.css $(PORTROOT)/css/quirks-overrides.css > $(DerivedSourcesDir)/quirks.css - perl $< $@ UserAgentStyleSheetsData.cpp $(DerivedSourcesDir)/html4.css $(DerivedSourcesDir)/quirks.css $(USER_AGENT_STYLE_SHEETS) +USER_AGENT_STYLE_SHEETS = $(WebCore)/css/html4.css $(WebCore)/css/quirks.css $(WebCore)/css/view-source.css $(WebCore)/css/svg.css $(WebCore)/css/wml.css $(WebCore)/css/themeWin.css $(WebCore)/css/themeWinQuirks.css +UserAgentStyleSheets.h : css/make-css-file-arrays.pl $(USER_AGENT_STYLE_SHEETS) + perl $< $@ UserAgentStyleSheetsData.cpp $(USER_AGENT_STYLE_SHEETS) # character set name table diff --git a/webkit/port/css/html4-overrides.css b/webkit/port/css/html4-overrides.css deleted file mode 100644 index ef4f658..0000000 --- a/webkit/port/css/html4-overrides.css +++ /dev/null @@ -1,68 +0,0 @@ -/* Copyright 2008 Google Inc. All Rights Reserved. */ -/* Author: ojan@google.com (Ojan Vafai) */ - -/* These styles override the default styling for HTML elements as defined in - WebCore/css/html4.css. So far we have used this file exclusively for - making our form elements match Firefoxes. If we find other needs for this - file we should seriously consider if this is the right place of them. */ - -input:not([type]), -input[type="text"], -input[type="password"], -input[type="search"] { - margin:0; - padding:1px 0; -} - -input[type="checkbox"] { - margin:3px 3px 3px 4px; -} - -input[type="radio"] { - margin:3px 3px 0 5px; -} - -/* Not sure this is the right color. #EBEBE4 is what Firefox uses. - TODO(ojan): Figure out how to support legacy input rendering. - TODO(ojan): Add input[type="file"] once we figure out our file inputs. - TODO(ojan): Add input[type="image"] once we figure out our image inputs. - TODO(ojan): We probably do the wrong thing if you put an invalid input type. - do we care? -*/ -textarea:disabled, -input:not([type]):disabled, -input[type="text"]:disabled, -input[type="password"]:disabled, -input[type="search"]:disabled { - background-color: #EBEBE4; -} - -/* Chrome should render input[type="search"] the same as input with no type. - This search thing is an Apple-ism to get mac style search inputs. */ -input[type="search"] { - -webkit-appearance: textfield; - -webkit-box-sizing: content-box; -} - -input[type="button"], input[type="submit"], input[type="reset"], input[type="file"]::-webkit-file-upload-button, button { - /* Matches Firefox */ - padding: 0 6px; - margin: 0; -} - -/* Chrome selects are not rounded. Custom borders for them shouldn't be either. */ -keygen, -select, -select[size="0"], -select[size="1"] { - -webkit-border-radius: 0; - margin: 0; -} - -textarea { - font-family: monospace; - margin: 1px 0; - - /* Matches IE */ - padding: 2px; -} diff --git a/webkit/port/css/quirks-overrides.css b/webkit/port/css/quirks-overrides.css deleted file mode 100644 index b0300ee..0000000 --- a/webkit/port/css/quirks-overrides.css +++ /dev/null @@ -1,12 +0,0 @@ -/* Copyright 2008 Google Inc. All Rights Reserved. */ -/* Author: ojan@google.com (Ojan Vafai) */ - -/* These styles override the default styling for HTML elements in quirks-mode - as defined in WebCore/css/quirks.css. So far we have used this file exclusively for - making our form elements match Firefoxes. If we find other needs for this - file we should seriously consider if this is the right place of them. */ - -textarea { - /* Matches IE's text offsets in quirksmode (causes text to wrap the same as IE). */ - padding: 2px 0 0 2px; -} diff --git a/webkit/port/rendering/RenderThemeWin.cpp b/webkit/port/rendering/RenderThemeWin.cpp index a4614c1..d57524f 100644 --- a/webkit/port/rendering/RenderThemeWin.cpp +++ b/webkit/port/rendering/RenderThemeWin.cpp @@ -28,6 +28,7 @@ #include <vssym32.h> #include "ChromiumBridge.h" +#include "CSSStyleSheet.h" #include "CSSValueKeywords.h" #include "Document.h" #include "FontSelector.h" @@ -36,6 +37,7 @@ #include "ScrollbarTheme.h" #include "SkiaUtils.h" #include "ThemeHelperWin.h" +#include "UserAgentStyleSheets.h" // TODO(brettw) all of these dependencies should eventually be removed. #include "base/gfx/native_theme.h" @@ -199,6 +201,16 @@ RenderTheme* theme() return &winTheme; } +String RenderThemeWin::extraDefaultStyleSheet() +{ + return String(themeWinUserAgentStyleSheet, sizeof(themeWinUserAgentStyleSheet)); +} + +String RenderThemeWin::extraQuirksStyleSheet() +{ + return String(themeWinQuirksUserAgentStyleSheet, sizeof(themeWinQuirksUserAgentStyleSheet)); +} + bool RenderThemeWin::supportsFocusRing(const RenderStyle* style) const { // Let webkit draw one of its halo rings around any focused element, diff --git a/webkit/port/rendering/RenderThemeWin.h b/webkit/port/rendering/RenderThemeWin.h index 5c16330..cd9cb4c 100644 --- a/webkit/port/rendering/RenderThemeWin.h +++ b/webkit/port/rendering/RenderThemeWin.h @@ -46,6 +46,9 @@ public: RenderThemeWin() { } ~RenderThemeWin() { } + virtual String extraDefaultStyleSheet(); + virtual String extraQuirksStyleSheet(); + // A method asking if the theme's controls actually care about redrawing when hovered. virtual bool supportsHover(const RenderStyle*) const { return true; } |