mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Avoid the generic writer parameter for PropertyDeclaration serialization.
MozReview-Commit-ID: JR3IcL1NRHO
This commit is contained in:
parent
f5dd50dcfd
commit
5526947500
21 changed files with 227 additions and 108 deletions
|
@ -17,7 +17,9 @@ use gecko_bindings::sugar::refptr::{RefPtr, UniqueRefPtr};
|
|||
use nsstring::nsString;
|
||||
use properties::longhands::font_language_override;
|
||||
use shared_lock::{ToCssWithGuard, SharedRwLockReadGuard};
|
||||
use std::{fmt, str};
|
||||
use std::fmt::{self, Write};
|
||||
use std::str;
|
||||
use str::CssStringWriter;
|
||||
use values::computed::font::FamilyName;
|
||||
use values::generics::FontSettings;
|
||||
|
||||
|
@ -200,8 +202,7 @@ impl From<FontFaceRuleData> for FontFaceRule {
|
|||
}
|
||||
|
||||
impl ToCssWithGuard for FontFaceRule {
|
||||
fn to_css<W>(&self, _guard: &SharedRwLockReadGuard, dest: &mut W) -> fmt::Result
|
||||
where W: fmt::Write {
|
||||
fn to_css(&self, _guard: &SharedRwLockReadGuard, dest: &mut CssStringWriter) -> fmt::Result {
|
||||
let mut css_text = nsString::new();
|
||||
unsafe {
|
||||
bindings::Gecko_CSSFontFaceRule_GetCssText(self.get(), &mut *css_text);
|
||||
|
@ -237,8 +238,7 @@ impl From<counter_style::CounterStyleRuleData> for CounterStyleRule {
|
|||
}
|
||||
|
||||
impl ToCssWithGuard for CounterStyleRule {
|
||||
fn to_css<W>(&self, _guard: &SharedRwLockReadGuard, dest: &mut W) -> fmt::Result
|
||||
where W: fmt::Write {
|
||||
fn to_css(&self, _guard: &SharedRwLockReadGuard, dest: &mut CssStringWriter) -> fmt::Result {
|
||||
let mut css_text = nsString::new();
|
||||
unsafe {
|
||||
bindings::Gecko_CSSCounterStyle_GetCssText(self.get(), &mut *css_text);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue