mirror of
https://github.com/servo/servo.git
synced 2025-08-02 20:20:14 +01:00
Inline PresentationalHintSynthesis::synthesize_presentational_hints_for_legacy_attributes.
This commit is contained in:
parent
9c1d678b1b
commit
1154cf51c8
2 changed files with 6 additions and 39 deletions
|
@ -2,7 +2,6 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use legacy::PresentationalHintSynthesis;
|
||||
use media_queries::{Device, MediaType};
|
||||
use node::TElementAttributes;
|
||||
use properties::{PropertyDeclaration, PropertyDeclarationBlock};
|
||||
|
@ -277,9 +276,12 @@ impl Stylist {
|
|||
&mut shareable);
|
||||
|
||||
// Step 2: Presentational hints.
|
||||
self.synthesize_presentational_hints_for_legacy_attributes(element,
|
||||
applicable_declarations,
|
||||
&mut shareable);
|
||||
let length = applicable_declarations.len();
|
||||
element.synthesize_presentational_hints_for_legacy_attributes(applicable_declarations);
|
||||
if applicable_declarations.len() != length {
|
||||
// Never share style for elements with preshints
|
||||
shareable = false;
|
||||
}
|
||||
|
||||
// Step 3: User and author normal rules.
|
||||
map.user.normal.get_all_matching_rules(element,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue