summaryrefslogtreecommitdiffstats
path: root/content/common
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-19 00:43:36 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-19 00:43:36 +0000
commit6091604d9afaa69457389d83f1a9d6453150e6f4 (patch)
treea008aad369c12d1d12f0adeb9fa276b9c8305e50 /content/common
parent611cc90419870d40c0048c01ce72def49b8b5dd3 (diff)
downloadchromium_src-6091604d9afaa69457389d83f1a9d6453150e6f4.zip
chromium_src-6091604d9afaa69457389d83f1a9d6453150e6f4.tar.gz
chromium_src-6091604d9afaa69457389d83f1a9d6453150e6f4.tar.bz2
Move a bunch of remaining files from chrome\renderer to content\renderer.
TBR=avi Review URL: http://codereview.chromium.org/6688047 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78781 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/common')
-rw-r--r--content/common/renderer_preferences.cc23
-rw-r--r--content/common/renderer_preferences.h78
2 files changed, 101 insertions, 0 deletions
diff --git a/content/common/renderer_preferences.cc b/content/common/renderer_preferences.cc
new file mode 100644
index 0000000..2ec7a22
--- /dev/null
+++ b/content/common/renderer_preferences.cc
@@ -0,0 +1,23 @@
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "content/common/renderer_preferences.h"
+
+RendererPreferences::RendererPreferences()
+ : can_accept_load_drops(true),
+ should_antialias_text(true),
+ hinting(RENDERER_PREFERENCES_HINTING_SYSTEM_DEFAULT),
+ subpixel_rendering(
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_SYSTEM_DEFAULT),
+ focus_ring_color(0),
+ thumb_active_color(0),
+ thumb_inactive_color(0),
+ track_color(0),
+ active_selection_bg_color(0),
+ active_selection_fg_color(0),
+ inactive_selection_bg_color(0),
+ inactive_selection_fg_color(0),
+ browser_handles_top_level_requests(false),
+ caret_blink_interval(0) {
+}
diff --git a/content/common/renderer_preferences.h b/content/common/renderer_preferences.h
new file mode 100644
index 0000000..6beb090
--- /dev/null
+++ b/content/common/renderer_preferences.h
@@ -0,0 +1,78 @@
+// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+// A struct for managing browser's settings that apply to the renderer or its
+// webview. These differ from WebPreferences since they apply to Chromium's
+// glue layer rather than applying to just WebKit.
+//
+// Adding new values to this class probably involves updating
+// common/render_messages.h, browser/browser.cc, etc.
+
+#ifndef CONTENT_COMMON_RENDERER_PREFERENCES_H_
+#define CONTENT_COMMON_RENDERER_PREFERENCES_H_
+#pragma once
+
+#include "third_party/skia/include/core/SkColor.h"
+
+enum RendererPreferencesHintingEnum {
+ RENDERER_PREFERENCES_HINTING_SYSTEM_DEFAULT = 0,
+ RENDERER_PREFERENCES_HINTING_NONE,
+ RENDERER_PREFERENCES_HINTING_SLIGHT,
+ RENDERER_PREFERENCES_HINTING_MEDIUM,
+ RENDERER_PREFERENCES_HINTING_FULL,
+};
+
+enum RendererPreferencesSubpixelRenderingEnum {
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_SYSTEM_DEFAULT = 0,
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_NONE,
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_RGB,
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_BGR,
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_VRGB,
+ RENDERER_PREFERENCES_SUBPIXEL_RENDERING_VBGR,
+};
+
+struct RendererPreferences {
+ RendererPreferences();
+
+ // Whether the renderer's current browser context accept drops from the OS
+ // that result in navigations away from the current page.
+ bool can_accept_load_drops;
+
+ // Whether text should be antialiased.
+ // Currently only used by Linux.
+ bool should_antialias_text;
+
+ // The level of hinting to use when rendering text.
+ // Currently only used by Linux.
+ RendererPreferencesHintingEnum hinting;
+
+ // The type of subpixel rendering to use for text.
+ // Currently only used by Linux.
+ RendererPreferencesSubpixelRenderingEnum subpixel_rendering;
+
+ // The color of the focus ring. Currently only used on Linux.
+ SkColor focus_ring_color;
+
+ // The color of different parts of the scrollbar. Currently only used on
+ // Linux.
+ SkColor thumb_active_color;
+ SkColor thumb_inactive_color;
+ SkColor track_color;
+
+ // The colors used in selection text. Currently only used on Linux.
+ SkColor active_selection_bg_color;
+ SkColor active_selection_fg_color;
+ SkColor inactive_selection_bg_color;
+ SkColor inactive_selection_fg_color;
+
+ // Browser wants a look at all top level requests
+ bool browser_handles_top_level_requests;
+
+ // Cursor blink rate in seconds.
+ // Currently only changed from default on Linux. Uses |gtk-cursor-blink|
+ // from GtkSettings.
+ double caret_blink_interval;
+};
+
+#endif // CONTENT_COMMON_RENDERER_PREFERENCES_H_